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

Passed
Pull Request — master (#292)
by Jérémiah
16:02
created

ExtensibleSchema   A

Complexity

Total Complexity 5

Size/Duplication

Total Lines 40
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 5
lcom 1
cbo 2
dl 0
loc 40
ccs 12
cts 12
cp 1
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A setExtensions() 0 9 2
A addExtension() 0 4 1
A processExtensions() 0 8 2
1
<?php
2
3
namespace Overblog\GraphQLBundle\Definition\Type;
4
5
use GraphQL\Type\Schema;
6
use Overblog\GraphQLBundle\Definition\Type\SchemaExtension\SchemaExtensionInterface;
7
8
class ExtensibleSchema extends Schema
9
{
10
    /** @var SchemaExtensionInterface[] */
11
    private $extensions = [];
12
13
    /**
14
     * @param SchemaExtensionInterface[] $extensions
15
     *
16
     * @return $this
17
     */
18 72
    public function setExtensions(array $extensions)
19
    {
20 72
        $this->extensions = [];
21 72
        foreach ($extensions as $extension) {
22 72
            $this->addExtension($extension);
23
        }
24
25 72
        return $this;
26
    }
27
28
    /**
29
     * @param SchemaExtensionInterface $extension
30
     */
31 72
    public function addExtension(SchemaExtensionInterface $extension)
32
    {
33 72
        $this->extensions[] = $extension;
34 72
    }
35
36
    /**
37
     * @return $this
38
     */
39 68
    public function processExtensions()
40
    {
41 68
        foreach ($this->extensions as $extension) {
42 66
            $extension->process($this);
43
        }
44
45 68
        return $this;
46
    }
47
}
48