Room identifier max length is 36

This commit is contained in:
Andrey Terentev 2024-03-13 16:01:04 +07:00 committed by Andrey Terentev
parent a9847e8da7
commit 385dfea98b

View File

@ -11,7 +11,7 @@ public class IdentifierValidator {
} }
public static boolean forRoom(@NotNull String roomId) { public static boolean forRoom(@NotNull String roomId) {
return roomId.matches("^(?!-)[a-z\\d-]{0,31}[a-z\\d](?!-)$"); return roomId.matches("^(?!-)[a-z\\d-]{0,35}[a-z\\d](?!-)$");
} }
public static boolean forUser(@NotNull String username) { public static boolean forUser(@NotNull String username) {