From cacad0c86e16d304b31ae1559e9d9d3b5d7db718 Mon Sep 17 00:00:00 2001 From: Denis Nebytov Date: Wed, 27 Nov 2024 19:15:15 +0300 Subject: [PATCH] Applied suggested changes --- .../app/containers/wallet/WalletReceivePage.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/packages/yoroi-extension/app/containers/wallet/WalletReceivePage.js b/packages/yoroi-extension/app/containers/wallet/WalletReceivePage.js index 202d79d8c9..eb5017bd98 100644 --- a/packages/yoroi-extension/app/containers/wallet/WalletReceivePage.js +++ b/packages/yoroi-extension/app/containers/wallet/WalletReceivePage.js @@ -45,7 +45,6 @@ import WalletReceiveRevamp from '../../components/wallet/WalletReceiveRevamp'; import UnmangleTxDialogContainer from '../transfer/UnmangleTxDialogContainer'; import StandardHeaderRevamp from '../../components/wallet/receive/StandardHeaderRevamp'; import { maybe } from '../../coreUtils'; -import { ROUTES } from '../../routes-config'; type Props = {| ...StoresAndActionsProps, @@ -120,7 +119,7 @@ class WalletReceivePage extends Component { }; const isHwWallet = publicDeriver.type !== 'mnemonic'; - const isAddressBook = this.props.stores.router.location.pathname.startsWith(`${ROUTES.WALLETS.RECEIVE.ROOT}/addressBook/all`) + const isAddressBook = addressTypeStore.meta.name.group === AddressGroupTypes.addressBook; const onCopyAddressTooltip = (address, elementId) => { if (!uiNotifications.isOpen(elementId)) { @@ -195,7 +194,7 @@ class WalletReceivePage extends Component { /> ); } - if (addressTypeStore.meta.name.group === AddressGroupTypes.addressBook) { + if (isAddressBook) { return null; } if (addressTypeStore.meta.name.subgroup === AddressSubgroup.all) {