make(ActivationHandler::class))->handle($networkwide); }); register_deactivation_hook($file, function () use ($app) { ($app->make(DeactivationHandler::class))->handle(); }); require_once(FLUENTCART_PLUGIN_PATH . 'boot/action_scheduler_loader.php'); add_action('plugins_loaded', function () use ($app) { do_action('fluentcart_loaded', $app); (new FluentCart\App\Modules\Data\ProductDataSetup())->boot(); add_action('init', function () use ($app) { // maybe database changes DBMigrator::maybeMigrateDBChanges(); do_action('fluent_cart/init', $app); if (defined('DATABASE_TYPE') && DATABASE_TYPE === 'sqlite') { add_action('admin_notices', function () { ?>

')) { if(!PermissionManager::userCan('is_super_admin')) { return $notices; } $updateUrl = admin_url('plugins.php?s=fluent-cart&plugin_status=all&fluent-cart-pro-check-update=' . time()); $notices[] = [ 'id' => 'update_license', 'type' => 'core_update', 'html' => '
FluentCart Pro Plugin needs to be updated to the latest version. Click here to update
' ]; } return $notices; }); } }); add_action('wp_insert_site', function ($new_site) use ($app) { if (is_plugin_active_for_network('fluent-cart/fluent-cart.php')) { switch_to_blog($new_site->blog_id); ($app->make(ActivationHandler::class))->handle(false); restore_current_blog(); } }); return $app; };