diff options
| author | Adam Soltys <[email protected]> | 2025-01-15 16:32:23 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2025-01-15 16:32:23 -0800 |
| commit | d850e1c2f616ac5707a1d1be015b0bcdf08bf308 (patch) | |
| tree | c0082b4aa382f3dadc9707ee9c59e358d299e752 /routes | |
| parent | 5d2c06457d018ef75c0fc4fa5fd4e9af266f19d8 (diff) | |
| download | coinos-server-d850e1c2f616ac5707a1d1be015b0bcdf08bf308.tar.gz coinos-server-d850e1c2f616ac5707a1d1be015b0bcdf08bf308.zip | |
default to blech32 for liquid
Diffstat (limited to 'routes')
| -rw-r--r-- | routes/invoices.ts | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/routes/invoices.ts b/routes/invoices.ts index a545459a..6f24e990 100644 --- a/routes/invoices.ts +++ b/routes/invoices.ts @@ -2,7 +2,7 @@ import config from "$config"; import { db, g } from "$lib/db"; import { generate } from "$lib/invoices"; import { err } from "$lib/logging"; -import { bail, getInvoice, pick } from "$lib/utils"; +import { bail, fields, getInvoice, getUser } from "$lib/utils"; import rpc from "@coinos/rpc"; export default { @@ -15,14 +15,7 @@ export default { if (invoice) { invoice.secret = undefined; - invoice.user = pick(await g(`user:${invoice.uid}`), [ - "id", - "picture", - "banner", - "currency", - "username", - "pubkey", - ]); + invoice.user = await getUser(invoice.uid, fields); invoice.items ||= []; } |
