Commit 010d52a3 authored by marcvangend's avatar marcvangend Committed by Erik Stielstra

Issue #2613144 by marcvangend: Field default value does not show in the block

parent e23e7745
......@@ -324,7 +324,7 @@ class FieldBlock extends BlockBase implements ContainerFactoryPluginInterface {
if ($entity instanceof ContentEntityInterface && $entity->getEntityTypeId() === $entity_type && $entity->hasField($this->configuration['field_name'])) {
$field = $entity->get($this->configuration['field_name']);
return AccessResult::allowedIf(!$field->isEmpty() && $field->access('view', $account));
return AccessResult::allowedIf($field->access('view', $account));
return AccessResult::forbidden();
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment