From ed261b9f56d0a48bf65b473196a4976dbafac45b Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Wed, 1 Apr 2020 10:19:31 -0700 Subject: simplify currencies --- routes/users.js | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/routes/users.js b/routes/users.js index 855e804d..1fa04c6b 100644 --- a/routes/users.js +++ b/routes/users.js @@ -169,13 +169,8 @@ app.post("/user", auth, async (req, res) => { }); } - user.currencies = currencies; user.currency = currency; - if (currencies.length) { - if (!currencies.includes(currency)) user.currency = currencies[0]; - } else { - user.currency = null; - } + user.currencies = currencies; user.twofa = twofa; user.pin = pin; -- cgit v1.2.3