If no handle return false

Splitting up the condition and return false for each condition works in all tests.
This commit is contained in:
FusionPBX
2022-10-20 16:18:55 -06:00
committed by GitHub
parent b004e8f3ba
commit 88b43cfa14

View File

@@ -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;
}