You are here

protected function EntityShareBlockFieldEnhancer::doTransform in Entity Share 8.2

Same name and namespace in other branches
  1. 8.3 src/Plugin/jsonapi/FieldEnhancer/EntityShareBlockFieldEnhancer.php \Drupal\entity_share\Plugin\jsonapi\FieldEnhancer\EntityShareBlockFieldEnhancer::doTransform()

File

src/Plugin/jsonapi/FieldEnhancer/EntityShareBlockFieldEnhancer.php, line 104

Class

EntityShareBlockFieldEnhancer
Prepare block field value to be able to handle block content entities.

Namespace

Drupal\entity_share\Plugin\jsonapi\FieldEnhancer

Code

protected function doTransform($value, Context $context) {
  if (isset($value['block_content_href'])) {
    unset($value['block_content_href']);
  }
  return $value;
}