From 49059c5e6734a61654f7f2f9c6cc8ee35a7b68b9 Mon Sep 17 00:00:00 2001 From: Wei Wang Date: Mon, 23 Apr 2018 14:42:43 +0900 Subject: [PATCH] Update isActive logic to always checking equality --- lib/default-theme/util.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/lib/default-theme/util.js b/lib/default-theme/util.js index e5a859be25..5aafb431bb 100644 --- a/lib/default-theme/util.js +++ b/lib/default-theme/util.js @@ -46,11 +46,7 @@ export function isActive (route, path) { } const routePath = normalize(route.path) const pagePath = normalize(path) - if (endingSlashRE.test(routePath) || endingSlashRE.test(pagePath)) { - return routePath === pagePath - } else { - return routePath.indexOf(pagePath) === 0 - } + return routePath === pagePath } export function resolvePage (pages, rawPath, base) {