| Conditions | 2 |
| Paths | 1 |
| Total Lines | 15 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 7 |
| CRAP Score | 2 |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 21 | 6 | public function register() |
|
| 22 | { |
||
| 23 | // Register the main class to use with the facade |
||
| 24 | $this->app->singleton('hablame-sms', function () { |
||
| 25 | /** @var \Closure $callback */ |
||
| 26 | 6 | $callback = Config::get('services.hablame_sms.guzzle'); |
|
| 27 | |||
| 28 | /** @var \GuzzleHttp\Client|null $http */ |
||
| 29 | 6 | $http = isset($callback) ? $callback() : null; |
|
| 30 | |||
| 31 | 6 | return new Client( |
|
| 32 | 6 | Config::get('services.hablame_sms.account'), |
|
| 33 | 6 | Config::get('services.hablame_sms.apikey'), |
|
| 34 | 6 | Config::get('services.hablame_sms.token'), |
|
| 35 | $http |
||
| 36 | 6 | ); |
|
| 40 |