<?php
// Version
define('VERSION', '4.1.0.0');

// Configuration
if (is_file('config.php')) {
    require_once('config.php');
}

// Install
if (!defined('DIR_APPLICATION')) {
    header('Location: install/index.php');
    exit();
}

// Startup
require_once(DIR_SYSTEM . 'startup.php');

// 加载自定义解密模板类
require_once(DIR_SYSTEM . 'library/template/DecryptTwig.php');

// Framework
require_once(DIR_SYSTEM . 'framework.php');

// 替换 Registry 中的 template
if (class_exists('Registry')) {
    $registry = Registry::getInstance();
    $registry->set('template', new DecryptTwig());
}