mirror of
https://github.com/slawkens/myaac.git
synced 2025-04-29 10:49:22 +02:00
Add HOOK_INIT, executed just after $hooks are loaded
This commit is contained in:
parent
a73fb1003e
commit
19686725dc
@ -50,6 +50,7 @@ $cache = Cache::getInstance();
|
|||||||
global $hooks;
|
global $hooks;
|
||||||
$hooks = new Hooks();
|
$hooks = new Hooks();
|
||||||
$hooks->load();
|
$hooks->load();
|
||||||
|
$hooks->trigger(HOOK_INIT);
|
||||||
|
|
||||||
// twig
|
// twig
|
||||||
require_once SYSTEM . 'twig.php';
|
require_once SYSTEM . 'twig.php';
|
||||||
|
@ -5,6 +5,7 @@ const SKILL_BALANCE = -2;
|
|||||||
|
|
||||||
$i = 0;
|
$i = 0;
|
||||||
|
|
||||||
|
define('HOOK_INIT', ++$i);
|
||||||
define('HOOK_STARTUP', ++$i);
|
define('HOOK_STARTUP', ++$i);
|
||||||
define('HOOK_BEFORE_PAGE', ++$i);
|
define('HOOK_BEFORE_PAGE', ++$i);
|
||||||
define('HOOK_AFTER_PAGE', ++$i);
|
define('HOOK_AFTER_PAGE', ++$i);
|
||||||
@ -96,7 +97,7 @@ define('HOOK_CACHE_CLEAR', ++$i);
|
|||||||
define('HOOK_INSTALL_FINISH', ++$i);
|
define('HOOK_INSTALL_FINISH', ++$i);
|
||||||
define('HOOK_INSTALL_FINISH_END', ++$i);
|
define('HOOK_INSTALL_FINISH_END', ++$i);
|
||||||
|
|
||||||
const HOOK_FIRST = HOOK_STARTUP;
|
const HOOK_FIRST = HOOK_INIT;
|
||||||
define('HOOK_LAST', $i);
|
define('HOOK_LAST', $i);
|
||||||
|
|
||||||
function is_sub_dir($path = NULL, $parent_folder = BASE): bool|string
|
function is_sub_dir($path = NULL, $parent_folder = BASE): bool|string
|
||||||
|
Loading…
x
Reference in New Issue
Block a user