From ba41c7db056c40bbbda7f3b489d669d93cd87753 Mon Sep 17 00:00:00 2001 From: Vanessa Date: Tue, 17 Jan 2023 00:50:33 +0800 Subject: [PATCH] :recycle: https://github.com/siyuan-note/siyuan/pull/7089/files --- app/src/layout/util.ts | 2 +- app/src/mobile/util/initFramework.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/layout/util.ts b/app/src/layout/util.ts index 27b68f0f8..1ee0cc717 100644 --- a/app/src/layout/util.ts +++ b/app/src/layout/util.ts @@ -300,7 +300,7 @@ export const JSONToLayout = (isStart: boolean) => { } // https://github.com/siyuan-note/siyuan/pull/7086 const openId = getSearch("id"); - if (openId !== null) { + if (openId) { openFileById({ id: openId, action: [Constants.CB_GET_FOCUS, Constants.CB_GET_CONTEXT], diff --git a/app/src/mobile/util/initFramework.ts b/app/src/mobile/util/initFramework.ts index 3b589e105..fb42cce9b 100644 --- a/app/src/mobile/util/initFramework.ts +++ b/app/src/mobile/util/initFramework.ts @@ -129,7 +129,7 @@ export const initFramework = () => { initEditorName(); if (getOpenNotebookCount() > 0) { const openId = getSearch("id"); - if (openId !== null) { + if (openId) { openMobileFileById(openId, getSearch("focus") === "1" ? [Constants.CB_GET_ALL, Constants.CB_GET_FOCUS] : [Constants.CB_GET_FOCUS, Constants.CB_GET_CONTEXT]); } else {