Fixed bug for non-int values

This commit is contained in:
Alex Renoki 2020-09-06 20:29:33 +03:00
parent 3ce55575a0
commit 3555b471cd
1 changed files with 2 additions and 0 deletions

View File

@ -170,6 +170,8 @@ class WebSocketHandler implements MessageComponentInterface
if ($connectionsCount instanceof PromiseInterface) {
$connectionsCount->then(function ($connectionsCount) use ($capacity, $connection) {
$connectionsCount = $connectionsCount ?: 0;
$this->sendExceptionIfOverCapacity($connectionsCount, $capacity, $connection);
});
} else {