diff --git a/src/WebSocketServer.php b/src/WebSocketServer.php index 85554f0d..d2959c4b 100644 --- a/src/WebSocketServer.php +++ b/src/WebSocketServer.php @@ -240,7 +240,7 @@ public function sendToAll(string $data, int $sender = 0, int $pageSize = 50): in foreach ($fdList as $fd) { $info = $this->getClientInfo($fd); - if ($info && $info['websocket_status'] > 0) { + if (isset($info['websocket_status']) && $info['websocket_status'] > 0) { $this->server->push($fd, $data); } }