mirror of
https://github.com/d0zingcat/NotionNext.git
synced 2026-05-14 07:26:52 +00:00
修复搜索bug
This commit is contained in:
@@ -120,7 +120,10 @@ async function filterByMemCache (allPosts, keyword) {
|
||||
let hitCount = 0
|
||||
for (const i in indexContent) {
|
||||
const c = indexContent[i]
|
||||
const index = c.toLowerCase().indexOf(keyword.toLowerCase())
|
||||
if (!c) {
|
||||
continue
|
||||
}
|
||||
const index = c.toLowerCase().indexOf(keyword.toLowerCase()) || -1
|
||||
if (index > -1) {
|
||||
hit = true
|
||||
hitCount += 1
|
||||
|
||||
Reference in New Issue
Block a user