You are here

public function PathConfigForm::submitForm in JSON Web Token Authentication (JWT) 8

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 ConfigFormBase::submitForm

File

modules/jwt_path_auth/src/Form/PathConfigForm.php, line 72

Class

PathConfigForm
Class ConfigForm.

Namespace

Drupal\jwt_path_auth\Form

Code

public function submitForm(array &$form, FormStateInterface $form_state) {
  parent::submitForm($form, $form_state);
  $prefix_list = $form_state
    ->getTemporaryValue('prefix_list');
  $this
    ->config('jwt_path_auth.config')
    ->set('allowed_path_prefixes', $prefix_list)
    ->save();
}