Skip to content

Commit e826328

Browse files
committed
Fix GreetingNormalizer::supportsNormalization
`Compile Error: Declaration of App\Rest\Serializer\GreetingNormalizer::supportsNormalization(mixed $data, ?string $format = null) must be compatible with Symfony\Component\Serializer\Normalizer\NormalizerInterface::supportsNormalization(mixed $data, ?string $format = null, array $context = []): bool`
1 parent 0e82f5f commit e826328

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

code_samples/api/rest_api/src/Rest/Serializer/GreetingNormalizer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ class GreetingNormalizer implements NormalizerInterface, NormalizerAwareInterfac
1111
{
1212
use NormalizerAwareTrait;
1313

14-
public function supportsNormalization(mixed $data, ?string $format = null)
14+
public function supportsNormalization(mixed $data, ?string $format = null, array $context = []): bool
1515
{
1616
return $data instanceof Greeting;
1717
}

0 commit comments

Comments
 (0)