From 1888fb69a1fa4fdec71c283260207913f072d8a4 Mon Sep 17 00:00:00 2001 From: Maxim Leshchenko Date: Wed, 8 Dec 2021 22:19:16 +0200 Subject: [PATCH] Users: Allow use of underscores in the Telegram account name --- Web/Util/Validator.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Web/Util/Validator.php b/Web/Util/Validator.php index 50a2f345..aa30a8b5 100644 --- a/Web/Util/Validator.php +++ b/Web/Util/Validator.php @@ -19,7 +19,7 @@ class Validator function telegramValid(string $telegram): bool { - return (bool) preg_match("/^(?:t.me\/|@)?([a-zA-Z0-9]{0,32})$/", $telegram); + return (bool) preg_match("/^(?:t.me\/|@)?([a-zA-Z0-9_]{0,32})$/", $telegram); } use TSimpleSingleton;