You are here

public function EntityReferenceDisplayItem::isEmpty in Entity Reference Display 8

Determines whether the data structure is empty.

Return value

bool TRUE if the data structure is empty, FALSE otherwise.

Overrides Map::isEmpty

File

src/Plugin/Field/FieldType/EntityReferenceDisplayItem.php, line 88

Class

EntityReferenceDisplayItem
Plugin implementation of the 'entity_reference_display' field type.

Namespace

Drupal\entity_reference_display\Plugin\Field\FieldType

Code

public function isEmpty() {
  $value = $this
    ->get('value')
    ->getValue();
  return $value === NULL || $value === '';
}