backup - wire cancellation into backup() method

This commit is contained in:
Benjamin Pasero
2020-10-17 09:25:26 +02:00
parent 24876cda75
commit 41e73c836f
12 changed files with 138 additions and 80 deletions

View File

@@ -567,7 +567,7 @@ class MainThreadCustomEditorModel extends Disposable implements ICustomEditorMod
}
}
public async backup(): Promise<IWorkingCopyBackup> {
public async backup(token: CancellationToken): Promise<IWorkingCopyBackup> {
const editors = this._getEditors();
if (!editors.length) {
throw new Error('No editors found for resource, cannot back up');