public function UnflagConfirmForm::submitForm in Flag 8.4
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/ UnflagConfirmForm.php, line 47
Class
- UnflagConfirmForm
- Provides the confirm form page for unflagging an entity.
Namespace
Drupal\flag\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
\Drupal::service('flag')
->unflag($this->flag, $this->entity);
}