Conditions | 4 |
Paths | 3 |
Total Lines | 11 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
42 | private function sandbox($getParams, $message) |
||
43 | { |
||
44 | $apiKey = $getParams['apiKey'] ?? ''; |
||
45 | $channel = $getParams['channel'] ?? ''; |
||
46 | if (!empty($apiKey) && !empty($channel)) { |
||
47 | $messenger = new Messenger\Telegram($apiKey, $channel); |
||
48 | if ($messenger->send($message['body'])) { |
||
49 | return true; |
||
50 | } |
||
51 | } |
||
52 | return false; |
||
53 | } |
||
54 | } |