Skip to content

Commit 9e518e8

Browse files
committed
Allow importing of empty arrays
1 parent f804ead commit 9e518e8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Post_Block_Command.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,7 @@ public function import( $args, $assoc_args ) {
623623
// Handle export format (with metadata wrapper) or plain blocks array.
624624
$import_blocks = isset( $data['blocks'] ) ? $data['blocks'] : $data;
625625

626-
if ( ! is_array( $import_blocks ) || empty( $import_blocks ) ) {
626+
if ( ! is_array( $import_blocks ) ) {
627627
WP_CLI::error( 'No blocks found in import data.' );
628628
}
629629

0 commit comments

Comments
 (0)