diff options
Diffstat (limited to 'extension/lib/wallet/wallet.ts')
-rw-r--r-- | extension/lib/wallet/wallet.ts | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/extension/lib/wallet/wallet.ts b/extension/lib/wallet/wallet.ts index 448714254..8e7f63b12 100644 --- a/extension/lib/wallet/wallet.ts +++ b/extension/lib/wallet/wallet.ts @@ -513,7 +513,7 @@ export class Wallet { function storeMintCoin(mc) { let mint: IMintInfo = mc[0]; - let coin = mc[1]; + let coin: Coin = mc[1]; let cd = { coin: coin, denom: mint.denoms.find((e) => e.denom_pub === coin.denomPub) @@ -521,6 +521,10 @@ export class Wallet { if (!cd.denom) { throw Error("denom not found (database inconsistent)"); } + if (cd.denom.value.currency !== paymentAmount.currency) { + console.warn("same pubkey for different currencies"); + return; + } let x = m[mint.baseUrl]; if (!x) { m[mint.baseUrl] = [cd]; |