1 | <?php |
||
14 | class ObjectType extends AbstractObjectType implements TypeSystemPluginReferenceInterface, CacheableEdgeInterface { |
||
15 | use TypeSystemPluginReferenceTrait; |
||
16 | use CacheableEdgeTrait; |
||
17 | |||
18 | /** |
||
19 | * {@inheritdoc} |
||
20 | */ |
||
21 | public function __construct(TypePluginBase $plugin, array $config = []) { |
||
25 | |||
26 | /** |
||
27 | * {@inheritdoc} |
||
28 | */ |
||
29 | public function getName() { |
||
32 | |||
33 | /** |
||
34 | * Checks whether this type applies to a given object. |
||
35 | * |
||
36 | * @param mixed $object |
||
37 | * The object to check against. |
||
38 | * @param \Youshido\GraphQL\Execution\ResolveInfo|null $info |
||
39 | * The resolve info object. |
||
40 | * |
||
41 | * @return bool |
||
42 | * TRUE if this type applies to the given object, FALSE otherwise. |
||
43 | */ |
||
44 | public function applies($object, ResolveInfo $info = NULL) { |
||
51 | |||
52 | /** |
||
53 | * {@inheritdoc} |
||
54 | */ |
||
55 | public function build($config) { |
||
58 | |||
59 | } |
||
60 |
It seems like you allow that null is being passed for a parameter, however the function which is called does not seem to accept null.
We recommend to add an additional type check (or disallow null for the parameter):