From f3378fb4246d760c0fd925e89d481b5fb2b834bb Mon Sep 17 00:00:00 2001 From: alter-eggo Date: Mon, 6 Nov 2023 14:36:28 +0400 Subject: [PATCH] fix: brc20 send form bug, closes #4482 --- .../send/send-crypto-asset-form/components/amount-field.tsx | 5 ++++- .../send-crypto-asset-form/form/brc-20/brc20-send-form.tsx | 4 ++-- src/shared/storage/redux-pesist.ts | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/app/pages/send/send-crypto-asset-form/components/amount-field.tsx b/src/app/pages/send/send-crypto-asset-form/components/amount-field.tsx index 7d7d3b0df50..d92acd3556e 100644 --- a/src/app/pages/send/send-crypto-asset-form/components/amount-field.tsx +++ b/src/app/pages/send/send-crypto-asset-form/components/amount-field.tsx @@ -219,7 +219,10 @@ export function AmountField({ {switchableAmount && switchableAmount} {showError && ( - + {meta.error} )} diff --git a/src/app/pages/send/send-crypto-asset-form/form/brc-20/brc20-send-form.tsx b/src/app/pages/send/send-crypto-asset-form/form/brc-20/brc20-send-form.tsx index 5e3d656e4b1..e381d59edeb 100644 --- a/src/app/pages/send/send-crypto-asset-form/form/brc-20/brc20-send-form.tsx +++ b/src/app/pages/send/send-crypto-asset-form/form/brc-20/brc20-send-form.tsx @@ -1,7 +1,7 @@ -import { Form, Outlet, useLocation } from 'react-router-dom'; +import { Outlet, useLocation } from 'react-router-dom'; import { Box } from '@stacks/ui'; -import { Formik } from 'formik'; +import { Form, Formik } from 'formik'; import get from 'lodash.get'; import { openInNewTab } from '@app/common/utils/open-in-new-tab'; diff --git a/src/shared/storage/redux-pesist.ts b/src/shared/storage/redux-pesist.ts index 66723f200af..fa256b29e58 100644 --- a/src/shared/storage/redux-pesist.ts +++ b/src/shared/storage/redux-pesist.ts @@ -135,7 +135,7 @@ async function migrateToRenameKeysStoreModule(state: Promise) { }; // add stacks ledger keys to new place - if (resolvedState.keys?.entities.default.type === 'ledger') { + if (resolvedState.keys?.entities.default?.type === 'ledger') { newStore.ledger = { ...resolvedState.ledger, stacks: processStacksLedgerKeys(resolvedState.keys),