mirror of
https://github.com/microsoft/vscode.git
synced 2026-05-08 17:19:48 +01:00
workspaces - do not leave stale untitled workspaces around
This commit is contained in:
@@ -200,8 +200,11 @@ export abstract class AbstractWorkspaceEditingService implements IWorkspaceEditi
|
||||
const remoteAuthority = this.environmentService.configuration.remoteAuthority;
|
||||
const untitledWorkspace = await this.workspacesService.createUntitledWorkspace(folders, remoteAuthority);
|
||||
if (path) {
|
||||
await this.saveWorkspaceAs(untitledWorkspace, path);
|
||||
await this.workspacesService.deleteUntitledWorkspace(untitledWorkspace); // https://github.com/microsoft/vscode/issues/100276
|
||||
try {
|
||||
await this.saveWorkspaceAs(untitledWorkspace, path);
|
||||
} finally {
|
||||
await this.workspacesService.deleteUntitledWorkspace(untitledWorkspace); // https://github.com/microsoft/vscode/issues/100276
|
||||
}
|
||||
} else {
|
||||
path = untitledWorkspace.configPath;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user