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
Push — master ( 352f99...e3c5ff )
by Cees-Jan
09:24
created

Build::getRequest()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 1

Duplication

Lines 4
Ratio 100 %

Code Coverage

Tests 0
CRAP Score 2
Metric Value
dl 4
loc 4
ccs 0
cts 4
cp 0
rs 10
cc 1
eloc 1
nc 1
nop 0
crap 2
1
<?php
2
3
namespace WyriHaximus\Travis;
4
5
use Psr\Http\Message\RequestInterface;
6
use Psr\Http\Message\ResponseInterface;
7
8 View Code Duplication
class Build implements EndpointInterface
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
9
{
10
    use ParentHasClientAwareTrait;
11
12
    /**
13
     * @var Repository
14
     */
15
    protected $repository;
16
17
    /**
18
     * @var int
19
     */
20
    protected $id;
21
22
    public function __construct(Repository $repository, \stdClass $build)
23
    {
24
        $this->setParent($repository);
25
        $this->repository = $repository;
26
27
        $this->id = $build->id;
28
    }
29
30
    public function getRequest(): RequestInterface
31
    {
32
        // TODO: Implement getRequest() method.
33
    }
34
35
    public function fromResponse(ResponseInterface $response): EndpointInterface
36
    {
37
        // TODO: Implement fromResponse() method.
38
    }
39
40
    /**
41
     * @return mixed
42
     */
43
    public function getId(): int
44
    {
45
        return $this->id;
46
    }
47
48
    public function matrix()
49
    {
50
        return new BuildMatrix($this);
51
    }
52
}
53