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 ( dcd0c7...a5712b )
by Cees-Jan
7s
created

Repository::commits()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 9
Code Lines 5

Duplication

Lines 9
Ratio 100 %
Metric Value
dl 9
loc 9
rs 9.6666
cc 1
eloc 5
nc 1
nop 0
1
<?php
2
declare(strict_types=1);
3
4
namespace WyriHaximus\Travis\Resource\Sync;
5
6
use Rx\Observable;
7
use Rx\React\Promise;
8
use WyriHaximus\Travis\Resource\Repository as BaseRepository;
9
use function Clue\React\Block\await;
10
use function React\Promise\resolve;
11
12
class Repository extends BaseRepository
13
{
14 View Code Duplication
    public function builds(): array
0 ignored issues
show
Duplication introduced by
This method 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...
15
    {
16
        return await(
17
            Promise::fromObservable(
18
                $this->getTransport()->getHydrator()->buildAsyncFromSync('Repository', $this)->builds()->toArray()
19
            ),
20
            $this->getTransport()->getLoop()
21
        );
22
    }
23
24
    public function build(int $id): Build
25
    {
26
        return await(
27
            $this->getTransport()->getHydrator()->buildAsyncFromSync('Repository', $this)->build($id),
28
            $this->getTransport()->getLoop()
29
        );
30
    }
31
32 View Code Duplication
    public function commits(): array
0 ignored issues
show
Duplication introduced by
This method 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...
33
    {
34
        return await(
35
            Promise::fromObservable(
36
                $this->getTransport()->getHydrator()->buildAsyncFromSync('Repository', $this)->commits()->toArray()
37
            ),
38
            $this->getTransport()->getLoop()
39
        );
40
    }
41
}
42