mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-30 02:25:00 +00:00
Rector changes and immplementations of required methods
This commit is contained in:
@@ -17,18 +17,18 @@ use Symfony\Component\Serializer\Normalizer\ContextAwareNormalizerInterface;
|
||||
use Symfony\Component\Serializer\Normalizer\NormalizerAwareInterface;
|
||||
use Symfony\Component\Serializer\Normalizer\NormalizerAwareTrait;
|
||||
|
||||
class GenderDocGenNormalizer implements ContextAwareNormalizerInterface, NormalizerAwareInterface
|
||||
class GenderDocGenNormalizer implements \Symfony\Component\Serializer\Normalizer\NormalizerInterface, NormalizerAwareInterface
|
||||
{
|
||||
use NormalizerAwareTrait;
|
||||
|
||||
public function __construct(private readonly TranslatableStringHelperInterface $translatableStringHelper) {}
|
||||
|
||||
public function supportsNormalization($data, ?string $format = null, array $context = [])
|
||||
public function supportsNormalization($data, ?string $format = null, array $context = []): bool
|
||||
{
|
||||
return $data instanceof Gender;
|
||||
}
|
||||
|
||||
public function normalize($gender, ?string $format = null, array $context = [])
|
||||
public function normalize($gender, ?string $format = null, array $context = []): string|int|float|bool|\ArrayObject|array|null
|
||||
{
|
||||
return [
|
||||
'id' => $gender->getId(),
|
||||
|
Reference in New Issue
Block a user