Skip to content

Commit

Permalink
force activation of mint for migration
Browse files Browse the repository at this point in the history
  • Loading branch information
callebtc committed Apr 25, 2023
1 parent 6d73414 commit 5812d79
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/pages/WalletPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2366,7 +2366,7 @@ export default {
this.walletURL = this.baseURL;
}
let activeMintUrl = localStorage.getItem("cashu.activeMintUrl");
await this.activateMint(activeMintUrl);
await this.activateMint(activeMintUrl, false, true);
} else {
this.setTab("settings");
}
Expand Down
4 changes: 2 additions & 2 deletions src/stores/mints.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,9 @@ export const useMintsStore = defineStore("mints", {
this.showAddMintDialog = false;
}
},
activateMint: async function (url, verbose = false) {
activateMint: async function (url, verbose = false, force = false) {
const workers = useWorkersStore();
if (url === this.activeMintUrl) {
if (url === this.activeMintUrl && !force) {
// return here because this function is called repeatedly by the
// invoice check and token spendable check workers and would otherwise
// run until cleaAllWorkers and kill the woerkers
Expand Down

0 comments on commit 5812d79

Please sign in to comment.