8000 Add context to (de)normalizer support check · Elao/PhpEnums@ab69eab · GitHub
[go: up one dir, main page]

Skip to content

Commit ab69eab

Browse files
authored
Add context to (de)normalizer support check
See symfony/symfony#43982
1 parent 5741331 commit ab69eab

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Bridge/Symfony/Serializer/Normalizer/EnumNormalizer.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ public function normalize($object, $format = null, array $context = []): string
3636
/**
3737
* {@inheritdoc}
3838
*/
39-
public function supportsNormalization($data, $format = null): bool
39+
public function supportsNormalization($data, $format = null, array $context = []): bool
4040
{
4141
return $data instanceof EnumInterface;
4242
}
@@ -67,7 +67,7 @@ public function denormalize($data, $class, $format = null, array $context = []):
6767
/**
6868
* {@inheritdoc}
6969
*/
70-
public function supportsDenormalization($data, $type, $format = null): bool
70+
public function supportsDenormalization($data, $type, $format = null, array $context = []): bool
7171
{
7272
return is_a($type, EnumInterface::class, true);
7373
}

0 commit comments

Comments
 (0)
0