From 2d0866ad74ebc5d417b8be7d7b7a17ffedcc9fea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Munsch?= Date: Tue, 7 Sep 2021 14:41:16 +0200 Subject: [PATCH] fix client containSymbol validate not accepting underscores --- src/Utils.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Utils.php b/src/Utils.php index b48af39..7eda121 100644 --- a/src/Utils.php +++ b/src/Utils.php @@ -175,7 +175,7 @@ class Utils $validators[] = [ 'type' => $rule, 'validate' => function () use ($data, $attribute) { - return \preg_match('/[^\w]/', $data[$attribute]); + return \preg_match('/[^a-zA-Z0-9]/', $data[$attribute]); }, // phpcs:ignore Generic.Files.LineLength.TooLong 'error' => self::translate($attribute) . ' doit contenir au moins un caractère spécial comme une virgule par exemple'