From 1ac8f4279e0e53e2d4e18b59ff4b54acee2d2c57 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Thu, 15 Dec 2022 13:35:30 -0800 Subject: prettier --- routes/invoices.js | 14 +++++++------- routes/locations.js | 12 +++++++----- routes/payments.js | 2 +- 3 files changed, 15 insertions(+), 13 deletions(-) (limited to 'routes') diff --git a/routes/invoices.js b/routes/invoices.js index 7fa82afb..d689775f 100644 --- a/routes/invoices.js +++ b/routes/invoices.js @@ -183,13 +183,13 @@ app.post("/invoice", optionalAuth, async (req, res, next) => { if (!existing) emit(request.requester.username, "invoice", { - amount: invoice.amount, - currency: invoice.currency, - rate: invoice.rate, - request_id, - uuid: invoice.uuid, - user: { username: user.username, profile: user.profile } - }); + amount: invoice.amount, + currency: invoice.currency, + rate: invoice.rate, + request_id, + uuid: invoice.uuid, + user: { username: user.username, profile: user.profile } + }); } } diff --git a/routes/locations.js b/routes/locations.js index 3e0fee4c..63bfe1a1 100644 --- a/routes/locations.js +++ b/routes/locations.js @@ -8,12 +8,14 @@ app.get("/locations", async (req, res) => { }); let getLocations = async () => { - let { data } = await axios.get('https://api.btcmap.org/v2/elements?updated_since=2022-09-19'); - locations = data.filter( - (l) => l['osm_json'].tags && l['osm_json'].tags['payment:coinos'] === 'yes' - ); + let { data } = await axios.get( + "https://api.btcmap.org/v2/elements?updated_since=2022-09-19" + ); + locations = data.filter( + l => l["osm_json"].tags && l["osm_json"].tags["payment:coinos"] === "yes" + ); setTimeout(getLocations, 60000); -} +}; getLocations(); diff --git a/routes/payments.js b/routes/payments.js index 96791bb3..da55f1ec 100644 --- a/routes/payments.js +++ b/routes/payments.js @@ -154,7 +154,7 @@ app.get("/payment/:redeemcode", async (req, res) => { }); payment = payment.get({ plain: true }); - payment.redeemer = payment['with']; + payment.redeemer = payment["with"]; if (!payment) fail("invalid code"); -- cgit v1.2.3