From eb992b0b343de37a0e8558c489f51e4e331d24dd Mon Sep 17 00:00:00 2001 From: Tobias Nyholm Date: Thu, 29 May 2025 11:09:41 +0200 Subject: [PATCH] fix cs --- phpstan-baseline.neon | 3 ++- src/Serializer.php | 6 ------ src/SerializerRouter.php | 6 ------ 3 files changed, 2 insertions(+), 13 deletions(-) diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index 2fb4baa..375f83d 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -1,7 +1,8 @@ parameters: ignoreErrors: - - message: "#^Else branch is unreachable because ternary operator condition is always true\\.$#" + message: '#^Call to function is_object\(\) with object will always evaluate to true\.$#' + identifier: function.alreadyNarrowedType count: 1 path: src/Transformer/Transformer.php diff --git a/src/Serializer.php b/src/Serializer.php index 4273640..3710894 100644 --- a/src/Serializer.php +++ b/src/Serializer.php @@ -28,9 +28,6 @@ public function __construct(MessageToArrayInterface $transformer, ArrayToMessage $this->logger = $logger ?? new NullLogger(); } - /** - * {@inheritdoc} - */ public function decode(array $encodedEnvelope): Envelope { if (empty($encodedEnvelope['body'])) { @@ -59,9 +56,6 @@ public function decode(array $encodedEnvelope): Envelope return $this->addMetaToEnvelope($meta, $envelope); } - /** - * {@inheritdoc} - */ public function encode(Envelope $envelope): array { $envelope = $envelope->withoutStampsOfType(NonSendableStampInterface::class); diff --git a/src/SerializerRouter.php b/src/SerializerRouter.php index 281892c..bc26b09 100644 --- a/src/SerializerRouter.php +++ b/src/SerializerRouter.php @@ -23,9 +23,6 @@ public function __construct(SerializerInterface $happyrSerializer, SerializerInt $this->symfonySerializer = $symfonySerializer; } - /** - * {@inheritdoc} - */ public function decode(array $encodedEnvelope): Envelope { if (empty($encodedEnvelope['body'])) { @@ -50,9 +47,6 @@ public function decode(array $encodedEnvelope): Envelope return $this->symfonySerializer->decode($encodedEnvelope); } - /** - * {@inheritdoc} - */ public function encode(Envelope $envelope): array { try {