From 2aa24d19ee9c8d6b579a98a8fe6dd49243659096 Mon Sep 17 00:00:00 2001 From: lingdocs <71590811+lingdocs@users.noreply.github.com> Date: Sun, 22 Aug 2021 17:15:58 +0400 Subject: [PATCH] reorder --- account/src/routers/api-router.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/account/src/routers/api-router.ts b/account/src/routers/api-router.ts index f4a4d9a..338ff39 100644 --- a/account/src/routers/api-router.ts +++ b/account/src/routers/api-router.ts @@ -135,10 +135,8 @@ apiRouter.put("/user/upgrade", async (req, res, next) => { apiRouter.delete("/user", async (req, res, next) => { try { if (!req.user) throw new Error("user not found"); - await Promise.all([ - deleteWordlistDatabase(req.user.userId), - deleteLingdocsUser(req.user.userId), - ]); + await deleteWordlistDatabase(req.user.userId), + await deleteLingdocsUser(req.user.userId), sendResponse(res, { ok: true, message: "user deleted" }); } catch (e) { next(e);