From fa5b05a4cbdeeca75b472ca152591e1428f5508e Mon Sep 17 00:00:00 2001 From: Bobby Date: Sun, 26 Jun 2022 20:16:18 +0530 Subject: replace www. subdomain with empty string for profile redirect --- routes/account.routes.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/routes/account.routes.js b/routes/account.routes.js index f833c63f..b07c7d40 100644 --- a/routes/account.routes.js +++ b/routes/account.routes.js @@ -33,7 +33,7 @@ router.get("/", (req, res) => { avatar: md5(user.gravatarEmail || user.email || ""), url: user.public == 1 - ? `${req.protocol + "://" + user.username + '.' + req.get("host")}` + ? `${req.protocol + "://" + user.username + '.' + req.get("host")}`.replace('www.', '') : "", }, }); -- cgit v1.2.3