function get_option($name) { $cache = Cache::get('system-options'); if (empty($cache)) { $options = App\Option::get(['name', 'value']); foreach ($options as $option) { $data[$option->name] = $option->value; } Cache::forever('system-options', $data); $cache = Cache::get('system-options'); } return htmlspecialchars_decode($cache[$name]); }