Skip to content

Commit cc334de

Browse files
committed
tweak
1 parent 4df01bd commit cc334de

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

test/-cases.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@
3939
function fetchPagePaths(content) {
4040
var pageList = [];
4141

42-
singleFetch(/"([^"]+\.html)\s*"/g);
43-
singleFetch(/'([^']+\.html)\s*'/g);
42+
singleFetch(/"([^"/]*\/)*([^"/]+\.html)\s*"/g);
43+
singleFetch(/'([^'/]*\/)*([^'/]+\.html)\s*'/g);
4444

4545
function singleFetch(pattern) {
4646
var result;
4747
while ((result = pattern.exec(content)) != null) {
48-
pageList.push(result[1]);
48+
pageList.push(result[result.length - 1]);
4949
}
5050
}
5151

0 commit comments

Comments
 (0)