Hook calls can now be forked into a worker queue entry

This commit is contained in:
Michael 2018-02-06 22:52:36 +00:00
parent 66e3c1836e
commit 47d165cb25
9 changed files with 47 additions and 68 deletions

19
src/Worker/ForkHook.php Normal file
View file

@ -0,0 +1,19 @@
<?php
/**
* @file src/Worker/ForkHook.php
*/
namespace Friendica\Worker;
use Friendica\Core\Addon;
Class ForkHook {
public static function execute($name, $hook_json, $data_json) {
global $a;
$hook = json_decode($hook_json, true);
$data = json_decode($data_json, true);
Addon::callSingleHook($a, $name, $hook, $data);
}
}