function FeedItemsDeleteForm::submitForm

Same name in other branches
  1. 9 core/modules/aggregator/src/Form/FeedItemsDeleteForm.php \Drupal\aggregator\Form\FeedItemsDeleteForm::submitForm()

Overrides ContentEntityForm::submitForm

File

core/modules/aggregator/src/Form/FeedItemsDeleteForm.php, line 40

Class

FeedItemsDeleteForm
Provides a deletion confirmation form for items that belong to a feed.

Namespace

Drupal\aggregator\Form

Code

public function submitForm(array &$form, FormStateInterface $form_state) {
    $this->entity
        ->deleteItems();
    $form_state->setRedirectUrl($this->getCancelUrl());
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.