You are here

public function FlushAllForm::submitForm in Textimage 8.4

Same name and namespace in other branches
  1. 8.3 src/Form/FlushAllForm.php \Drupal\textimage\Form\FlushAllForm::submitForm()

Form submission handler.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

Overrides FormInterface::submitForm

File

src/Form/FlushAllForm.php, line 80

Class

FlushAllForm
Creates a form to confirm flushing of all Textimage images.

Namespace

Drupal\textimage\Form

Code

public function submitForm(array &$form, FormStateInterface $form_state) {
  $this->textimageFactory
    ->flushAll();
  $form_state
    ->setRedirect('textimage.settings');
}