@@ -17,7 +17,7 @@ |
||
17 | 17 | $queryString = $this->buildRequestParams($queryParams); |
18 | 18 | |
19 | 19 | $this->addCurlOpt(CURLOPT_URL, $this->credentials->getHost() . $endpoint . '?' . $queryString) |
20 | - ->addCurlOpt(CURLOPT_CUSTOMREQUEST, EnumHttpMethods::GET); |
|
20 | + ->addCurlOpt(CURLOPT_CUSTOMREQUEST, EnumHttpMethods::GET); |
|
21 | 21 | |
22 | 22 | $this->auth($queryString); |
23 | 23 |
@@ -43,11 +43,11 @@ discard block |
||
43 | 43 | */ |
44 | 44 | public function execute(): void |
45 | 45 | { |
46 | - $this->worker->onWorkerStart = function () { |
|
46 | + $this->worker->onWorkerStart = function() { |
|
47 | 47 | |
48 | 48 | $heartbeatTimerId = null; |
49 | 49 | |
50 | - $connection = new AsyncTcpConnection($this->hostStream.'/'.self::CHANNEL_ACCESS.'/'.$this->streamType); |
|
50 | + $connection = new AsyncTcpConnection($this->hostStream . '/' . self::CHANNEL_ACCESS . '/' . $this->streamType); |
|
51 | 51 | $connection->transport = 'ssl'; |
52 | 52 | |
53 | 53 | /** |
@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | * @param $connection |
57 | 57 | * @return void |
58 | 58 | */ |
59 | - $connection->onConnect = function ($connection) use (&$heartbeatTimerId) { |
|
59 | + $connection->onConnect = function($connection) use (&$heartbeatTimerId) { |
|
60 | 60 | $connection->send(json_encode(["op" => $this->operation, "args" => $this->topic])); |
61 | 61 | |
62 | 62 | $heartbeatTimerId = Timer::add(20, function() use ($connection) { |
@@ -74,7 +74,7 @@ discard block |
||
74 | 74 | * @return void |
75 | 75 | * @throws \Exception |
76 | 76 | */ |
77 | - $connection->onMessage = function ($connection, $message) use ($callback) { |
|
77 | + $connection->onMessage = function($connection, $message) use ($callback) { |
|
78 | 78 | $message = json_decode($message, true); |
79 | 79 | |
80 | 80 | $responseDto = $this->getResponseClassname($this->streamType); |
@@ -105,7 +105,7 @@ discard block |
||
105 | 105 | * @param $connection |
106 | 106 | * @return void |
107 | 107 | */ |
108 | - $this->worker->onClose = function ($connection) use (&$heartbeatTimerId) { |
|
108 | + $this->worker->onClose = function($connection) use (&$heartbeatTimerId) { |
|
109 | 109 | Timer::del($heartbeatTimerId); |
110 | 110 | }; |
111 | 111 |