aboutsummaryrefslogtreecommitdiffstats
path: root/routes
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2024-11-19 13:50:35 -0800
committerAdam Soltys <[email protected]>2024-11-19 13:50:35 -0800
commit5642b90b54084061cdbbf6f1dc70c38245b05d5f (patch)
tree7bee78564f1e2dfa327b1d2361ce713721a822ba /routes
parent947474e5e507b2bfcec5aeb2b0ad8e058703dbd7 (diff)
downloadcoinos-server-5642b90b54084061cdbbf6f1dc70c38245b05d5f.tar.gz
coinos-server-5642b90b54084061cdbbf6f1dc70c38245b05d5f.zip
min fee 5 sats
Diffstat (limited to 'routes')
-rw-r--r--routes/payments.ts3
1 files changed, 2 insertions, 1 deletions
diff --git a/routes/payments.ts b/routes/payments.ts
index c8fd07dd..5a6eba91 100644
--- a/routes/payments.ts
+++ b/routes/payments.ts
@@ -157,9 +157,10 @@ export default {
params: { hash },
} = req;
const p = await getPayment(hash);
- if (p.type === types.internal) p.with = await g(`user:${p.ref}`);
+ if (p?.type === types.internal) p.with = await g(`user:${p.ref}`);
res.send(p);
} catch (e) {
+ console.log(e);
err("failed to get payment", e.message);
bail(res, e.message);
}