Passed
Push — master ( 781e53...d845af )
by Bruno
09:45
created

LaravelMediaLibraryDataDirective   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 5
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 18
c 1
b 0
f 0
dl 0
loc 5
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A definition() 0 3 1
1
<?php declare(strict_types=1);
2
3
namespace Modelarium\Laravel\Lighthouse\Directives;
4
5
use Nuwave\Lighthouse\Schema\Directives\BaseDirective;
6
use Nuwave\Lighthouse\Support\Contracts\DefinedDirective;
7
8
class LaravelMediaLibraryDataDirective extends BaseDirective implements DefinedDirective
0 ignored issues
show
Deprecated Code introduced by
The interface Nuwave\Lighthouse\Suppor...tracts\DefinedDirective has been deprecated: The method definition() will be moved to ( Ignorable by Annotation )

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

8
class LaravelMediaLibraryDataDirective extends BaseDirective implements /** @scrutinizer ignore-deprecated */ DefinedDirective

This interface has been deprecated. The supplier of the interface has supplied an explanatory message.

The explanatory message should give you some clue as to whether and when the interface will be removed and what other interface to use instead.

Loading history...
9
{
10
    public static function definition(): string
11
    {
12
        return /** @lang GraphQL */ <<<'SDL'
13
"""
14
Implement the Laravel Media Library attributes on a model
15
"""
16
directive @laravelMediaLibraryData (
17
    """
18
    The collection name to use
19
    """
20
    collection: String
21
22
    """
23
    The list of fields to compose in the index
24
    """
25
    fields: [String!]
26
) on FIELD_DEFINITION
27
28
SDL;
29
    }
30
}
31