mirror of
https://github.com/klaussilveira/gitlist.git
synced 2025-11-18 11:40:57 +01:00
Die when no config object provided
Just a friendlier error message, when `boot.php` is included without a global `$config` object being set.
This commit is contained in:
6
boot.php
6
boot.php
@@ -1,7 +1,9 @@
|
||||
<?php
|
||||
|
||||
// Load configuration
|
||||
$config = GitList\Config::fromFile('config.ini');
|
||||
if (!isset($config)) {
|
||||
die("No configuration object provided.");
|
||||
}
|
||||
|
||||
$config->set('git', 'repositories', rtrim($config->get('git', 'repositories'), DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR);
|
||||
|
||||
// Startup and configure Silex application
|
||||
|
||||
Reference in New Issue
Block a user