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.

TeamworkServiceProvider::register()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 13
Code Lines 7

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 13
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 7
nc 1
nop 0
1
<?php
2
3
namespace Ciromattia\Teamwork;
4
5
use GuzzleHttp\Client as Guzzle;
6
use Illuminate\Support\ServiceProvider;
7
8
class TeamworkServiceProvider extends ServiceProvider
9
{
10
    /**
11
     * Register the service provider.
12
     *
13
     * @return void
14
     */
15
    public function register()
16
    {
17
        $this->app->singleton('ciromattia.teamwork', function ($app) {
18
            $client = new \Ciromattia\Teamwork\Client(new Guzzle,
19
                $app['config']->get('services.teamwork.key'),
20
                $app['config']->get('services.teamwork.url')
21
            );
22
23
            return new \Ciromattia\Teamwork\Factory($client);
24
        });
25
26
        $this->app->bind('Ciromattia\Teamwork\Factory', 'ciromattia.teamwork');
27
    }
28
}