From 5284871aa2269cbedd621fa450ba793d91208825 Mon Sep 17 00:00:00 2001 From: dhcpcd9 Date: Wed, 23 Mar 2022 11:26:59 +0000 Subject: [PATCH] Update 'OsuLazerServer/Controllers/Users/UsersController.cs' --- OsuLazerServer/Controllers/Users/UsersController.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/OsuLazerServer/Controllers/Users/UsersController.cs b/OsuLazerServer/Controllers/Users/UsersController.cs index 2c88820..add28c6 100644 --- a/OsuLazerServer/Controllers/Users/UsersController.cs +++ b/OsuLazerServer/Controllers/Users/UsersController.cs @@ -100,7 +100,7 @@ public class UsersController : Controller Username = new[] {"Username or email already took"} }); - if (!Regex.IsMatch(body.Username, @"^[a-zA-Z0-9_-\ ]{3,15}$")) + if (!Regex.IsMatch(body.Username, @"^[a-zA-Z0-9_-]{3,15}$")) return await GenerateRegistrationError(new RegistrationRequestErrors.UserErrors { Username = new[] {"Invalid username"} -- GitLab