Ensure that organisers are excluded
This commit is contained in:
parent
3bffa3cdd6
commit
dab1f156e3
|
@ -12,7 +12,7 @@ final class EventCollection extends Collection
|
||||||
public function excludeEventHosts(): self
|
public function excludeEventHosts(): self
|
||||||
{
|
{
|
||||||
return (new self($this->items))->filter(function (array $rsvp): bool {
|
return (new self($this->items))->filter(function (array $rsvp): bool {
|
||||||
return $rsvp['member']['event_context']['host'];
|
return !$rsvp['member']['event_context']['host'];
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue