X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=bin%2Fworker.php;h=c7174d81e1813ea0e246e2435c0132a7bdb8249a;hb=f4dfd4f6490dd965651aeb5fa8d39e0d566ed413;hp=5b5e949757fb8036230de480cd60f6a744cf74b1;hpb=fe8f0e00454919e3ee1150a2e75badb55a273c3a;p=friendica.git diff --git a/bin/worker.php b/bin/worker.php index 5b5e949757..c7174d81e1 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\Logger; -use Friendica\Core\Worker; use Friendica\Core\Update; +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 = Logger::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); // Quit when in maintenance if (!$a->getMode()->has(App\Mode::MAINTENANCEDISABLED)) {