diff --git a/app/src/mobile/menu/search.ts b/app/src/mobile/menu/search.ts index 9d4752b09..c49d8f09e 100644 --- a/app/src/mobile/menu/search.ts +++ b/app/src/mobile/menu/search.ts @@ -573,7 +573,7 @@ const initSearchEvent = (app: App, element: Element, config: ISearchOption) => { } else if (target.getAttribute("data-type") === "search-item") { const id = target.getAttribute("data-node-id"); if (id) { - if (window.siyuan.mobile.editor.protyle) { + if (window.siyuan.mobile.editor?.protyle) { preventScroll(window.siyuan.mobile.editor.protyle); } checkFold(id, (zoomIn) => {