High performance self-hosted photo and video management solution.
TypeScript backup-toolfluttergoogle-photosgoogle-photos-alternativejavascriptmobile-appnestjsnodejsphoto-galleryphotosphotos-managementself-hostedsveltesveltekittypescriptvideos
chore(server): use fs to read package.json (#6692)
Daniel Dietzlere9333837bfa8
diff --git a/server/src/domain/domain.constant.ts b/server/src/domain/domain.constant.tsindex 8b101a1b68..5589eb15a6 100644--- a/server/src/domain/domain.constant.ts+++ b/server/src/domain/domain.constant.ts@@ -1,7 +1,9 @@import { AssetType } from '@app/infra/entities';import { Duration } from 'luxon';+import { readFileSync } from 'node:fs';import { extname, join } from 'node:path';-import pkg from 'src/../../package.json';++const pkg = JSON.parse(readFileSync('./package.json', 'utf-8'));export const AUDIT_LOG_MAX_DURATION = Duration.fromObject({ days: 100 });export const ONE_HOUR = Duration.fromObject({ hours: 1 });