lib: Fix so it displays the restart message during restart
All checks were successful
continuous-integration/appveyor/branch AppVeyor build succeeded

This commit is contained in:
Jonatan Nilsson 2022-03-30 08:19:49 +00:00
parent 23f9173720
commit b5359515b5

View file

@ -37,8 +37,8 @@ export default class ServiceCore {
async init(module = null) { async init(module = null) {
this.db = await GetDB(this.config, this.log, this.dbfilename) this.db = await GetDB(this.config, this.log, this.dbfilename)
this.core = new Core(this.db, this.util, this.log, () => { this.core = new Core(this.db, this.util, this.log, (msg) => {
let err = new Error('Got request to restart') let err = new Error('Got request to restart' + (msg ? ': ' + msg : ''))
this.log.fatal(err) this.log.fatal(err)
process.exit(0) process.exit(0)
}) })