You are here

public function EntityLazyLoadContext::hasContextValue in Page Manager 8

Same name and namespace in other branches
  1. 8.4 src/Context/EntityLazyLoadContext.php \Drupal\page_manager\Context\EntityLazyLoadContext::hasContextValue()

Returns whether the context has a value.

Return value

bool TRUE if the context has a value, FALSE otherwise.

Overrides Context::hasContextValue

File

src/Context/EntityLazyLoadContext.php, line 63
Contains \Drupal\page_manager\Context\EntityLazyLoadContext.

Class

EntityLazyLoadContext
@todo.

Namespace

Drupal\page_manager\Context

Code

public function hasContextValue() {

  // Ensure that the entity is loaded before checking if it exists.
  if (!$this->contextData) {
    $this
      ->getContextValue();
  }
  return parent::hasContextValue();
}