Fixes regarding to init.php

This commit is contained in:
slawkens
2024-11-08 10:23:22 +01:00
parent c3dd10af96
commit 92024cfdbf
12 changed files with 21 additions and 11 deletions

View File

@@ -14,10 +14,10 @@ use MyAAC\CsrfToken;
use MyAAC\Hooks;
use MyAAC\Models\Town;
use MyAAC\Settings;
use MyAAC\Towns;
defined('MYAAC') or die('Direct access not allowed!');
global $config;
if(!isset($config['installed']) || !$config['installed']) {
throw new RuntimeException('MyAAC has not been installed yet or there was error during installation. Please install again.');
}
@@ -46,6 +46,7 @@ if(isset($config['gzip_output']) && $config['gzip_output'] && isset($_SERVER['HT
$cache = Cache::getInstance();
// event system
global $hooks;
$hooks = new Hooks();
$hooks->load();