Skip to content

Commit

Permalink
CLI: fix site import (#216)
Browse files Browse the repository at this point in the history
* clean up headstart skin

* version bump

* fix site import
  • Loading branch information
jhnstn authored Jan 6, 2025
1 parent d2b3c6d commit afb8541
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugin/cli/class-wpcloud-cli-site.php
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ public function import( array $args, array $switches ): void {
$sites = array_filter(
$sites,
function ( $site ) {
return ! WPCLOUD_Site::get_by_id( $site->atomic_site_id );
return ! WPCLOUD_Site::get_by_id( (int) $site->atomic_site_id );
}
);

Expand All @@ -216,7 +216,7 @@ function ( $site ) {
WP_CLI::confirm( 'Are you sure you want to import?' );
$progress = \WP_CLI\Utils\make_progress_bar( 'Importing', $total );
foreach ( $sites as $site ) {
$this->import_site( $site->atomic_site_id, $owner );
$this->import_site( (int) $site->atomic_site_id, $owner );
$progress->tick();
}
$progress->finish();
Expand Down

0 comments on commit afb8541

Please sign in to comment.