X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=bin%2Fworker.php;h=2b5915f471d4fc76b9fdfdee1bad2ff42318cea0;hb=5e3a55915d7fdd554d711b2b5b619552a492c090;hp=a64b6a83305660f705bf5530141061ddcf379269;hpb=2e602afd3e1be80dc0e14db98ce0445c58d5231c;p=friendica.git diff --git a/bin/worker.php b/bin/worker.php index a64b6a8330..2b5915f471 100755 --- a/bin/worker.php +++ b/bin/worker.php @@ -4,11 +4,12 @@ * @file bin/worker.php * @brief Starts the background processing */ + use Friendica\App; use Friendica\Core\Config; -use Friendica\Core\Worker; use Friendica\Core\Update; -use Friendica\Util\LoggerFactory; +use Friendica\Core\Worker; +use Friendica\Factory; // Get options $shortopts = 'sn'; @@ -29,12 +30,10 @@ if (!file_exists("boot.php") && (sizeof($_SERVER["argv"]) != 0)) { require dirname(__DIR__) . '/vendor/autoload.php'; -$logger = LoggerFactory::create('worker'); - -$a = new App(dirname(__DIR__), $logger); +$a = Factory\DependencyFactory::setUp('worker', dirname(__DIR__)); // Check the database structure and possibly fixes it -Update::check(true); +Update::check($a->getBasePath(), true, $a->getMode()); // Quit when in maintenance if (!$a->getMode()->has(App\Mode::MAINTENANCEDISABLED)) {