public channel

This commit is contained in:
2024-05-14 15:01:39 +07:00
parent f4a6a65e83
commit db0850b835

View File

@@ -34,7 +34,12 @@ class ChatMessageSent implements ShouldBroadcast
*/ */
public function broadcastOn() public function broadcastOn()
{ {
return new PrivateChannel('chat'. $this->message->channel_id); return new Channel('chat'. $this->message->channel_id);
} }
public function broadcastAs(): string
{
return 'chat.sent';
}
} }