Skip to content

Commit bd471a2

Browse files
committed
use same condition for scratchpads as untitled
1 parent 1c816b0 commit bd471a2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/vs/workbench/services/workingCopy/electron-sandbox/workingCopyBackupTracker.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ export class NativeWorkingCopyBackupTracker extends WorkingCopyBackupTracker imp
303303
}
304304

305305
private doSaveAllBeforeShutdown(modifiedWorkingCopies: IWorkingCopy[], reason: SaveReason): Promise<void>;
306-
private doSaveAllBeforeShutdown(includeUntitled: boolean, reason: SaveReason): Promise<void>;
306+
private doSaveAllBeforeShutdown(includeAllUntitled: boolean, reason: SaveReason): Promise<void>;
307307
private doSaveAllBeforeShutdown(arg1: IWorkingCopy[] | boolean, reason: SaveReason): Promise<void> {
308308
const modifiedWorkingCopies = Array.isArray(arg1) ? arg1 : this.workingCopyService.modifiedWorkingCopies.filter(workingCopy => {
309309
if (arg1 === false && (workingCopy.capabilities & WorkingCopyCapabilities.Untitled)) {
@@ -324,7 +324,7 @@ export class NativeWorkingCopyBackupTracker extends WorkingCopyBackupTracker imp
324324
let result: boolean | undefined = undefined;
325325
if (typeof arg1 === 'boolean' || modifiedWorkingCopies.length === this.workingCopyService.modifiedCount) {
326326
result = (await this.editorService.saveAll({
327-
includeScratchpad: true,
327+
includeScratchpad: typeof arg1 === 'boolean' ? arg1 : true,
328328
includeUntitled: typeof arg1 === 'boolean' ? arg1 : true,
329329
...saveOptions
330330
})).success;

0 commit comments

Comments
 (0)