@@ -18,6 +18,10 @@ discard block |
||
18 | 18 | |
19 | 19 | private $chat_id; |
20 | 20 | |
21 | + /** |
|
22 | + * @param string $token |
|
23 | + * @param integer $chatId |
|
24 | + */ |
|
21 | 25 | public function __construct($token, $chatId) { |
22 | 26 | |
23 | 27 | $this->telegram = new TelegramBotApi($token); |
@@ -25,6 +29,9 @@ discard block |
||
25 | 29 | return $this; |
26 | 30 | } |
27 | 31 | |
32 | + /** |
|
33 | + * @param string $message |
|
34 | + */ |
|
28 | 35 | public function sendMessage($message) { |
29 | 36 | |
30 | 37 | $response = $this->telegram->sendMessage([ |
@@ -41,7 +41,7 @@ |
||
41 | 41 | */ |
42 | 42 | protected function write(array $record) |
43 | 43 | { |
44 | - $message = '<b>' . $record['channel'] . '</b>' . PHP_EOL; |
|
44 | + $message = '<b>'.$record['channel'].'</b>'.PHP_EOL; |
|
45 | 45 | $message .= $record['formatted']; |
46 | 46 | |
47 | 47 | $this->telegram->sendMessage($message); |