From a3e357b2040bad18923ffb3f58ec85bfc4c16891 Mon Sep 17 00:00:00 2001 From: Mikkel RINGAUD Date: Fri, 5 Jul 2024 09:58:54 +0200 Subject: [PATCH] fix(geo): lowercase received URLs (#45) --- src/api/geolocation/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/geolocation/index.ts b/src/api/geolocation/index.ts index 26a5d48..062e48b 100644 --- a/src/api/geolocation/index.ts +++ b/src/api/geolocation/index.ts @@ -32,7 +32,7 @@ export const callApiGeolocation = makeApiHandler(async (fetcher, // Restructure the results to be more readable. const results: ApiGeolocation["output"] = data.map((result) => ({ - url: result.url, + url: result.url.toLowerCase(), name: decode(result.nomEtab) // Use UTF8 instead of HTML entities encoding. .replace("COLLEGE", "COLLÈGE") .replace("LYCEE", "LYCÉE")