protected function ComponentBlock::contextHandler in Component blocks 1.x
Same name and namespace in other branches
- 1.0.x src/Plugin/Block/ComponentBlock.php \Drupal\component_blocks\Plugin\Block\ComponentBlock::contextHandler()
- 1.1.x src/Plugin/Block/ComponentBlock.php \Drupal\component_blocks\Plugin\Block\ComponentBlock::contextHandler()
Wraps the context handler.
Return value
\Drupal\Core\Plugin\Context\ContextHandlerInterface
Overrides ContextAwarePluginAssignmentTrait::contextHandler
File
- src/
Plugin/ Block/ ComponentBlock.php, line 478
Class
- ComponentBlock
- Defines a class for a specially shaped block.
Namespace
Drupal\component_blocks\Plugin\BlockCode
protected function contextHandler() {
// phpcs:disable DrupalPractice.Objects.GlobalDrupal.GlobalDrupal
return $this->contextHandler ?: \Drupal::service('context.handler');
}