diff options
author | Whymarrh Whitby <whymarrh.whitby@gmail.com> | 2018-10-01 20:50:33 +0800 |
---|---|---|
committer | Whymarrh Whitby <whymarrh.whitby@gmail.com> | 2018-10-01 23:23:32 +0800 |
commit | ce2e068b436f5e04c89bbef5c43afb23bd05b919 (patch) | |
tree | 8409374b3b92a1225fcbb7539372da4429ab52f6 /ui/app/components/send/send-content/send-to-row/send-to-row.utils.js | |
parent | c9f22916dd026445b2eb0ba343b54cc672fdf6f0 (diff) | |
download | tangerine-wallet-browser-ce2e068b436f5e04c89bbef5c43afb23bd05b919.tar.gz tangerine-wallet-browser-ce2e068b436f5e04c89bbef5c43afb23bd05b919.tar.zst tangerine-wallet-browser-ce2e068b436f5e04c89bbef5c43afb23bd05b919.zip |
Recipient not required on send screen when hex data present
Diffstat (limited to 'ui/app/components/send/send-content/send-to-row/send-to-row.utils.js')
-rw-r--r-- | ui/app/components/send/send-content/send-to-row/send-to-row.utils.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ui/app/components/send/send-content/send-to-row/send-to-row.utils.js b/ui/app/components/send/send-content/send-to-row/send-to-row.utils.js index 6b90a9f09..0eeaa3a11 100644 --- a/ui/app/components/send/send-content/send-to-row/send-to-row.utils.js +++ b/ui/app/components/send/send-content/send-to-row/send-to-row.utils.js @@ -4,9 +4,11 @@ const { } = require('../../send.constants') const { isValidAddress } = require('../../../../util') -function getToErrorObject (to, toError = null) { +function getToErrorObject (to, toError = null, hasHexData = false) { if (!to) { - toError = REQUIRED_ERROR + if (!hasHexData) { + toError = REQUIRED_ERROR + } } else if (!isValidAddress(to) && !toError) { toError = INVALID_RECIPIENT_ADDRESS_ERROR } |