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   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 3
dl 0
loc 21
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A register() 0 13 1
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
}