From ad4964103df0484c465d825991557aaebba3a09b Mon Sep 17 00:00:00 2001 From: Vanessa Date: Tue, 15 Jul 2025 18:07:28 +0800 Subject: [PATCH] :art: https://github.com/siyuan-note/siyuan/issues/15297 --- app/src/protyle/util/editorCommonEvent.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/protyle/util/editorCommonEvent.ts b/app/src/protyle/util/editorCommonEvent.ts index 37c1e559c..a7dea2c3e 100644 --- a/app/src/protyle/util/editorCommonEvent.ts +++ b/app/src/protyle/util/editorCommonEvent.ts @@ -816,7 +816,7 @@ export const dropEvent = (protyle: IProtyle, editorElement: HTMLElement) => { return; } let target = event.target as HTMLElement; - if (target.classList.contains("av__gallery-img")) { + if (target.classList?.contains("av__gallery-img")) { target = hasClosestByClassName(target, "av__gallery-item") as HTMLElement; } if (!target) {