if (new_config) {
loaded_config = new_config;
- global.config = new_config[environment];
+ global.config = new_config[environment] || {};
return loaded_config;
} else {
return false;
module.exports.get = function (specific_environment) {
specific_environment = specific_environment || environment;
- return loaded_config[specific_environment];
+ return loaded_config[specific_environment] || {};
};
module.exports.loadConfig = loadConfig;
\ No newline at end of file