mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-10-04 20:39:40 +00:00
Add getSupportedTypes method for (de)normalizerInterface implementations
This commit is contained in:
@@ -68,4 +68,15 @@ class ThirdPartyNormalizer implements NormalizerAwareInterface, NormalizerInterf
|
||||
{
|
||||
return $data instanceof ThirdParty && 'json' === $format;
|
||||
}
|
||||
|
||||
public function getSupportedTypes(?string $format): array
|
||||
{
|
||||
if ('json' !== $format) {
|
||||
return [];
|
||||
}
|
||||
|
||||
return [
|
||||
ThirdParty::class => true,
|
||||
];
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user