| Conditions | 2 |
| Paths | 2 |
| Total Lines | 18 |
| Code Lines | 12 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php declare(strict_types=1); |
||
| 30 | public function toGraphql(): string |
||
| 31 | { |
||
| 32 | $args = array_map( |
||
| 33 | function (ValidatorArgs $a) { |
||
| 34 | return $a->toGraphql(); |
||
| 35 | }, |
||
| 36 | $this->args |
||
| 37 | ); |
||
| 38 | |||
| 39 | $argString = ''; |
||
| 40 | if ($args) { |
||
| 41 | $argString = "(\n" . join("\n", $args) . ')'; |
||
| 42 | } |
||
| 43 | return <<< EOF |
||
| 44 | """ |
||
| 45 | {$this->comment} |
||
| 46 | """ |
||
| 47 | directive @{$this->name}{$argString} on FIELD_DEFINITION |
||
| 48 | |||
| 52 |
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.