fix(core): update

This commit is contained in:
Philipp Kunz 2020-09-30 00:20:53 +00:00
parent 38f017934c
commit ca7470eedf
2 changed files with 4 additions and 3 deletions

View File

@ -60,8 +60,10 @@ export class Smartsocket {
public async stop() { public async stop() {
await plugins.smartdelay.delayFor(1000); await plugins.smartdelay.delayFor(1000);
this.socketConnections.forEach((socketObjectArg: SocketConnection) => { this.socketConnections.forEach((socketObjectArg: SocketConnection) => {
logger.log('info', `disconnect socket with >>alias ${socketObjectArg.alias}`); if (socketObjectArg) {
socketObjectArg.socket.disconnect(); logger.log('info', `disconnect socket with >>alias ${socketObjectArg.alias}`);
socketObjectArg.socket.disconnect();
}
}); });
this.socketConnections.wipe(); this.socketConnections.wipe();
this.io.close(); this.io.close();

View File

@ -14,7 +14,6 @@ export class SocketServer {
private httpServer: pluginsTyped.http.Server | pluginsTyped.https.Server; private httpServer: pluginsTyped.http.Server | pluginsTyped.https.Server;
// wether httpServer is standalone // wether httpServer is standalone
private standaloneServer = false; private standaloneServer = false;
private expressServer: any;
constructor(smartSocketInstance: Smartsocket) { constructor(smartSocketInstance: Smartsocket) {
this.smartsocket = smartSocketInstance; this.smartsocket = smartSocketInstance;