ldc-boutique-cnc/routes/channels.php

19 lines
588 B
PHP
Raw Permalink Normal View History

2020-10-30 17:26:00 +01:00
<?php
use Illuminate\Support\Facades\Broadcast;
/*
2022-08-25 12:26:43 +02:00
|--------------------------------------------------------------------------
| Broadcast Channels
|--------------------------------------------------------------------------
|
| Here you may register all of the event broadcasting channels that your
| application supports. The given channel authorization callbacks are
| used to check if an authenticated user can listen to the channel.
|
2020-10-30 17:26:00 +01:00
*/
Broadcast::channel('App.Models.User.{id}', function ($user, $id) {
2022-08-25 12:26:43 +02:00
return (int)$user->id === (int)$id;
2020-10-30 17:26:00 +01:00
});