@@ -45,7 +45,7 @@ discard block |
||
| 45 | 45 | |
| 46 | 46 | $this->fd = $this->socket->getSockOpt(ZMQ::SOCKOPT_FD); |
| 47 | 47 | |
| 48 | - $writeListener = [ $this, 'handleEvent' ]; |
|
| 48 | + $writeListener = [$this, 'handleEvent']; |
|
| 49 | 49 | $this->buffer = new ZmqBuffer($socket, $this->fd, $this->loop, $writeListener); |
| 50 | 50 | } |
| 51 | 51 | |
@@ -54,7 +54,7 @@ discard block |
||
| 54 | 54 | */ |
| 55 | 55 | public function attachReadListener() |
| 56 | 56 | { |
| 57 | - $this->loop->addReadStream($this->fd, [ $this, 'handleEvent' ]); |
|
| 57 | + $this->loop->addReadStream($this->fd, [$this, 'handleEvent']); |
|
| 58 | 58 | } |
| 59 | 59 | |
| 60 | 60 | /** |
@@ -92,7 +92,7 @@ discard block |
||
| 92 | 92 | $messages = $this->socket->recvmulti(ZMQ::MODE_DONTWAIT); |
| 93 | 93 | if (false !== $messages) |
| 94 | 94 | { |
| 95 | - $this->emit('messages', [ $messages ]); |
|
| 95 | + $this->emit('messages', [$messages]); |
|
| 96 | 96 | } |
| 97 | 97 | } |
| 98 | 98 | |
@@ -146,7 +146,7 @@ discard block |
||
| 146 | 146 | return; |
| 147 | 147 | } |
| 148 | 148 | |
| 149 | - $this->emit('end', [ $this ]); |
|
| 149 | + $this->emit('end', [$this]); |
|
| 150 | 150 | $this->loop->removeStream($this->fd); |
| 151 | 151 | $this->buffer->flushListeners(); |
| 152 | 152 | $this->flushListeners(); |
@@ -179,6 +179,6 @@ discard block |
||
| 179 | 179 | */ |
| 180 | 180 | public function __call($method, $args) |
| 181 | 181 | { |
| 182 | - return call_user_func_array([ $this->socket, $method ], $args); |
|
| 182 | + return call_user_func_array([$this->socket, $method], $args); |
|
| 183 | 183 | } |
| 184 | 184 | } |
@@ -36,7 +36,7 @@ |
||
| 36 | 36 | */ |
| 37 | 37 | public function __call($method, $args) |
| 38 | 38 | { |
| 39 | - $res = call_user_func_array([ $this->context, $method ], $args); |
|
| 39 | + $res = call_user_func_array([$this->context, $method], $args); |
|
| 40 | 40 | if ($res instanceof RawZMQSocket) |
| 41 | 41 | { |
| 42 | 42 | $res = $this->wrapSocket($res); |
@@ -117,7 +117,7 @@ |
||
| 117 | 117 | } |
| 118 | 118 | catch (ZMQSocketException $ex) |
| 119 | 119 | { |
| 120 | - $this->emit('error', [ $ex ]); |
|
| 120 | + $this->emit('error', [$ex]); |
|
| 121 | 121 | } |
| 122 | 122 | } |
| 123 | 123 | } |