mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Remove unnecesarry TerminalApi.destroy and TerminalApi.reconnect overloads (#4538)
This commit is contained in:
parent
747ef8daee
commit
181197fad8
@ -144,18 +144,6 @@ export class TerminalApi extends WebSocketApi<TerminalEvents> {
|
|||||||
this.socket.binaryType = "arraybuffer";
|
this.socket.binaryType = "arraybuffer";
|
||||||
}
|
}
|
||||||
|
|
||||||
destroy() {
|
|
||||||
if (!this.socket) return;
|
|
||||||
const controlCode = String.fromCharCode(4); // ctrl+d
|
|
||||||
|
|
||||||
this.sendMessage({ type: TerminalChannels.STDIN, data: controlCode });
|
|
||||||
setTimeout(() => super.destroy(), 2000);
|
|
||||||
}
|
|
||||||
|
|
||||||
reconnect() {
|
|
||||||
super.reconnect();
|
|
||||||
}
|
|
||||||
|
|
||||||
sendMessage(message: TerminalMessage) {
|
sendMessage(message: TerminalMessage) {
|
||||||
return this.send(serialize(message));
|
return this.send(serialize(message));
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user