I am trying to trigger a pusher event but it's not working.
class SendWaitingForRedirect implements ShouldBroadcast
{
use Dispatchable, InteractsWithSockets, SerializesModels;
public $message;
public function __construct($message)
{
$this->message = $message;
}
public function broadcastOn()
{
return ['my-channel'];
}
public function broadcastAs()
{
return 'my-event';
}
}
and calling the event as
event(new \App\Events\SendWaitingForRedirect('hello world'));
I don't know what's wrong. Can you please help?
I checked errors on the pusher. It is not having any errors. Can you please help.