From 6cfdac529f1378e7c45d556e18352198361e2b72 Mon Sep 17 00:00:00 2001 From: ryanml Date: Fri, 19 Mar 2021 08:48:41 -0700 Subject: [PATCH] Don't render faucet row in deposit modal for custom chains (#10674) Fixes MetaMask/metamask-extension#10038 --- .../deposit-ether-modal.component.js | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/ui/app/components/app/modals/deposit-ether-modal/deposit-ether-modal.component.js b/ui/app/components/app/modals/deposit-ether-modal/deposit-ether-modal.component.js index 147a80e86..553f25973 100644 --- a/ui/app/components/app/modals/deposit-ether-modal/deposit-ether-modal.component.js +++ b/ui/app/components/app/modals/deposit-ether-modal/deposit-ether-modal.component.js @@ -155,14 +155,15 @@ export default class DepositEtherModal extends Component { buttonLabel: this.context.t('viewAccount'), onButtonClick: () => this.goToAccountDetailsModal(), })} - {this.renderRow({ - logo: , - title: this.context.t('testFaucet'), - text: this.context.t('getEtherFromFaucet', [networkName]), - buttonLabel: this.context.t('getEther'), - onButtonClick: () => toFaucet(chainId), - hide: !isTestnet, - })} + {networkName && + this.renderRow({ + logo: , + title: this.context.t('testFaucet'), + text: this.context.t('getEtherFromFaucet', [networkName]), + buttonLabel: this.context.t('getEther'), + onButtonClick: () => toFaucet(chainId), + hide: !isTestnet, + })}