diff options
| author | Adam Soltys <[email protected]> | 2026-09-27 23:45:07 -0700 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-09-27 23:45:07 -0700 |
| commit | 360c39400e219b9b4863e3ae6716f4e73b788045 (patch) | |
| tree | d796b01d6f3eaf39be286b9978aa9e4a36f9a497 /src/ark | |
| parent | 8a3af8c8afa9c86bc84f2821faaf6530eeb81a03 (diff) | |
| download | coinosv3-360c39400e219b9b4863e3ae6716f4e73b788045.tar.gz coinosv3-360c39400e219b9b4863e3ae6716f4e73b788045.zip | |
Expired dust gets a quiet line and a Forget button, not a red warning.
A coin past its expiry and under the 330-sat floor can be renewed by
nobody and exited by nobody; the home page said "the server can still
renew it" in red over 21 sats. Now a muted line points at Manage, where
the coin's row offers Forget: held as spent, quietly, so it stops
counting and stops warning. Larger expired coins keep the warning.
Co-Authored-By: Claude Fable 5.1 <[email protected]>
Claude-Session: https://claude.ai/code/session_01VhUKyXKtsJ67QAFfb7QR9D
Diffstat (limited to 'src/ark')
| -rw-r--r-- | src/ark/manager.js | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/ark/manager.js b/src/ark/manager.js index b828d7e..311c793 100644 --- a/src/ark/manager.js +++ b/src/ark/manager.js @@ -362,6 +362,21 @@ export class ArkManager { return true; } + // Give up a coin that has expired and is too small to renew (under the + // 330-sat output floor) or that the server has refused as expired: it is + // the server's now, in effect. Held as spent, quietly, so it stops + // counting and stops warning. + forgetVtxo(id) { + const v = this._vtxo(id); + if (!v || v.state !== 'spendable') return false; + const tip = this._tipH || 0; + if (!(v.expiryRejected || (tip && v.expiryHeight && v.expiryHeight <= tip))) return false; + v.state = 'spent'; + v.forgotten = true; + this._save(); + return true; + } + balance() { const tip = this._tipH || 0; const sum = (st) => this.state.vtxos |
