Skip to content

Commit

Permalink
Adjust services to symfony/serializer:4.4
Browse files Browse the repository at this point in the history
  • Loading branch information
Zales0123 committed Nov 2, 2020
1 parent e54495a commit 3602d51
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 7 deletions.
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
"doctrine/collections": "^1.6",
"doctrine/doctrine-bundle": "^1.12",
"doctrine/doctrine-cache-bundle": "^1.4",
"doctrine/migrations": "^3.0",
"doctrine/doctrine-migrations-bundle": "^3.0",
"doctrine/migrations": "^3.0",
"doctrine/orm": "^2.7",
"egulias/email-validator": "^2.1",
"friendsofsymfony/oauth-server-bundle": "^1.6",
Expand Down Expand Up @@ -94,6 +94,7 @@
"symfony/security-csrf": "^4.4",
"symfony/security-guard": "^4.4",
"symfony/security-http": "^4.4",
"symfony/serializer": "^4.4",
"symfony/swiftmailer-bundle": "^3.4",
"symfony/templating": "^4.4",
"symfony/thanks": "^1.2",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function __construct(
$this->interfaceType = $interfaceType;
}

public function denormalize($data, string $type, string $format = null, array $context = [])
public function denormalize($data, $type, $format = null, array $context = []): array
{
return $this->objectNormalizer->denormalize(
$data,
Expand All @@ -48,7 +48,7 @@ public function denormalize($data, string $type, string $format = null, array $c
);
}

public function supportsDenormalization($data, string $type, string $format = null, array $context = [])
public function supportsDenormalization($data, $type, $format = null, array $context = []): bool
{
return $type === $this->interfaceType;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@ public function __construct(NormalizerInterface $decoratedNormalizer, string $ap
$this->apiRoute = $apiRoute;
}

public function supportsNormalization($data, string $format = null): bool
public function supportsNormalization($data, $format = null): bool
{
return $this->decoratedNormalizer->supportsNormalization($data, $format);
}

public function normalize($object, string $format = null, array $context = [])
public function normalize($object, $format = null, array $context = []): array
{
$docs = $this->decoratedNormalizer->normalize($object, $format, $context);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@ public function __construct(NormalizerInterface $decoratedNormalizer, string $ap
$this->apiRoute = $apiRoute;
}

public function supportsNormalization($data, string $format = null): bool
public function supportsNormalization($data, $format = null): bool
{
return $this->decoratedNormalizer->supportsNormalization($data, $format);
}

public function normalize($object, string $format = null, array $context = [])
public function normalize($object, $format = null, array $context = [])
{
$docs = $this->decoratedNormalizer->normalize($object, $format, $context);

Expand Down

0 comments on commit 3602d51

Please sign in to comment.