Define return value of overriding jsonSerialize()

Threw DEPRECATED warnings on php8.x systems
This commit is contained in:
Jonathan Flueren 2022-11-06 20:19:30 +01:00 committed by thrillfall
parent bfb3799f5c
commit 33c5a28250

View File

@ -18,7 +18,7 @@ class SubscriptionChangeEntity extends Entity implements JsonSerializable {
$this->addType('subscribed','boolean'); $this->addType('subscribed','boolean');
} }
public function jsonSerialize() { public function jsonSerialize(): array {
return [ return [
'id' => $this->id, 'id' => $this->id,
'url' => $this->url, 'url' => $this->url,