From e5391cf9fdc7dfc25318caaed5dd56270946ddf8 Mon Sep 17 00:00:00 2001 From: Dan Date: Mon, 30 Oct 2017 19:34:21 -0230 Subject: Allow sending 0 eth or tokens --- ui/app/send-v2.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'ui/app') diff --git a/ui/app/send-v2.js b/ui/app/send-v2.js index 6f3b48be6..951af3d2c 100644 --- a/ui/app/send-v2.js +++ b/ui/app/send-v2.js @@ -422,7 +422,7 @@ SendTransactionScreen.prototype.renderAmountRow = function () { primaryCurrency, convertedCurrency, selectedToken, - value: amount, + value: amount || '0x0', conversionRate: amountConversionRate, handleChange: this.handleAmountChange, validate: this.validateAmount, @@ -512,7 +512,7 @@ SendTransactionScreen.prototype.renderFooter = function () { errors: { amount: amountError, to: toError }, } = this.props - const noErrors = amountError === null && toError === null + const noErrors = !amountError && toError === null const errorClass = noErrors ? '' : '__disabled' return h('div.send-v2__footer', [ @@ -566,7 +566,7 @@ SendTransactionScreen.prototype.onSubmit = function (event) { errors: { amount: amountError, to: toError }, } = this.props - const noErrors = amountError === null && toError === null + const noErrors = !amountError && toError === null if (!noErrors) { return -- cgit