Я не знаю, почему name
не включено при трансляции события. Но он включен в return $message
Вот мой MessageController
Laravel.
namespace App\Http\Controllers; use Illuminate\Http\Request; use App\Message; use Illuminate\Support\Facades\Auth; use App\Events\Chat; class MessageController extends Controller { public function create(Request $request){ $message = new Message; $message->channel = $request->channel_id; $message->by = Auth::user()->id; $message->body = $request->message; $message->save(); $message->name = "Clyde Santiago"; //This it the inserted data to the object event(new Chat($message)); //sends `message` object to Pusher but not including the `name` return $message //returns `message` object including the `name` } }