diff --git a/scripts/helper/uk-paginator.js b/scripts/helper/uk-paginator.js index 3c6541a..75a6c4e 100644 --- a/scripts/helper/uk-paginator.js +++ b/scripts/helper/uk-paginator.js @@ -10,6 +10,12 @@ hexo.extend.helper.register("uk_paginator", function(option) { mainClasses: [], itemClasses: [], }, option); + const pagePathReplaced = options.pagePath.replace('/', '\/').replace('%d', '\\d+'); + console.log(pagePathReplaced); + const regPagePath = new RegExp(pagePathReplaced); + console.log(regPagePath); + options.base = options.base.replace(regPagePath, ''); + console.dir(options); let pageStructure = []; pageStructure.push(`