| Total Complexity | 3 |
| Total Lines | 23 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 23 | class WhitelistCreatedEvent implements WhitelistEvent |
||
| 24 | { |
||
| 25 | public function __construct(public InstitutionCollection $whitelistedInstitutions) |
||
| 27 | } |
||
| 28 | |||
| 29 | /** |
||
| 30 | * @param array $data |
||
| 31 | * @return WhitelistCreatedEvent |
||
| 32 | */ |
||
| 33 | public static function deserialize(array $data): self |
||
| 34 | { |
||
| 35 | return new self(InstitutionCollection::deserialize($data['whitelisted_institutions'])); |
||
| 36 | } |
||
| 37 | |||
| 38 | /** |
||
| 39 | * The data ending up in the event_stream, be careful not to include sensitive data here! |
||
| 40 | * |
||
| 41 | * @return array<string, mixed> |
||
| 42 | */ |
||
| 43 | public function serialize(): array |
||
| 46 | } |
||
| 47 | } |
||
| 48 |