From f7d7625c1c0fcd82787bc9b5b594bc7e50e90447 Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Sun, 16 Jun 2024 05:48:40 -0400 Subject: [PATCH] Redownload file marked as a forced download when opening file Previously we were redownloading only `SYNC_STATE_TO_DOWNLOAD` files, not `SYNC_STATE_FORCE_DOWNLOAD`, because the latter gets downloaded even when using on-demand file syncing, but if the download fails for some reason, it should be retried on a manual open. --- chrome/content/zotero/zoteroPane.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/chrome/content/zotero/zoteroPane.js b/chrome/content/zotero/zoteroPane.js index 76599f9359..a5016a8a5b 100644 --- a/chrome/content/zotero/zoteroPane.js +++ b/chrome/content/zotero/zoteroPane.js @@ -4817,7 +4817,10 @@ var ZoteroPane = new function() if (fileExists && !isLinkedFile && fileSyncingEnabled - && (item.attachmentSyncState == Zotero.Sync.Storage.Local.SYNC_STATE_TO_DOWNLOAD)) { + && ([ + Zotero.Sync.Storage.Local.SYNC_STATE_TO_DOWNLOAD, + Zotero.Sync.Storage.Local.SYNC_STATE_FORCE_DOWNLOAD + ].includes(item.attachmentSyncState))) { Zotero.debug("File exists but is queued for download -- re-downloading"); redownload = true; }