blob: 346aeb34a4db048c6cc4742ec1ab286d06b7b8c4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
<?php
namespace Matrix\Data\Room;
class ThreadNotificationCounts implements \JsonSerializable
{
public function __construct(
private ?int $highlightCount = null,
private ?int $notificationCount = null,
)
{}
public function jsonSerialize(): array
{
return array_filter([
"highlight_count" => $this->highlightCount,
"notification_count" => $this->notificationCount,
], "is_null");
}
}
|