protected function _loadSettings()
    {
        $settings = Cache::remember('settings', function () {
            /** @var SettingsTable $Settings */
            $Settings = $this->loadModel('Wasabi/Core.Settings');
            return $Settings->getAllKeyValues();
        }, 'wasabi/core/longterm');

        $event = new Event('Settings.afterLoad', $settings);
        $this->eventManager()->dispatch($event);

        if ($event->result !== null) {
            $settings = $event->result;
        }

        Configure::write('Settings', $settings);
    }