1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-23 18:41:38 +01:00

Merge pull request #1446 from MetaMask/DisallowDecimalsInHexInput

Fix bug where decimals in gas inputs gave strange results
This commit is contained in:
Dan Finlay 2017-05-17 14:35:21 -07:00 committed by GitHub
commit fae34c169f
2 changed files with 2 additions and 1 deletions

View File

@ -5,6 +5,7 @@
- Fix bug where edited gas parameters would not take effect.
- Trim currency list.
- Fix event filter bug introduced by newer versions of Geth.
- Fix bug where decimals in gas inputs could result in strange values.
## 3.6.4 2017-5-8

View File

@ -139,7 +139,7 @@ HexAsDecimalInput.prototype.constructWarning = function () {
}
function hexify (decimalString) {
const hexBN = new BN(decimalString, 10)
const hexBN = new BN(parseInt(decimalString), 10)
return '0x' + hexBN.toString('hex')
}