You are here

public function QueueChangeForm::submitForm in Purge 8.3

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

modules/purge_ui/src/Form/QueueChangeForm.php, line 110

Class

QueueChangeForm
The queue data browser.

Namespace

Drupal\purge_ui\Form

Code

public function submitForm(array &$form, FormStateInterface $form_state) {
  $plugin_id = $form_state
    ->getValue('plugin_id');
  if (in_array($plugin_id, array_keys($this->purgeQueue
    ->getPlugins()))) {
    $this->purgeQueue
      ->setPluginsEnabled([
      $plugin_id,
    ]);
  }
}