mirror of https://github.com/embarklabs/embark.git
eslint is king
This commit is contained in:
parent
02e407f90b
commit
d3b0787895
|
@ -65,13 +65,16 @@ Config.prototype.reloadConfig = function() {
|
|||
|
||||
Config.prototype._mergeConfig = function(configFilePath, defaultConfig, env) {
|
||||
if (!configFilePath) {
|
||||
let configToReturn = defaultConfig['default'] || {}
|
||||
let configToReturn = defaultConfig['default'] || {};
|
||||
configToReturn.enabled = false;
|
||||
return configToReturn;
|
||||
}
|
||||
|
||||
if (!fs.existsSync(configFilePath)) {
|
||||
this.logger.warn("no config file found at " + configFilePath + ". using default config");
|
||||
// TODO: remove this if
|
||||
if (this.logger) {
|
||||
this.logger.warn("no config file found at " + configFilePath + ". using default config");
|
||||
}
|
||||
return defaultConfig['default'] || {};
|
||||
}
|
||||
|
||||
|
@ -86,10 +89,10 @@ Config.prototype._mergeConfig = function(configFilePath, defaultConfig, env) {
|
|||
};
|
||||
|
||||
Config.prototype._getFileOrOject = function(object, filePath, property) {
|
||||
if (typeof(this.configDir) === 'object') {
|
||||
if (typeof (this.configDir) === 'object') {
|
||||
return this.configDir[property];
|
||||
}
|
||||
return this.configDir + filepath;
|
||||
return this.configDir + filePath;
|
||||
};
|
||||
|
||||
Config.prototype.loadBlockchainConfigFile = function() {
|
||||
|
@ -106,7 +109,7 @@ Config.prototype.loadContractsConfigFile = function() {
|
|||
var defaultVersions = {
|
||||
"web3.js": "1.0.0-beta",
|
||||
"solc": "0.4.17"
|
||||
}
|
||||
};
|
||||
var versions = utils.recursiveMerge(defaultVersions, this.embarkConfig.versions || {});
|
||||
|
||||
var configObject = {
|
||||
|
|
Loading…
Reference in New Issue