allow empty config file
This commit is contained in:
parent
1bdcd73d28
commit
dad2e66f52
|
@ -56,6 +56,10 @@ function readConfigAndRun(args) {
|
|||
} catch(e) {
|
||||
try {
|
||||
config = require('js-yaml').safeLoad(text);
|
||||
// blank config file
|
||||
if ('undefined' === typeof config) {
|
||||
config = {};
|
||||
}
|
||||
} catch(e) {
|
||||
throw new Error(
|
||||
"Could not load '" + filename + "' as JSON nor YAML"
|
||||
|
|
Loading…
Reference in New Issue