diff --git a/src/components/qr-scanner-button.tsx b/src/components/qr-scanner-button.tsx index 98182a9c3..23d2c8dcf 100644 --- a/src/components/qr-scanner-button.tsx +++ b/src/components/qr-scanner-button.tsx @@ -16,7 +16,7 @@ export const QrScannerButton = () => { const onPressQR = useCallback(() => { const subscription = ({from, to}: any) => { - if (AddressUtils.isEthAddress(to)) { + if (AddressUtils.isValidAddress(to)) { app.off('address', subscription); hideModal(ModalType.qr); navigation.navigate('transaction', {to, from}); diff --git a/src/event-actions/on-deep-link.ts b/src/event-actions/on-deep-link.ts index 3198e876e..f8a870d3a 100644 --- a/src/event-actions/on-deep-link.ts +++ b/src/event-actions/on-deep-link.ts @@ -66,13 +66,13 @@ export async function onDeepLink( return false; } - if (AddressUtils.isEthAddress(link)) { - await handleAddress(link, withoutFromAddress); + if (AddressUtils.isHaqqAddress(link)) { + await handleAddress(AddressUtils.toEth(link), withoutFromAddress); return true; } - if (AddressUtils.isHaqqAddress(link)) { - await handleAddress(AddressUtils.toEth(link), withoutFromAddress); + if (AddressUtils.isValidAddress(link)) { + await handleAddress(link, withoutFromAddress); return true; } @@ -101,13 +101,13 @@ export async function onDeepLink( ':', ); - if (AddressUtils.isEthAddress(key)) { - await handleAddress(key, withoutFromAddress); + if (AddressUtils.isHaqqAddress(link)) { + await handleAddress(AddressUtils.toEth(link), withoutFromAddress); return true; } - if (AddressUtils.isHaqqAddress(key)) { - await handleAddress(AddressUtils.toEth(key), withoutFromAddress); + if (AddressUtils.isValidAddress(link)) { + await handleAddress(link, withoutFromAddress); return true; }