8000 [DoctrineBridge] Fix value type for simple_array · symfony/symfony@6375990 · GitHub
[go: up one dir, main page]

Skip to content

Commit 6375990

Browse files
author
Gigino Chianese
committed
[DoctrineBridge] Fix value type for simple_array
1 parent b6835dd commit 6375990

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Bridge/Doctrine/PropertyInfo/DoctrineExtractor.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ public function getTypes(string $class, string $property, array $context = [])
180180
return [new Type(Type::BUILTIN_TYPE_ARRAY, $nullable, null, true)];
181181

182182
case Types::SIMPLE_ARRAY:
183-
return [new Type(Type::BUILTIN_TYPE_ARRAY, $nullable, null, true, new Type(Type::BUILTIN_TYPE_INT), new Type(Type::BUILTIN_TYPE_STRING))];
183+
return [new Type(Type::BUILTIN_TYPE_ARRAY, $nullable, null, true, new Type(Type::BUILTIN_TYPE_INT), $enumType ?? new Type(Type::BUILTIN_TYPE_STRING))];
184184
}
185185
break;
186186
case Type::BUILTIN_TYPE_INT:

0 commit comments

Comments
 (0)
0