Set validateConfig and jsonReader to be local functions used only by getConfig which now returns a promise that is given the final, validated json object data.
Removed unnecessary variables and constants
If you run node reader.js you will see the object output. All errors injected are caught as they were before as well.
Removed use a typecheck and used R.is instead
Set validateConfig and jsonReader to be local functions used only by getConfig which now returns a promise that is given the final, validated json object data.
Removed unnecessary variables and constants
If you run
node reader.js
you will see the object output. All errors injected are caught as they were before as well.