add triple equals

This commit is contained in:
Jonathan Rainville 2018-06-20 14:06:15 -04:00 committed by Iuri Matias
parent 86d8a30c15
commit 5a3a9878f9
1 changed files with 3 additions and 3 deletions

View File

@ -152,16 +152,16 @@ class ContractDeployer {
accounts = _accounts;
// applying deployer account configuration, if any
if (typeof contract.fromIndex == 'number') {
if (typeof contract.fromIndex === 'number') {
deploymentAccount = accounts[contract.fromIndex];
if (deploymentAccount === undefined) {
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.'));
}
if (typeof contract.from == 'string') {
if (typeof contract.from === 'string') {
deploymentAccount = contract.from;
}