Răsfoiți Sursa

don't auto-close tabs of cancelled saves

Former-commit-id: 6ded4784ed1292236d8cc4bc58f02073cd157dc5
Gildas 6 ani în urmă
părinte
comite
60e4b6c7c5
1 a modificat fișierele cu 2 adăugiri și 1 ștergeri
  1. 2 1
      extension/core/bg/business.js

+ 2 - 1
extension/core/bg/business.js

@@ -100,8 +100,9 @@ singlefile.extension.core.bg.business = (() => {
 						promiseSaveTab = Promise.resolve();
 					}
 					saveTabs(tabs, options);
+					const saveInfo = pendingSaves.get(tabId);
 					await promiseSaveTab;
-					if (tabOptions.autoClose) {
+					if (tabOptions.autoClose && !saveInfo.cancelled) {
 						singlefile.extension.core.bg.tabs.remove(tabId);
 					}
 				}