diff options
| -rw-r--r-- | lib/payments.ts | 2 | ||||
| -rw-r--r-- | routes/payments.ts | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/lib/payments.ts b/lib/payments.ts index 4c91266f..3a02bfda 100644 --- a/lib/payments.ts +++ b/lib/payments.ts @@ -782,7 +782,7 @@ export let reconcile = async (account, initial = false) => { let { total_amount } = await node.scanTxOutSet("start", descriptors); total = Math.round(total_amount * SATS); } else { - total = Math.round((await node.getBalance()) * SATS); + total = Math.round((await node.getBalance({ minconf: 1 })) * SATS); } let { balanceAdjustment: memo } = t(user); diff --git a/routes/payments.ts b/routes/payments.ts index 73a6b1f8..5d190c7e 100644 --- a/routes/payments.ts +++ b/routes/payments.ts @@ -291,6 +291,8 @@ export default { if (typeof p === "string") p = await g(`payment:${p}`); if (!p) { + let invoice = await getInvoice(address); + if (!hot && aid !== invoice?.aid) continue; await credit({ hash: address, amount: sats(amount), |
