From 543a66579e606a3ac9a8448b365938626126fc21 Mon Sep 17 00:00:00 2001 From: Mike Cao Date: Wed, 16 Sep 2020 09:25:14 -0700 Subject: [PATCH] Fix delete account issue. --- pages/api/account/[id].js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/api/account/[id].js b/pages/api/account/[id].js index c87f948b..6f9beac1 100644 --- a/pages/api/account/[id].js +++ b/pages/api/account/[id].js @@ -9,7 +9,7 @@ export default async (req, res) => { const { id } = req.query; const user_id = +id; - if (is_admin) { + if (!is_admin) { return unauthorized(res); }