From a7f816424eea2541af79243ab7fef903c9a093cc Mon Sep 17 00:00:00 2001 From: Ilija Studen Date: Wed, 15 Apr 2026 11:52:04 +0200 Subject: [PATCH 1/2] Skip notice in newer versions of PHP --- src/Entity/Entity.php | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Entity/Entity.php b/src/Entity/Entity.php index 356806d..2652db3 100644 --- a/src/Entity/Entity.php +++ b/src/Entity/Entity.php @@ -1028,6 +1028,7 @@ protected function triggerEvent($event, array $event_parameters = []) /** * {@inheritdoc} */ + #[\ReturnTypeWillChange] public function jsonSerialize() { $result = [ From 7c7b5200a07fb5403f6dab442549230425394150 Mon Sep 17 00:00:00 2001 From: Ilija Studen Date: Wed, 15 Apr 2026 11:55:39 +0200 Subject: [PATCH 2/2] Fix deprecations --- src/Collection.php | 1 + src/Exception/ValidationException.php | 1 + test/src/Fixtures/StatSnapshots/Base/StatsSnapshot.php | 1 + 3 files changed, 3 insertions(+) diff --git a/src/Collection.php b/src/Collection.php index 405a170..2e6700d 100644 --- a/src/Collection.php +++ b/src/Collection.php @@ -202,6 +202,7 @@ public function getItemsPerPage() * * @return array */ + #[\ReturnTypeWillChange] public function jsonSerialize() { $result = $this->execute(); diff --git a/src/Exception/ValidationException.php b/src/Exception/ValidationException.php index ea591c9..8f15eeb 100644 --- a/src/Exception/ValidationException.php +++ b/src/Exception/ValidationException.php @@ -60,6 +60,7 @@ public function setObject(EntityInterface $object) * * @return array */ + #[\ReturnTypeWillChange] public function jsonSerialize() { $result = [ diff --git a/test/src/Fixtures/StatSnapshots/Base/StatsSnapshot.php b/test/src/Fixtures/StatSnapshots/Base/StatsSnapshot.php index 2f4fc06..4461758 100644 --- a/test/src/Fixtures/StatSnapshots/Base/StatsSnapshot.php +++ b/test/src/Fixtures/StatSnapshots/Base/StatsSnapshot.php @@ -222,6 +222,7 @@ public function &setFieldValue($name, $value) /** * {@inheritdoc} */ + #[\ReturnTypeWillChange] public function jsonSerialize() { return array_merge(parent::jsonSerialize(), [