You are here

public function WebhookDeleteConfirmForm::submitForm in Acquia Content Hub 8.2

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/acquia_contenthub_publisher/src/Form/Webhook/WebhookDeleteConfirmForm.php, line 157

Class

WebhookDeleteConfirmForm
Confirmation form for webhook deletion.

Namespace

Drupal\acquia_contenthub_publisher\Form\Webhook

Code

public function submitForm(array &$form, FormStateInterface $form_state) {
  if ($form_state
    ->getTriggeringElement()['#name'] === 'cancel') {
    $form_state
      ->setRedirect('acquia_contenthub.subscription_settings');
  }
}