diff options
| author | Adam Soltys <[email protected]> | 2025-05-12 12:36:28 -0700 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2025-05-12 12:36:28 -0700 |
| commit | f85ae08db1dd6471d9e2d5edc28025684d0f3af4 (patch) | |
| tree | 74bce0b17195b8bda4973e6a203215b1a87cf364 /routes/users.ts | |
| parent | 67f9ec53b7348860ab55e49574a81df4706dfb06 (diff) | |
| download | coinos-server-f85ae08db1dd6471d9e2d5edc28025684d0f3af4.tar.gz coinos-server-f85ae08db1dd6471d9e2d5edc28025684d0f3af4.zip | |
locked balance
Diffstat (limited to 'routes/users.ts')
| -rw-r--r-- | routes/users.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/routes/users.ts b/routes/users.ts index ff69fbcf..6b73513b 100644 --- a/routes/users.ts +++ b/routes/users.ts @@ -2,7 +2,7 @@ import { createReadStream } from "node:fs"; import { appendFile, unlink } from "node:fs/promises"; import config from "$config"; import { requirePin } from "$lib/auth"; -import { db, g, s } from "$lib/db"; +import { db, g, ga, s } from "$lib/db"; import { err, l, warn } from "$lib/logging"; import { mail, templates } from "$lib/mail"; import { getNostrUser, getProfile, serverPubkey } from "$lib/nostr"; @@ -32,6 +32,7 @@ export default { const { user } = req; try { user.balance = await g(`balance:${user.id}`); + user.locked = await ga(`balance:${user.id}`); user.prompt = !!user.prompt; if (user.pubkey) user.npub = nip19.npubEncode(user.pubkey); |
