validator = $validator; } /** * Returns TRUE to accept the message, FALSE to block it. * * @param array $event event data * @return bool */ public function filter(array $event) { return $this->validator->isValid($event['message']); } }