From 009a0243e0e724d139355eb1ef4f7d845ad4175d Mon Sep 17 00:00:00 2001 From: Gordon Nicholas Date: Sat, 21 Dec 2024 00:00:41 +0100 Subject: [PATCH] N21-2103 fix configs --- .../src/infra/sync/media-licenses/vidis-sync-config.ts | 2 +- apps/server/src/infra/vidis-client/vidis-client-config.ts | 2 +- apps/server/src/modules/server/server.config.ts | 8 ++++++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/apps/server/src/infra/sync/media-licenses/vidis-sync-config.ts b/apps/server/src/infra/sync/media-licenses/vidis-sync-config.ts index d49bf142ab..5e0b6c51e7 100644 --- a/apps/server/src/infra/sync/media-licenses/vidis-sync-config.ts +++ b/apps/server/src/infra/sync/media-licenses/vidis-sync-config.ts @@ -1,3 +1,3 @@ export interface VidisSyncConfig { - VIDIS_SYNC_REGION: string; + VIDIS_SYNC_REGION: string | undefined; } diff --git a/apps/server/src/infra/vidis-client/vidis-client-config.ts b/apps/server/src/infra/vidis-client/vidis-client-config.ts index 9b6970d637..5bd526e731 100644 --- a/apps/server/src/infra/vidis-client/vidis-client-config.ts +++ b/apps/server/src/infra/vidis-client/vidis-client-config.ts @@ -1,3 +1,3 @@ export interface VidisClientConfig { - VIDIS_API_CLIENT_BASE_URL: string; + VIDIS_API_CLIENT_BASE_URL: string | undefined; } diff --git a/apps/server/src/modules/server/server.config.ts b/apps/server/src/modules/server/server.config.ts index 37c6020004..81b2895398 100644 --- a/apps/server/src/modules/server/server.config.ts +++ b/apps/server/src/modules/server/server.config.ts @@ -325,8 +325,12 @@ const config: ServerConfig = { FEATURE_OAUTH_LOGIN: Configuration.get('FEATURE_OAUTH_LOGIN') as boolean, FEATURE_EXTERNAL_SYSTEM_LOGOUT_ENABLED: Configuration.get('FEATURE_EXTERNAL_SYSTEM_LOGOUT_ENABLED') as boolean, PUBLIC_BACKEND_URL: Configuration.get('PUBLIC_BACKEND_URL') as string, - VIDIS_API_CLIENT_BASE_URL: Configuration.get('VIDIS_API_CLIENT_BASE_URL') as string, - VIDIS_SYNC_REGION: Configuration.get('VIDIS_SYNC_REGION') as string, + VIDIS_API_CLIENT_BASE_URL: Configuration.has('VIDIS_API_CLIENT_BASE_URL') + ? (Configuration.get('VIDIS_API_CLIENT_BASE_URL') as string) + : undefined, + VIDIS_SYNC_REGION: Configuration.has('VIDIS_SYNC_REGION') + ? (Configuration.get('VIDIS_SYNC_REGION') as string) + : undefined, }; export const serverConfig = () => config;