get(\MailPoet\Settings\SettingsController::class); if ($settings->get('cron_trigger.method') !== \MailPoet\Cron\CronTrigger::METHOD_LINUX_CRON) { echo 'You attempt to run MailPoets "Server side cron (Linux cron)."' . PHP_EOL . 'But in your settings, you have defined a different method for the Newsletter task scheduler.' . PHP_EOL . 'If you want to use the "Server side cron", please go to MailPoet > Settings > Advanced and choose the correct Newsletter task scheduler.' . PHP_EOL; exit(1); } // Run Cron Daemon $cronHelper = $container->get(\MailPoet\Cron\CronHelper::class); $data = $cronHelper->createDaemon(null); $trigger = $container->get(\MailPoet\Cron\Daemon::class); $trigger->run($data);