remote - unhook providers on dispose

This commit is contained in:
Johannes Rieken
2018-01-10 15:12:13 -08:00
parent 22170c2bf6
commit 5c8c83419e

View File

@@ -19,7 +19,6 @@ import { onUnexpectedError } from 'vs/base/common/errors';
@extHostNamedCustomer(MainContext.MainThreadFileSystem)
export class MainThreadFileSystem implements MainThreadFileSystemShape {
private readonly _toDispose: IDisposable[] = [];
private readonly _proxy: ExtHostFileSystemShape;
private readonly _provider = new Map<number, RemoteFileSystemProvider>();
@@ -33,7 +32,8 @@ export class MainThreadFileSystem implements MainThreadFileSystemShape {
}
dispose(): void {
dispose(this._toDispose);
this._provider.forEach(value => dispose());
this._provider.clear();
}
$registerFileSystemProvider(handle: number, scheme: string): void {