From d4ce7b4af1e10816871ffd4e2d263a3b3d678427 Mon Sep 17 00:00:00 2001 From: Sylvain Briat Date: Wed, 17 Jan 2024 15:35:09 +0100 Subject: [PATCH] fix bad geography types for geocoder providers --- src/config/geography.config.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/config/geography.config.ts b/src/config/geography.config.ts index b385daa..693b2b4 100644 --- a/src/config/geography.config.ts +++ b/src/config/geography.config.ts @@ -12,8 +12,8 @@ export interface GeographyConfig extends Config { geocoderConsolidate: boolean; geocoderProximity: number; geocoderPopulationPrioritizerCoef: number; - geocoderProviders: number[]; - geocoderProvidersFallback: string; + geocoderProviders: string[]; + geocoderProvidersFallback: string[]; } export default registerAs('geography', () => ({ @@ -49,5 +49,7 @@ export default registerAs('geography', () => ({ geocoderProviders: process.env.GEOCODER_PROVIDERS ? process.env.GEOCODER_PROVIDERS?.split(',') : ['ADDOK,PELIAS_SEARCH,PELIAS_AUTOCOMPLETE'], - geocoderProvidersFallback: process.env.GEOCODER_PROVIDERS_FALLBACK ?? 'GMAPS', + geocoderProvidersFallback: process.env.GEOCODER_PROVIDERS_FALLBACK + ? process.env.GEOCODER_PROVIDERS_FALLBACK?.split(',') + : ['GMAPS'], }));