mirror of
https://github.com/d0zingcat/NotionNext.git
synced 2026-06-09 15:10:39 +00:00
修复搜索bug
This commit is contained in:
@@ -120,7 +120,10 @@ async function filterByMemCache (allPosts, keyword) {
|
|||||||
let hitCount = 0
|
let hitCount = 0
|
||||||
for (const i in indexContent) {
|
for (const i in indexContent) {
|
||||||
const c = indexContent[i]
|
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) {
|
if (index > -1) {
|
||||||
hit = true
|
hit = true
|
||||||
hitCount += 1
|
hitCount += 1
|
||||||
|
|||||||
Reference in New Issue
Block a user