Skip to content

Commit

Permalink
WIP fix "must be of type Frame, Swoole\WebSocket\Frame given"
Browse files Browse the repository at this point in the history
  • Loading branch information
kingIZZZY authored Dec 23, 2024
1 parent 50779a9 commit 3b70270
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bin/swoole-server
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ if($serverState['octaneConfig']['swoole']['enableWebSockets'] ?? false){
|--------------------------------------------------------------------------
*/

$server->on('message', function (Server $server, Frame $frame) use ($workerState) {
$server->on('message', function (WServer $server, Swoole\WebSocket\Frame $frame) use ($workerState) {
$workerState->worker->handleWebSocketMessage($server, $frame);
});

Expand All @@ -199,7 +199,7 @@ if($serverState['octaneConfig']['swoole']['enableWebSockets'] ?? false){
|--------------------------------------------------------------------------
*/

$server->on('close', function (Server $server, int $fd) use ($workerState) {
$server->on('close', function (WServer $server, int $fd) use ($workerState) {
$workerState->worker->handleWebSocketDisconnect($server, $fd);
});

Expand Down

0 comments on commit 3b70270

Please sign in to comment.