Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

Completed
Pull Request — master (#790)
by
unknown
18:34
created

Connection   A

Complexity

Total Complexity 7

Size/Duplication

Total Lines 64
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 7
eloc 13
c 1
b 0
f 0
dl 0
loc 64
ccs 18
cts 18
cp 1
rs 10

7 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A setEdges() 0 3 1
A getPageInfo() 0 3 1
A getEdges() 0 3 1
A setPageInfo() 0 3 1
A setTotalCount() 0 3 1
A getTotalCount() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Overblog\GraphQLBundle\Relay\Connection\Output;
6
7
use GraphQL\Executor\Promise\Promise;
8
use Overblog\GraphQLBundle\Relay\Connection\ConnectionInterface;
9
use Overblog\GraphQLBundle\Relay\Connection\EdgeInterface;
10
use Overblog\GraphQLBundle\Relay\Connection\PageInfoInterface;
11
12
class Connection implements ConnectionInterface
13
{
14
    use DeprecatedPropertyPublicAccessTrait;
15
16
    /** @var EdgeInterface[] */
17
    protected array $edges;
18
19
    protected ?PageInfoInterface $pageInfo;
20
21
    /** @var int|Promise|null Total count or promise that returns the total count */
22
    protected $totalCount = null;
23
24 92
    public function __construct(array $edges = [], PageInfoInterface $pageInfo = null)
25
    {
26 92
        $this->edges = $edges;
27 92
        $this->pageInfo = $pageInfo;
28 92
    }
29
30
    /**
31
     * {@inheritdoc}
32
     */
33 89
    public function getEdges(): array
34
    {
35 89
        return $this->edges;
36
    }
37
38
    /**
39
     * {@inheritdoc}
40
     */
41 2
    public function setEdges(iterable $edges): void
42
    {
43 2
        $this->edges = $edges;
0 ignored issues
show
Documentation Bug introduced by
It seems like $edges of type iterable is incompatible with the declared type Overblog\GraphQLBundle\R...nection\EdgeInterface[] of property $edges.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
44 2
    }
45
46
    /**
47
     * {@inheritdoc}
48
     */
49 71
    public function getPageInfo(): ? PageInfoInterface
50
    {
51 71
        return $this->pageInfo;
52
    }
53
54
    /**
55
     * {@inheritdoc}
56
     */
57 1
    public function setPageInfo(PageInfoInterface $pageInfo): void
58
    {
59 1
        $this->pageInfo = $pageInfo;
60 1
    }
61
62
    /**
63
     * {@inheritdoc}
64
     */
65 57
    public function getTotalCount()
66
    {
67 57
        return $this->totalCount;
68
    }
69
70
    /**
71
     * {@inheritdoc}
72
     */
73 4
    public function setTotalCount($totalCount): void
74
    {
75 4
        $this->totalCount = $totalCount;
76 4
    }
77
}
78