]> git.mxchange.org Git - friendica.git/blobdiff - bin/daemon.php
Deprecated upload function relocates to a replacement
[friendica.git] / bin / daemon.php
index 4fa9f8bd3fb5e844f3810a6a9657d5ca88954333..490a92ab84bb160449268e64cfff792ae2b61a84 100755 (executable)
@@ -60,6 +60,7 @@ $dice = (new Dice())->addRules(include __DIR__ . '/../static/dependencies.config
 $dice = $dice->addRule(LoggerInterface::class,['constructParams' => ['daemon']]);
 
 DI::init($dice);
+\Friendica\Core\Logger\Handler\ErrorHandler::register($dice->create(\Psr\Log\LoggerInterface::class));
 $a = DI::app();
 
 if (DI::mode()->isInstall()) {
@@ -195,7 +196,7 @@ while (true) {
                $do_cron = true;
        }
 
-       if ($do_cron || (!DI::process()->isMaxLoadReached() && Worker::entriesExists() && Worker::isReady())) {
+       if ($do_cron || (!DI::system()->isMaxLoadReached() && Worker::entriesExists() && Worker::isReady())) {
                Worker::spawnWorker($do_cron);
        } else {
                Logger::info('Cool down for 5 seconds', ['pid' => $pid]);