From 25092528c9df614db749b6d8403561fc348c8a7f Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Mon, 17 Aug 2026 23:33:40 -0700 Subject: Old money stops surprising: a payment confirmed more than fifteen minutes ago is news, not an event — the celebration is reserved for arrivals you could actually be waiting on MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01JtaatFfAbx91Nh3xqKVqKz --- src/app.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/app.js b/src/app.js index 577f7b2..063da05 100644 --- a/src/app.js +++ b/src/app.js @@ -3223,8 +3223,13 @@ function tabContent() { // within the last couple hours. This is a hard guard so an old payment can never // trigger the celebration on import, regardless of receive-index bookkeeping. function hasRecentIncoming() { + // "Recent" means "plausibly the payment you're watching for right now". + // The open-time baseline can't cover a payment the socket only DISCOVERS + // seconds after it was taken — with a 2h window, money that landed a while + // ago celebrated on open as if it had just arrived. A payment confirmed + // more than 15 minutes ago is news, not an event. const now = Date.now() / 1000; - return wallet.txs.some((tx) => tx.net > 0 && (!tx.confirmed || (tx.blockTime && now - tx.blockTime < 2 * 3600))); + return wallet.txs.some((tx) => tx.net > 0 && (!tx.confirmed || (tx.blockTime && now - tx.blockTime < 900))); } // ---------------------------------------------------------------- Receive -- cgit v1.2.3