From 9b026408e2dc26e987db73c867a9b69be5d7bc5a Mon Sep 17 00:00:00 2001 From: morgane Date: Sun, 21 Jun 2026 15:31:32 +0000 Subject: [PATCH] Actualiser api/index.php --- api/index.php | 1 + 1 file changed, 1 insertion(+) diff --git a/api/index.php b/api/index.php index d534a9b..15ce0bc 100644 --- a/api/index.php +++ b/api/index.php @@ -12538,6 +12538,7 @@ function customUnitsAdd(PDO $db): void { } $key = mb_strtolower($key); + $key = strtr($key, ['à'=>'a','â'=>'a','ä'=>'a','é'=>'e','è'=>'e','ê'=>'e','ë'=>'e','ï'=>'i','î'=>'i','ô'=>'o','ö'=>'o','ù'=>'u','û'=>'u','ü'=>'u','ç'=>'c','œ'=>'oe','æ'=>'ae']); $key = preg_replace('/[^a-z0-9]+/u', '_', $key); $key = trim($key, '_'); if ($key === '' || in_array($key, ['pz', 'g', 'ml', 'conf'], true)) {