Skip to content

Commit

Permalink
Code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
brendt committed Apr 27, 2021
1 parent 7c5c5cd commit 184ad05
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/Connection.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,15 +95,12 @@ public function read(): Generator

$outputFromSocket = socket_read($this->socket, $this->bufferSize);

if ($outputFromSocket === false) {
break;
}

if ($outputFromSocket === '') {
if ($outputFromSocket === false || $outputFromSocket === ''){
break;
}

yield $outputFromSocket;
}
}
}

0 comments on commit 184ad05

Please sign in to comment.