diff --git a/src/Disposable.ts b/src/Disposable.ts index 0f168b107..83a08dc32 100644 --- a/src/Disposable.ts +++ b/src/Disposable.ts @@ -1,20 +1,20 @@ /*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -export default class Disposable { - private onDispose: {(): void}; - - constructor (onDispose: {(): void}){ - if (!onDispose) { - throw new Error("onDispose cannot be null or empty."); - } - - this.onDispose = onDispose; - } - - public dispose(): void { - this.onDispose(); - } + *--------------------------------------------------------------------------------------------*/ + +export default class Disposable { + private onDispose: { (): void }; + + constructor(onDispose: { (): void }) { + if (!onDispose) { + throw new Error("onDispose cannot be null or empty."); + } + + this.onDispose = onDispose; + } + + public dispose = (): void => { + this.onDispose(); + } }