1
0
mirror of https://github.com/flextype/flextype.git synced 2025-08-08 14:16:46 +02:00

general engine changes and fixes

This commit is contained in:
Awilum
2018-03-09 19:49:27 +03:00
parent 7186fa46db
commit a7ea69d2a5
12 changed files with 5 additions and 17 deletions

View File

@@ -10,20 +10,14 @@
namespace Rawilum;
// Register the auto-loader.
$autoload = __DIR__ . '/vendor/autoload.php';
// Check PHP Version
version_compare($ver = PHP_VERSION, $req = '7.1.3', '<') and exit(sprintf('You are running PHP %s, but Rawilum needs at least <strong>PHP %s</strong> to run.', $ver, $req));
// Ensure vendor libraries exist
!is_file($autoload) and exit("Please run: <i>composer install</i>");
// Ensure vendor libraries exist and Register The Auto Loader
!is_file($autoload = __DIR__ . '/vendor/autoload.php') and exit("Please run: <i>composer install</i>");
// Register the auto-loader.
$loader = require_once $autoload;
// Check PHP Version
version_compare($ver = PHP_VERSION, $req = '7.1.3', '<') and exit(sprintf('You are running PHP %s, but Rawilum needs at least <strong>PHP %s</strong> to run.', $ver, $req));
// Get Rawilum Instance
$app = Rawilum::instance();
// Run Rawilum Application
$app->run();
$rawilum = Rawilum::instance()->run();

View File

@@ -60,10 +60,6 @@ class Rawilum extends Container
return new Config($c);
};
$container['router'] = function ($c) {
return new \Klein\Klein();
};
// Start the session
//\Session::start();
@@ -93,8 +89,6 @@ class Rawilum extends Container
return new Themes($c);
};
$container['router']->dispatch();
return $container;
}