is this thing causing everything to die?

This commit is contained in:
flash 2015-04-01 17:14:09 +02:00
parent 3a79f21db5
commit 5191a56b85

View file

@ -29,12 +29,16 @@ class Configuration {
*/ */
public static function initDB() { public static function initDB() {
// Get config table from the database
$_DATA = Database::fetch('config', true); $_DATA = Database::fetch('config', true);
// Create variable to temporarily store values in
$_DBCN = array(); $_DBCN = array();
foreach($_DATA as $_CONF) foreach($_DATA as $_CONF) // Properly sort the values
$_DBCN[$_CONF[0]] = $_CONF[1]; $_DBCN[$_CONF[0]] = $_CONF[1];
// Assign the temporary array to the static one
self::$_DCNF = $_DBCN; self::$_DCNF = $_DBCN;
} }
@ -81,7 +85,7 @@ class Configuration {
trigger_error('Unable to get configuration value!', E_USER_ERROR); trigger_error('Unable to get configuration value!', E_USER_ERROR);
} }
/*
// Parse .cfg files, mainly/only used for templates // Parse .cfg files, mainly/only used for templates
public static function parseCfg($data) { public static function parseCfg($data) {
@ -111,6 +115,6 @@ class Configuration {
// Return the output variable // Return the output variable
return $out; return $out;
} }*/
} }