Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions Service/Logger/LoggerAwareTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,9 @@ protected function getLogger() : LoggerInterface

/**
* @param LoggerInterface $logger
*
* @return $this
*/
public function setLogger(LoggerInterface $logger)
public function setLogger(LoggerInterface $logger): void
{
$this->traitLogger = $logger;

return $this;
}
}
4 changes: 2 additions & 2 deletions Service/Serializer/Encoder/JsonEncoder.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ class JsonEncoder extends \Symfony\Component\Serializer\Encoder\JsonEncoder
{
const FORMAT_JSON_PATCH = 'json-patch';

public function supportsEncoding($format): bool
public function supportsEncoding(string $format): bool
{
return static::FORMAT_JSON_PATCH === $format || parent::supportsEncoding($format);
}

public function supportsDecoding($format): bool
public function supportsDecoding(string $format): bool
{
return static::FORMAT_JSON_PATCH === $format || parent::supportsDecoding($format);
}
Expand Down
4 changes: 2 additions & 2 deletions Service/Serializer/Encoder/UrlEncode.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class UrlEncode implements EncoderInterface
*
* {@inheritdoc}
*/
public function encode($data, $format, array $context = []): string
public function encode(mixed $data, string $format, array $context = []): string
{
$data = $this->convertCamelCaseToSnakeCase($data);
$encoded = http_build_query($data);
Expand All @@ -29,7 +29,7 @@ public function encode($data, $format, array $context = []): string
/**
* {@inheritdoc}
*/
public function supportsEncoding($format): bool
public function supportsEncoding(string $format, array $context = []): bool
{
return UrlEncoder::FORMAT === $format;
}
Expand Down
4 changes: 2 additions & 2 deletions Service/Serializer/Encoder/UrlEncoder.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,15 @@ public function __construct(?UrlEncode $encodingImpl = null)
/**
* {@inheritdoc}
*/
public function encode($data, $format, array $context = array()): string
public function encode(mixed $data, string $format, array $context = []): string
{
return $this->encodingImpl->encode($data, self::FORMAT, $context);
}

/**
* {@inheritdoc}
*/
public function supportsEncoding($format): bool
public function supportsEncoding(string $format, array $context = []): bool
{
return self::FORMAT === $format;
}
Expand Down
4 changes: 2 additions & 2 deletions Service/Serializer/Encoder/VoidEncoder.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@ class VoidEncoder implements EncoderInterface
/**
* {@inheritdoc}
*/
public function encode($data, $format, array $context = array()): string
public function encode(mixed $data, string $format, array $context = []): string
{
return '';
}

/**
* {@inheritdoc}
*/
public function supportsEncoding($format): bool
public function supportsEncoding(string $format, array $context = []): bool
{
return self::FORMAT === $format;
}
Expand Down
Loading