| Conditions | 1 |
| Paths | 1 |
| Total Lines | 12 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 22 | public function createFunction(array $config, Field $field) |
||
| 23 | { |
||
| 24 | return function ($node, array $arguments, ResolveInfo $info) { |
||
| 25 | /** @var ObjectType $parentType */ |
||
| 26 | $parentType = $info->parentType; |
||
| 27 | $field = $parentType->getField($info->fieldName); |
||
| 28 | |||
| 29 | $resolveConfig = $field->config['resolve_config']; |
||
| 30 | |||
| 31 | return call_user_func([$node, $resolveConfig['method']]); |
||
| 32 | }; |
||
| 33 | } |
||
| 34 | } |
||
| 35 |