瀏覽代碼

:art: fix https://github.com/siyuan-note/siyuan/issues/9717

Vanessa 1 年之前
父節點
當前提交
cd0900f0a5
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      app/src/mobile/menu/search.ts

+ 1 - 1
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") {
                 } else if (target.getAttribute("data-type") === "search-item") {
                     const id = target.getAttribute("data-node-id");
                     const id = target.getAttribute("data-node-id");
                     if (id) {
                     if (id) {
-                        if (window.siyuan.mobile.editor.protyle) {
+                        if (window.siyuan.mobile.editor?.protyle) {
                             preventScroll(window.siyuan.mobile.editor.protyle);
                             preventScroll(window.siyuan.mobile.editor.protyle);
                         }
                         }
                         checkFold(id, (zoomIn) => {
                         checkFold(id, (zoomIn) => {