diff --git a/packages/better-php-doc-parser/src/PhpDocNode/Symfony/Validator/Constraints/AssertChoiceTagValueNode.php b/packages/better-php-doc-parser/src/PhpDocNode/Symfony/Validator/Constraints/AssertChoiceTagValueNode.php index e69401ce3582..5f90216fafb6 100644 --- a/packages/better-php-doc-parser/src/PhpDocNode/Symfony/Validator/Constraints/AssertChoiceTagValueNode.php +++ b/packages/better-php-doc-parser/src/PhpDocNode/Symfony/Validator/Constraints/AssertChoiceTagValueNode.php @@ -110,7 +110,7 @@ private function createOriginalChoiceContent() private function resolveOriginalChoiceContent(string $annotationContent): ?string { - $matches = Strings::match($annotationContent, '#(\(choices=|\()(?.*?)(\)|,)#ms'); + $matches = Strings::match($annotationContent, '#(\(choices=|\()(?.*?(})?)(\)|})#ms'); return $matches['choice_content'] ?? null; }