Browse Source

fixed improper if condition

Mark Magyar 2 years ago
parent
commit
2e0afcf621
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/Connection/TcpConnection.php

+ 1 - 1
src/Connection/TcpConnection.php

@@ -686,7 +686,7 @@ class TcpConnection extends ConnectionInterface implements JsonSerializable
                 // The data is enough for a packet.
                 ++self::$statistics['total_request'];
                 // The current packet length is equal to the length of the buffer.
-                if ($one = strlen($this->recvBuffer) === $this->currentPackageLength) {
+                if ($one = (strlen($this->recvBuffer) === $this->currentPackageLength)) {
                     $oneRequestBuffer = $this->recvBuffer;
                     $this->recvBuffer = '';
                 } else {