From 359ad9396389c138d56925be9e051dea4c384a8d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=8F=E8=99=8E=E6=95=85=E6=B4=9E?= <55782476+TigerCubDen@users.noreply.github.com> Date: Wed, 17 Feb 2021 19:49:40 +0800 Subject: [PATCH] Update changelog.js --- lib/routes/changelog.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/routes/changelog.js b/lib/routes/changelog.js index da75a40e26..1556d0d64b 100644 --- a/lib/routes/changelog.js +++ b/lib/routes/changelog.js @@ -39,10 +39,10 @@ module.exports = async (ctx) => { const patt = /[0-9]\d*/g; let result; let date = ""; - while ((result = patt.exec(str)) != null) { + while ((result = patt.exec(str)) !== null) { date += result + '-'; } - return date.replace(/\-$/g, ""); + return date.replace(/-$/g, ""); } return {