refactor: add version to session endpoint

This commit is contained in:
Carlos Valente
2025-06-19 18:51:40 +02:00
committed by Carlos Valente
parent 08d9e24871
commit cd40a6e55e
2 changed files with 3 additions and 0 deletions
@@ -10,6 +10,7 @@ import { getNetworkInterfaces } from '../../utils/network.js';
import { getTimezoneLabel } from '../../utils/time.js'; import { getTimezoneLabel } from '../../utils/time.js';
import { password, routerPrefix } from '../../externals.js'; import { password, routerPrefix } from '../../externals.js';
import { hashPassword } from '../../utils/hash.js'; import { hashPassword } from '../../utils/hash.js';
import { ONTIME_VERSION } from '../../ONTIME_VERSION.js';
const startedAt = new Date(); const startedAt = new Date();
@@ -28,6 +29,7 @@ export async function getSessionStats(): Promise<SessionStats> {
projectName: filename, projectName: filename,
playback, playback,
timezone: getTimezoneLabel(startedAt), timezone: getTimezoneLabel(startedAt),
version: ONTIME_VERSION,
}; };
} }
@@ -14,6 +14,7 @@ export interface SessionStats {
projectName: string; projectName: string;
playback: Playback; playback: Playback;
timezone: string; timezone: string;
version: string;
} }
export interface GetInfo { export interface GetInfo {