Move hook-related methods from Core\Addon to Core\Hook

This commit is contained in:
Hypolite Petovan 2018-10-21 01:15:02 -04:00
parent 0aa7671119
commit ca9cad3491
9 changed files with 153 additions and 242 deletions

View file

@ -7,6 +7,7 @@ namespace Friendica\Worker;
use Friendica\BaseObject;
use Friendica\Core\Addon;
use Friendica\Core\Config;
use Friendica\Core\Hook;
use Friendica\Core\Protocol;
use Friendica\Core\Worker;
use Friendica\Database\DBA;
@ -45,7 +46,7 @@ class Cron
logger('cron: start');
// Fork the cron jobs in separate parts to avoid problems when one of them is crashing
Addon::forkHooks($a->queue['priority'], "cron");
Hook::fork($a->queue['priority'], "cron");
// run queue delivery process in the background
Worker::add(PRIORITY_NEGLIGIBLE, "Queue");