refresh also now clears messages from client

This commit is contained in:
hippoz 2020-12-02 23:44:59 +02:00
parent d0025b4221
commit 818cb1afc6

View file

@ -240,6 +240,10 @@ const app = new Vue({
}); });
this.gateway.socket.on('refreshClient', (e) => { this.gateway.socket.on('refreshClient', (e) => {
console.log('[*] [gateway] Gateway requested refresh', e); console.log('[*] [gateway] Gateway requested refresh', e);
this.gateway.disconnect();
this.messages = {};
this.userLists = {};
this.message.typed = '';
if (e.reason === 'exit') { if (e.reason === 'exit') {
this.showApp = false; this.showApp = false;
this.okNotification('The server has exited. Sit tight!'); this.okNotification('The server has exited. Sit tight!');