Skip to content

Commit 9e04b43

Browse files
committed
fix(search): remove extra /index from routes
1 parent 7dfe9d2 commit 9e04b43

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/node/plugins/localSearchPlugin.ts

+1
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ export async function localSearchPlugin(
9898
let relFile = path.relative(siteConfig.srcDir, file)
9999
relFile = siteConfig.rewrites.map[relFile] || relFile
100100
let id = path.join(siteConfig.site.base, relFile)
101+
id = id.replace(/\/index\.md$/, '/')
101102
id = id.replace(/\.md$/, siteConfig.cleanUrls ? '' : '.html')
102103
return id
103104
}

0 commit comments

Comments
 (0)