Skip to content

Commit

Permalink
fixed PHP Fatal error: Type of Tests\MockClass\MockTcpConnection::$_s…
Browse files Browse the repository at this point in the history
…endBuffer must not be defined (as in class Workerman\Connection\TcpConnection)
  • Loading branch information
chaz6chez committed Jan 24, 2025
1 parent 2a35c43 commit f31d893
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions tests/MockClass/MockTcpConnection.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
class MockTcpConnection extends TcpConnection
{

protected Response|string|null $_sendBuffer = null;
protected Response|string|null $__sendBuffer = null;

protected Response|string|null $_recvBuffer = null;
protected Response|string|null $__recvBuffer = null;

public function __construct($remote_address = '')
{
Expand Down Expand Up @@ -40,31 +40,31 @@ public function isPaused(): bool
*/
public function getSendBuffer()
{
return $this->_sendBuffer;
return $this->__sendBuffer;
}

/**
* @param string|Response|null $sendBuffer
*/
public function setSendBuffer(Response|string|null $sendBuffer): void
{
$this->_sendBuffer = $sendBuffer;
$this->__sendBuffer = $sendBuffer;
}

/**
* @return Response|string|null
*/
public function getRecvBuffer(): Response|string|null
{
return $this->_recvBuffer;
return $this->__recvBuffer;
}

/**
* @param Response|string|null $recvBuffer
*/
public function setRecvBuffer(Response|string|null $recvBuffer): void
{
$this->_recvBuffer = $recvBuffer;
$this->__recvBuffer = $recvBuffer;
}

/**
Expand Down

0 comments on commit f31d893

Please sign in to comment.