mirror of
https://github.com/LD-Reborn/Berufsschule_HAM.git
synced 2025-12-20 06:51:55 +00:00
Fixed umlauts not translating properly for username
This commit is contained in:
@@ -11,7 +11,7 @@ public static partial class UsersHelper
|
|||||||
throw new ArgumentException("Given name and surname must not be empty.");
|
throw new ArgumentException("Given name and surname must not be empty.");
|
||||||
|
|
||||||
string combined = (surname + givenName).ToLowerInvariant();
|
string combined = (surname + givenName).ToLowerInvariant();
|
||||||
|
combined = combined.Replace("ä", "ae").Replace("ö", "oe").Replace("ü", "ue");
|
||||||
// Normalize to decompose accents (e.g., é -> e + ́)
|
// Normalize to decompose accents (e.g., é -> e + ́)
|
||||||
string normalized = combined.Normalize(NormalizationForm.FormD);
|
string normalized = combined.Normalize(NormalizationForm.FormD);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user