| Conditions | 1 |
| Paths | 1 |
| Total Lines | 9 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 2 |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 37 | public function send(string $message): bool |
||
| 38 | { |
||
| 39 | $sender = getenv('BOT_NAME') ?? ''; |
||
| 40 | $message = sprintf('%s : %s', $sender, $message); |
||
| 41 | $url = getenv('FREE_SMS_URL') . urlencode($message); |
||
| 42 | |||
| 43 | $response = $this->client->get($url, ['timeout' => 120]); |
||
| 44 | |||
| 45 | return 200 === $response->getStatusCode(); |
||
| 46 | } |
||
| 48 |