1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

Merge pull request #6959 from MetaMask/normalize-addresses-send-from-input

Ensure showing of add contact dialog on send accounts for checksum inputs
This commit is contained in:
Thomas Huang 2019-08-05 19:15:33 -07:00 committed by GitHub
commit 1779dc8be4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -48,7 +48,7 @@ export default class SendContent extends Component {
maybeRenderAddContact () { maybeRenderAddContact () {
const { t } = this.context const { t } = this.context
const { to, addressBook = [], ownedAccounts = [], showAddToAddressBookModal } = this.props const { to, addressBook = [], ownedAccounts = [], showAddToAddressBookModal } = this.props
const isOwnedAccount = !!ownedAccounts.find(({ address }) => address === to) const isOwnedAccount = !!ownedAccounts.find(({ address }) => address.toLowerCase() === to.toLowerCase())
const contact = addressBook.find(({ address }) => address === to) || {} const contact = addressBook.find(({ address }) => address === to) || {}
if (isOwnedAccount || contact.name) { if (isOwnedAccount || contact.name) {