Every time you use for..in for an Array, Justin Beiber kills a kitten.
function loadConfig() {
var new_config,
- conf_filepath;
+ conf_filepath,
+ i;
// Loop through the possible config paths and find a usable one
- for (var i in config_dirs) {
+ for (i = 0; i < config_dirs.length; i++) {
conf_filepath = config_dirs[i] + config_filename;
try {
return loaded_config[specific_environment] || {};
};
-module.exports.loadConfig = loadConfig;
\ No newline at end of file
+module.exports.loadConfig = loadConfig;