Dedupe conf loading function.

Summary:

Test Plan:

Reviewers:

CC:
This commit is contained in:
epriestley
2011-02-11 13:17:06 -08:00
parent 5fbeac4abc
commit a4852d4a64
3 changed files with 29 additions and 19 deletions
+1 -8
View File
@@ -31,11 +31,4 @@ if (!ini_get('date.timezone')) {
phutil_load_library(dirname(__FILE__).'/../src/');
function phabricator_read_config_file($config) {
$root = dirname(dirname(__FILE__));
$conf = include $root.'/conf/'.$config.'.conf.php';
if ($conf === false) {
throw new Exception("Failed to read config file '{$config}'.");
}
return $conf;
}
require_once dirname(dirname(__FILE__)).'/conf/__init_conf__.php';