Cleaned up initialization process.

pull/55/merge
Mike Cao 12 years ago
parent 66a403ff96
commit 2050027db6

@ -45,8 +45,6 @@ class Engine {
$this->vars = array();
$this->loader = new Loader();
$this->loader->autoload(true, dirname(dirname(__DIR__)));
$this->dispatcher = new Dispatcher();
$this->init();
@ -79,6 +77,7 @@ class Engine {
static $initialized = false;
if ($initialized) {
$this->vars = array();
$this->loader->reset();
$this->dispatcher->reset();
}

@ -36,7 +36,6 @@ class Flight {
require_once __DIR__.'/autoload.php';
self::$engine = new \flight\Engine();
self::$engine->init();
$initialized = true;
}

Loading…
Cancel
Save