Skip to content

Commit 2b89529

Browse files
committed
fix: #1454, #1468
1 parent eaa0644 commit 2b89529

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/modules/editor/menu.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,11 @@ import { getEditorCore } from "../../utils/editor";
1212
export function initEditorMenu(editor: Zotero.EditorInstance) {
1313
const makeId = (key: string) =>
1414
`${config.addonRef}-editor-menu-${editor.instanceID}-${key}`;
15+
16+
if (editor._popup.dataset.bnMenuInitialized === "true") {
17+
return;
18+
}
19+
editor._popup.dataset.bnMenuInitialized = "true";
1520
(editor._popup as XULMenuElement).addEventListener(
1621
"popupshowing",
1722
async (ev) => {

0 commit comments

Comments
 (0)