If no handle return false
Splitting up the condition and return false for each condition works in all tests.
This commit is contained in:
parent
b004e8f3ba
commit
88b43cfa14
|
|
@ -142,7 +142,11 @@ class event_socket {
|
|||
}
|
||||
|
||||
public function connected() {
|
||||
if ($this->fp && feof($this->fp) === true) {
|
||||
if (!$this->fp) {
|
||||
//not connected to the socket
|
||||
return false;
|
||||
}
|
||||
if (feof($this->fp) === true) {
|
||||
//not connected to the socket
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue