From b0b0d2356e76c376c980a08493a6b28b9eeeec0a Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Thu, 26 Sep 2024 23:04:09 +0000 Subject: nwc --- lib/nwc.ts | 3 ++- routes/locations.ts | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/nwc.ts b/lib/nwc.ts index 4ea4e8a8..973d7263 100644 --- a/lib/nwc.ts +++ b/lib/nwc.ts @@ -114,7 +114,8 @@ let handle = (method, params, user) => }, async get_balance() { - let balance = await g(`balance:${user.id}`) * 1000; + let balance = await g(`balance:${user.id}`); + balance *= 1000; return result({ balance }); }, diff --git a/routes/locations.ts b/routes/locations.ts index e9a6843c..5aaeb02b 100644 --- a/routes/locations.ts +++ b/routes/locations.ts @@ -1,7 +1,7 @@ import { g } from "$lib/db"; export default { - async list(req, res) { + async list(_, res) { let locations = await g("locations"); res.send({ locations }); }, -- cgit v1.2.3