swooletw / laravel-swoole

High performance HTTP server based on Swoole. Speed up your Laravel or Lumen applications.
MIT License
4.03k stars 388 forks source link

Handling null event in websockets #551

Open yeganemehr opened 8 months ago

yeganemehr commented 8 months ago

Hi When using a custom websocket protocol and SimpleParser, if there is no event, there will be an fatal error about passing null to Websocket::on(string $event, $callback). This PR fix the problem and prevent calling on() method.