You are here

public function GpgKeyItem::isEmpty in Mailhandler 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/GpgKeyItem.php, line 56

Class

GpgKeyItem
Plugin implementation of the 'mailhandler_gpg' field type.

Namespace

Drupal\mailhandler\Plugin\Field\FieldType

Code

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