From a89845febf4ad2ecc5379103c5988b8a018599cf Mon Sep 17 00:00:00 2001 From: hunshnet <337490703@qq.com> Date: Tue, 9 Jun 2020 19:36:56 +0800 Subject: [PATCH] fix index.js, issue #9 --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index 0136700..13f358b 100644 --- a/index.js +++ b/index.js @@ -69,7 +69,7 @@ async function fetchHandler(e) { const exp2 = /^(?:https?:\/\/)?github\.com\/.+?\/.+?\/(?:blob)\/.*$/i const exp3 = /^(?:https?:\/\/)?github\.com\/.+?\/.+?\/(?:info|git-upload-pack).*$/i const exp4 = /^(?:https?:\/\/)?raw\.githubusercontent\.com\/.+?\/.+?\/.+?\/.+$/i - if (path.search(exp1) === 0 || !Config.cnpmjs && (path.search(exp3) === 0 || path.search(exp4))) { + if (path.search(exp1) === 0 || !Config.cnpmjs && (path.search(exp3) === 0 || path.search(exp4) === 0)) { return httpHandler(req, path) } else if (path.search(exp2) === 0) { if (Config.jsdelivr){