You are here

public function MultiversionFieldItemList::delete in Multiversion 8

Same name and namespace in other branches
  1. 8.2 src/MultiversionFieldItemList.php \Drupal\multiversion\MultiversionFieldItemList::delete()

@inheritDoc

Overrides PathFieldItemList::delete

File

src/MultiversionFieldItemList.php, line 12

Class

MultiversionFieldItemList

Namespace

Drupal\multiversion

Code

public function delete() {
  \Drupal::service('pathauto.alias_storage_helper')
    ->deleteEntityPathAll($this
    ->getEntity());
  if ($first = $this
    ->first()) {
    $first
      ->get('pathauto')
      ->purge();
  }
}