GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Pull Request — master (#24)
by Stephen
02:27
created

TwilioProvider::boot()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 20
Code Lines 11

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 13
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 20
ccs 13
cts 13
cp 1
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 11
nc 1
nop 0
crap 1
1
<?php
2
3
namespace NotificationChannels\Twilio;
4
5
use Services_Twilio as TwilioService;
6
use Illuminate\Support\ServiceProvider;
7
8
class TwilioProvider extends ServiceProvider
9
{
10
    /**
11
     * Bootstrap the application services.
12
     */
13 1
    public function boot()
14
    {
15 1
        $this->app->when(TwilioChannel::class)
16 1
            ->needs(Twilio::class)
17
            ->give(function () {
18
19 1
                $config = $this->app['config']['services.twilio'];
20
21 1
                return new Twilio(
22 1
                    $this->app->make(TwilioService::class),
23 1
                    $config['from']
24
                );
25 1
            });
26
27 1
        $this->app->bind(TwilioService::class, function () {
28 1
            $config = $this->app['config']['services.twilio'];
29
30 1
            return new TwilioService($config['account_sid'], $config['auth_token']);
31 1
        });
32 1
    }
33
34
    /**
35
     * Register the application services.
36
     */
37
    public function register()
38
    {
39
    }
40
}
41