From 1d84cefa84c0a83a8f7aa8b36b6a5769d01ae9d0 Mon Sep 17 00:00:00 2001 From: Phil Kunz Date: Sun, 1 Sep 2019 21:27:45 +0200 Subject: [PATCH] fix(core): update --- ts/smartuniverse.classes.universe.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ts/smartuniverse.classes.universe.ts b/ts/smartuniverse.classes.universe.ts index 8656836..9ab040f 100644 --- a/ts/smartuniverse.classes.universe.ts +++ b/ts/smartuniverse.classes.universe.ts @@ -160,12 +160,13 @@ export class Universe { this.smartsocket.addSocketFunction(socketFunctionSubscription); this.smartsocket.addSocketFunction(socketFunctionProcessMessage); - // add smartsocket to the running smartexpress app - await this.smartsocket.setExternalServer('smartexpress', this.smartexpressServer); - // start everything + // start the server if (!this.options.externalServer) { await this.smartexpressServer.start(); } + + // add smartsocket to the running smartexpress app + await this.smartsocket.setExternalServer('smartexpress', this.smartexpressServer); await this.smartsocket.start(); plugins.smartlog.defaultLogger.log('success', 'started universe'); }