Skip to content
This repository was archived by the owner on May 21, 2019. It is now read-only.

Commit 28299ba

Browse files
committed
Fix the issue when a storage wasn't updated on removeToEnd.
1 parent f0cdbbf commit 28299ba

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ScreenBuffer.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ export class ScreenBuffer extends events.EventEmitter {
240240

241241
clearToEnd() {
242242
this.clearRowToEnd();
243-
this.storage.splice(this.cursorPosition.row + 1, Number.MAX_VALUE);
243+
this.storage = this.storage.splice(this.cursorPosition.row + 1, this.storage.size - this.cursorPosition.row).toList();
244244
this.emitData();
245245
}
246246

0 commit comments

Comments
 (0)