Skip to content

Commit

Permalink
Fix redirect to UsdtAdded modal
Browse files Browse the repository at this point in the history
Cannot use useRouter() outside the setup function runtime itself.
  • Loading branch information
sisou committed Oct 24, 2024
1 parent 3eb8ebc commit df6f5d1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/layouts/AccountOverview.vue
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,7 @@ import LinkedDoubleArrowIcon from '../icons/LinkedDoubleArrowIcon.vue';
import AddressListBackgroundSvg from '../AddressListBackgroundSvg.vue';
import { useAddressStore } from '../../stores/Address';
import { useConfig } from '../../composables/useConfig';
import router, { useRouter } from '../../router';
import router from '../../router';
import { useAccountSettingsStore } from '../../stores/AccountSettings';
export default defineComponent({
Expand Down Expand Up @@ -414,7 +414,7 @@ export default defineComponent({
if (!hasPolygonAddresses.value || !stablecoin.value) return;
if (stablecoin.value === CryptoCurrency.USDC && !knowsAboutUsdt.value) {
useRouter().push({ name: 'usdt-added' });
context.root.$router.push({ name: 'usdt-added' });
return;
}
Expand Down

0 comments on commit df6f5d1

Please sign in to comment.