MCPcopy
hub / github.com/codeaashu/claude-code / recycle

Method recycle

src/server/web/public/terminal.js:2387–2390  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2385 this._array[this._getCyclicIndex(this._length)] = e3, this._length === this._maxLength ? (this._startIndex = ++this._startIndex % this._maxLength, this.onTrimEmitter.fire(1)) : this._length++;
2386 }
2387 recycle() {
2388 if (this._length !== this._maxLength) throw new Error("Can only recycle when the buffer is full");
2389 return this._startIndex = ++this._startIndex % this._maxLength, this.onTrimEmitter.fire(1), this._array[this._getCyclicIndex(this._length - 1)];
2390 }
2391 get isFull() {
2392 return this._length === this._maxLength;
2393 }

Callers 1

scrollMethod · 0.80

Calls 2

_getCyclicIndexMethod · 0.95
fireMethod · 0.80

Tested by

no test coverage detected