Use readonly over getter for exposing events

Fixes #4164
This commit is contained in:
Daniel Imms
2022-10-01 07:52:26 -07:00
parent 2659de2291
commit cf9949840b
24 changed files with 78 additions and 81 deletions
+2 -1
View File
@@ -41,8 +41,9 @@ export class WriteBuffer {
private _isSyncWriting = false;
private _syncCalls = 0;
private _didUserInput = false;
public get onWriteParsed(): IEvent<void> { return this._onWriteParsed.event; }
private _onWriteParsed = new EventEmitter<void>();
public readonly onWriteParsed = this._onWriteParsed.event;
constructor(private _action: (data: string | Uint8Array, promiseResult?: boolean) => void | Promise<boolean>) { }