Skip to content

Commit

Permalink
assume that non-JavaScript config files are in JSON format (#1391)
Browse files Browse the repository at this point in the history
  • Loading branch information
hegemonic committed Jul 10, 2017
1 parent a10a779 commit 25d93b8
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,9 @@ cli.loadConfig = function() {
break;
case '.json':
case '.EXAMPLE':
default:
config = fs.readFileSync(confPath, 'utf8');
break;
default:
cli.exit(1, 'Cannot use config file ' + confPath + '. Only .js and .json files ' +
'are supported.\n' + FATAL_ERROR_MESSAGE);
}
env.conf = new Config(config).get();
}
Expand Down

0 comments on commit 25d93b8

Please sign in to comment.