From fad595923a68fd67fdc81c83e96ff7b85d23711c Mon Sep 17 00:00:00 2001 From: "Patrik J. Braun" Date: Thu, 10 Sep 2020 19:40:44 +0200 Subject: [PATCH] Update Config.ts fixing uptime --- src/common/config/private/Config.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/common/config/private/Config.ts b/src/common/config/private/Config.ts index e21ac87e..4cf8cc82 100644 --- a/src/common/config/private/Config.ts +++ b/src/common/config/private/Config.ts @@ -8,6 +8,8 @@ import {ConfigProperty, IConfigClass} from 'typeconfig/common'; declare const process: any; +consts upTime = (new Date()).toISOString(); + @ConfigClass({ configPath: path.join(__dirname, './../../../../config.json'), saveIfNotExist: true, @@ -46,7 +48,7 @@ export class PrivateConfigClass implements IPrivateConfig { this.Server.Environment.appVersion = require('../../../../package.json').version; this.Server.Environment.buildTime = require('../../../../package.json').buildTime; this.Server.Environment.buildCommitHash = require('../../../../package.json').buildCommitHash; - this.Server.Environment.upTime = (new Date()).toISOString(); + this.Server.Environment.upTime = upTime; this.Server.Environment.isDocker = !!process.env['PI_DOCKER']; }