diff --git a/app/Events/SendAnnouncement.php b/app/Events/SendAnnouncement.php index f11740c..49bee59 100644 --- a/app/Events/SendAnnouncement.php +++ b/app/Events/SendAnnouncement.php @@ -34,4 +34,15 @@ class SendAnnouncement implements ShouldBroadcast new Channel('channel-pub'), ]; } + + /** + * @return array + */ + public function broadcastWith(): array { + return [ + 'name' => 'MyTestEvent', + 'message' => $this->message, + 'broadcastTime' => $this->broadcastTime + ]; + } }