fix: skip auto-sync for all opened notes

This commit is contained in:
windingwind 2024-10-21 15:50:39 +02:00
parent 99d8bb4679
commit 10fc0d5706

View File

@ -66,11 +66,11 @@ async function callSyncing(
if (skipActive) {
// Skip active note editors' targets
const activeNoteIds = Zotero.Notes._editorInstances
.filter(
(editor) =>
!Components.utils.isDeadWrapper(editor._iframeWindow) &&
editor._iframeWindow.document.hasFocus(),
)
// .filter(
// (editor) =>
// !Components.utils.isDeadWrapper(editor._iframeWindow) &&
// editor._iframeWindow.document.hasFocus(),
// )
.map((editor) => editor._item.id);
const filteredItems = items.filter(
(item) => !activeNoteIds.includes(item.id),