Skip to content

Commit

Permalink
Add conditional check to replace launch-site task with LYS task
Browse files Browse the repository at this point in the history
  • Loading branch information
ilyasfoo committed Sep 3, 2024
1 parent 6f4d9e8 commit 62d7e30
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions includes/class-wc-calypso-bridge-setup-tasks.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,9 +116,12 @@ public function add_tasks() {
$list = array_pop( $list );

$add_domain_task = new \Automattic\WooCommerce\Admin\Features\OnboardingTasks\Tasks\AddDomain( $list );
$launch_site_task = new \Automattic\WooCommerce\Admin\Features\OnboardingTasks\Tasks\LaunchSite( $list );
$tl::add_task( 'setup', $add_domain_task );
$tl::add_task( 'setup', $launch_site_task );

if ( ! class_exists( '\Automattic\WooCommerce\Admin\Features\Features' ) || ! \Automattic\WooCommerce\Admin\Features\Features::is_enabled( 'launch-your-store' ) ) {
$launch_site_task = new \Automattic\WooCommerce\Admin\Features\OnboardingTasks\Tasks\LaunchSite( $list );
$tl::add_task( 'setup', $launch_site_task );
}
}

/**
Expand Down

0 comments on commit 62d7e30

Please sign in to comment.