Remove extra indirection in toDisposable

This commit is contained in:
Matt Bierner
2019-06-04 15:15:01 -07:00
parent a1c5ded681
commit 025c005ffc
+1 -1
View File
@@ -34,7 +34,7 @@ export function combinedDisposable(...disposables: IDisposable[]): IDisposable {
}
export function toDisposable(fn: () => void): IDisposable {
return { dispose() { fn(); } };
return { dispose: fn };
}
export class DisposableStore implements IDisposable {