Failed Conditions
Push — master ( c4208e...4b96fe )
by Sylvain
09:02
created

ExcelExport   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
eloc 7
dl 0
loc 11
c 0
b 0
f 0
ccs 0
cts 8
cp 0
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A build() 0 9 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Application\Api\Field\Query;
6
7
use Application\Api\Field\FieldInterface;
8
use GraphQL\Type\Definition\Type;
9
10
abstract class ExcelExport implements FieldInterface
11
{
12
    public static function build(): array
13
    {
14
        return
15
            [
16
                'name' => 'excelExport',
17
                'type' => Type::nonNull(Type::string()),
18
                'description' => 'URL to download the Excel listing',
19
                'resolve' => function ($root, array $args): string {
2 ignored issues
show
Unused Code introduced by
The parameter $args is not used and could be removed. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-unused  annotation

19
                'resolve' => function ($root, /** @scrutinizer ignore-unused */ array $args): string {

This check looks for parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
Unused Code introduced by
The parameter $root is not used and could be removed. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-unused  annotation

19
                'resolve' => function (/** @scrutinizer ignore-unused */ $root, array $args): string {

This check looks for parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
20
                    return 'test';
21
                },
22
            ];
23
    }
24
}
25