mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
Fix error when denormalizing empty array for pick third party dynampic type
This commit is contained in:
parent
13dbbb6741
commit
6cd336922f
@ -28,10 +28,14 @@ class EntityToJsonTransformer implements DataTransformerInterface
|
||||
|
||||
public function reverseTransform($value)
|
||||
{
|
||||
if ('' === $value) {
|
||||
if (false === $this->multiple && '' === $value) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if ($this->multiple && [] === $value) {
|
||||
return [];
|
||||
}
|
||||
|
||||
$denormalized = json_decode((string) $value, true, 512, JSON_THROW_ON_ERROR);
|
||||
|
||||
if ($this->multiple) {
|
||||
|
@ -188,6 +188,7 @@ class WorkflowStepType extends AbstractType
|
||||
'label' => 'workflow.transition_destinee_third_party',
|
||||
'help' => 'workflow.transition_destinee_third_party_help',
|
||||
'multiple' => true,
|
||||
'empty_data' => [],
|
||||
]);
|
||||
|
||||
$builder
|
||||
|
Loading…
x
Reference in New Issue
Block a user