@@ -107,6 +107,10 @@ |
||
107 | 107 | } |
108 | 108 | |
109 | 109 | |
110 | + /** |
|
111 | + * @param string $command |
|
112 | + * @param string $params |
|
113 | + */ |
|
110 | 114 | private function assembleUri($command, $params) :string { |
111 | 115 | return sprintf( |
112 | 116 | 'https://api.telegram.org/bot%s/%s%s', |
@@ -67,7 +67,7 @@ |
||
67 | 67 | * |
68 | 68 | */ |
69 | 69 | public function getResponder($message) { |
70 | - return function ($text) use($message){ |
|
70 | + return function($text) use($message){ |
|
71 | 71 | $this->sendResponse($text, $message); |
72 | 72 | }; |
73 | 73 | } |
@@ -42,11 +42,11 @@ |
||
42 | 42 | $counter = 0; |
43 | 43 | $bot->setClient($this->client); |
44 | 44 | |
45 | - $this->loop->addPeriodicTimer(2, function (\React\EventLoop\Timer\Timer $timer) use ($bot, $times, &$counter) { |
|
45 | + $this->loop->addPeriodicTimer(2, function(\React\EventLoop\Timer\Timer $timer) use ($bot, $times, &$counter) { |
|
46 | 46 | |
47 | 47 | $bot->poll(); |
48 | 48 | |
49 | - if ( $times && $times >= $counter) { |
|
49 | + if ($times && $times >= $counter) { |
|
50 | 50 | $this->loop->cancelTimer($timer); |
51 | 51 | } |
52 | 52 | }); |