| Conditions | 1 |
| Paths | 1 |
| Total Lines | 10 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 22 | protected function resolveValues($value, array $args, ResolveInfo $info) { |
||
| 23 | /** @var \Drupal\Core\Language\LanguageInterface $context */ |
||
| 24 | $context = $value['context']; |
||
| 25 | /** @var \Drupal\Core\Language\LanguageInterface $language */ |
||
| 26 | $language = $value['link']['language']; |
||
| 27 | |||
| 28 | // Check if the link's language code matches the language from the current |
||
| 29 | // url context used for retrieving the language switch links. |
||
| 30 | yield $context->getId() === $language->getId(); |
||
| 31 | } |
||
| 32 | |||
| 34 |