diff options
-rw-r--r-- | src/views/Control/Kvm/KvmConsole.vue | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/views/Control/Kvm/KvmConsole.vue b/src/views/Control/Kvm/KvmConsole.vue index d7ec31e0..c028a9fc 100644 --- a/src/views/Control/Kvm/KvmConsole.vue +++ b/src/views/Control/Kvm/KvmConsole.vue @@ -94,11 +94,16 @@ export default { }, beforeDestroy() { window.removeEventListener('resize', this.resizeKvmWindow); + this.closeTerminal(); }, methods: { sendCtrlAltDel() { this.rfb.sendCtrlAltDel(); }, + closeTerminal() { + this.rfb.disconnect(); + this.rfb = null; + }, openTerminal() { const token = this.$store.getters['authentication/token']; this.rfb = new RFB( |