add triple equals
This commit is contained in:
parent
86d8a30c15
commit
5a3a9878f9
|
@ -152,16 +152,16 @@ class ContractDeployer {
|
||||||
accounts = _accounts;
|
accounts = _accounts;
|
||||||
|
|
||||||
// applying deployer account configuration, if any
|
// applying deployer account configuration, if any
|
||||||
if (typeof contract.fromIndex == 'number') {
|
if (typeof contract.fromIndex === 'number') {
|
||||||
deploymentAccount = accounts[contract.fromIndex];
|
deploymentAccount = accounts[contract.fromIndex];
|
||||||
if (deploymentAccount === undefined) {
|
if (deploymentAccount === undefined) {
|
||||||
return next(__("error deploying") + " " + contract.className + ": " + __("no account found at index") + " " + contract.fromIndex + __(" check the config"));
|
return next(__("error deploying") + " " + contract.className + ": " + __("no account found at index") + " " + contract.fromIndex + __(" check the config"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (typeof contract.from == 'string' && typeof contract.fromIndex != 'undefined') {
|
if (typeof contract.from === 'string' && typeof contract.fromIndex !== 'undefined') {
|
||||||
self.logger.warn(__('Both "from" and "fromIndex" are defined for contract') + ' "' + contract.className + '". ' + __('Using "from" as deployer account.'));
|
self.logger.warn(__('Both "from" and "fromIndex" are defined for contract') + ' "' + contract.className + '". ' + __('Using "from" as deployer account.'));
|
||||||
}
|
}
|
||||||
if (typeof contract.from == 'string') {
|
if (typeof contract.from === 'string') {
|
||||||
deploymentAccount = contract.from;
|
deploymentAccount = contract.from;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue