varspool / Wrench

A simple PHP WebSocket implementation for PHP 7.1
Do What The F*ck You Want To Public License
596 stars 210 forks source link

fix TypeErrors in calls to connection close #103

Closed dobrakmato closed 7 years ago

dobrakmato commented 7 years ago

When running under PHP7, following excpetion occurs:

PHP Fatal error: Uncaught TypeError: Argument 1 passed to Wrench\Connection::close() must be of the type integer, object given, called in .\vendor\wrench\wrench\lib\ConnectionManager.php on line 22

This pull request replaces close calls with object $connection->close($e); to correct calls with int $connection->close(Protocol::CLOSE_UNEXPECTED);

dominics commented 7 years ago

Nice, thanks