Skip to content
This repository was archived by the owner on Mar 5, 2025. It is now read-only.

Commit 08ff568

Browse files
Merge branch '1.x' into patch-1
2 parents e9f768e + 099fe36 commit 08ff568

File tree

3 files changed

+12
-5
lines changed

3 files changed

+12
-5
lines changed

CHANGELOG.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,6 +291,7 @@ Released with 1.0.0-beta.37 code base.
291291
## [1.3.1]
292292

293293
### Changed
294+
294295
- bump utils 0.10.0^ -> 0.12.0 (#3733)
295296

296297
### Removed
@@ -299,4 +300,6 @@ Released with 1.0.0-beta.37 code base.
299300

300301
### Fixed
301302

302-
- Fixed decoding bytes and string parameters for logs emitted with solc 0.4.x (#3724, #3738)
303+
- Fix possible unhandled promise rejection when sending a transaction (#3708)
304+
- Fixed decoding bytes and string parameters for logs emitted with solc 0.4.x (#3724, #3738)
305+
- Grammar changes to inputAddressFormatter error message

packages/web3-core-helpers/src/formatters.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -472,7 +472,7 @@ var inputAddressFormatter = function (address) {
472472
} else if (utils.isAddress(address)) {
473473
return '0x' + address.toLowerCase().replace('0x', '');
474474
}
475-
throw new Error('Provided address "' + address + '" is invalid, the capitalization checksum test failed, or its an indrect IBAN address which can\'t be converted.');
475+
throw new Error(`Provided address ${address} is invalid, the capitalization checksum test failed, or it's an indirect IBAN address which can't be converted.`);
476476
};
477477

478478

@@ -508,4 +508,3 @@ module.exports = {
508508
outputPostFormatter: outputPostFormatter,
509509
outputSyncingFormatter: outputSyncingFormatter
510510
};
511-

packages/web3-core-method/src/index.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -725,17 +725,22 @@ Method.prototype.buildCall = function () {
725725
txOptions.common = method.defaultCommon;
726726
}
727727

728-
return method.accounts.signTransaction(txOptions, wallet.privateKey)
728+
method.accounts.signTransaction(txOptions, wallet.privateKey)
729729
.then(sendSignedTx)
730730
.catch(function (err) {
731731
if (_.isFunction(defer.eventEmitter.listeners) && defer.eventEmitter.listeners('error').length) {
732-
defer.eventEmitter.emit('error', err);
732+
try {
733+
defer.eventEmitter.emit('error', err);
734+
} catch (err) {
735+
// Ignore userland error prevent it to bubble up within web3.
736+
}
733737
defer.eventEmitter.removeAllListeners();
734738
defer.eventEmitter.catch(function () {
735739
});
736740
}
737741
defer.reject(err);
738742
});
743+
return;
739744
}
740745

741746
// ETH_SIGN

0 commit comments

Comments
 (0)