mirror of
https://github.com/danog/amp.git
synced 2024-11-26 20:15:00 +01:00
Remove conditional emty arrays in selectActionableStreams
Neither readStreams or writeStreams are ever completely unset and the calling method checks that at least one of them has some sort of contents. There is no need to check if one is an empty array, and if so, supply an empty array.
This commit is contained in:
parent
cfb0badf6c
commit
feddb76a9a
@ -84,8 +84,8 @@ class NativeReactor implements Reactor {
|
||||
}
|
||||
|
||||
private function selectActionableStreams($sec, $usec) {
|
||||
$r = $this->readStreams ?: [];
|
||||
$w = $this->writeStreams ?: [];
|
||||
$r = $this->readStreams;
|
||||
$w = $this->writeStreams;
|
||||
$e = NULL;
|
||||
|
||||
if (stream_select($r, $w, $e, $sec, $usec)) {
|
||||
|
Loading…
Reference in New Issue
Block a user