From 01ab6b88ea99e9e4641975db54ae8426e5c9904f Mon Sep 17 00:00:00 2001 From: Sam Atkins Date: Wed, 1 May 2024 10:38:33 +0100 Subject: [PATCH] chore: Remove unused uses of uuid_user in save_account.js The variable doesn't exist, and we never use it after this. Seems like a copy-paste error. Solves these eslint errors: /puter/packages/backend/src/routers/save_account.js 90:9 error 'uuid_user' is not defined no-undef 91:9 error 'uuid_user' is not defined no-undef 91:21 error 'uuid_user' is not defined no-undef --- packages/backend/src/routers/save_account.js | 5 ----- 1 file changed, 5 deletions(-) diff --git a/packages/backend/src/routers/save_account.js b/packages/backend/src/routers/save_account.js index de58daf3c..d28c52f1e 100644 --- a/packages/backend/src/routers/save_account.js +++ b/packages/backend/src/routers/save_account.js @@ -85,11 +85,6 @@ router.post('/save_account', auth, express.json(), async (req, res, next)=>{ // get pseudo user, if exists let pseudo_user = await db.read(`SELECT * FROM user WHERE email = ? AND password IS NULL`, [req.body.email]); pseudo_user = pseudo_user[0]; - // get uuid user, if exists - if(req.body.uuid){ - uuid_user = await db.read(`SELECT * FROM user WHERE uuid = ? LIMIT 1`, [req.body.uuid]); - uuid_user = uuid_user[0]; - } // send_confirmation_code req.body.send_confirmation_code = req.body.send_confirmation_code ?? true;