aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Finlay <dan@danfinlay.com>2017-06-28 06:49:57 +0800
committerDan Finlay <dan@danfinlay.com>2017-06-28 06:49:57 +0800
commit8642feee09f57d5756c682a053434a196cff4af3 (patch)
tree694282fa94d6d60ef578ec8477f956404a815ef6
parent307e967a0c2f059e8e2c742c282ba5b43c311cb0 (diff)
downloadtangerine-wallet-browser-8642feee09f57d5756c682a053434a196cff4af3.tar
tangerine-wallet-browser-8642feee09f57d5756c682a053434a196cff4af3.tar.gz
tangerine-wallet-browser-8642feee09f57d5756c682a053434a196cff4af3.tar.bz2
tangerine-wallet-browser-8642feee09f57d5756c682a053434a196cff4af3.tar.lz
tangerine-wallet-browser-8642feee09f57d5756c682a053434a196cff4af3.tar.xz
tangerine-wallet-browser-8642feee09f57d5756c682a053434a196cff4af3.tar.zst
tangerine-wallet-browser-8642feee09f57d5756c682a053434a196cff4af3.zip
Remove token contract validation step
-rw-r--r--ui/app/add-token.js14
1 files changed, 1 insertions, 13 deletions
diff --git a/ui/app/add-token.js b/ui/app/add-token.js
index f21184270..b303b5c0d 100644
--- a/ui/app/add-token.js
+++ b/ui/app/add-token.js
@@ -142,13 +142,7 @@ AddTokenScreen.prototype.render = function () {
if (!valid) return
const { address, symbol, decimals } = this.state
- this.checkIfToken(address.trim())
- .then(() => {
- this.props.dispatch(actions.addToken(address.trim(), symbol.trim(), decimals))
- })
- .catch((reason) => {
- this.setState({ warning: 'Not a valid token address.' })
- })
+ this.props.dispatch(actions.addToken(address.trim(), symbol.trim(), decimals))
},
}, 'Add'),
]),
@@ -208,12 +202,6 @@ AddTokenScreen.prototype.validateInputs = function () {
return isValid
}
-AddTokenScreen.prototype.checkIfToken = async function (address) {
- const contract = this.TokenContract.at(address)
- const result = await contract.balance(address)
- return result[0].toString()
-}
-
AddTokenScreen.prototype.attemptToAutoFillTokenParams = async function (address) {
const contract = this.TokenContract.at(address)