You are here

public function Paths::validateConfigurationForm in Administration Language Negotiation 8

Form validation handler.

Parameters

array $form: An associative array containing the structure of the plugin form as built by static::buildConfigurationForm().

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form. Calling code should pass on a subform state created through \Drupal\Core\Form\SubformState::createForSubform().

Overrides ConditionPluginBase::validateConfigurationForm

File

src/Plugin/AdministrationLanguageNegotiationCondition/Paths.php, line 202

Class

Paths
Class for the Blacklisted paths condition plugin.

Namespace

Drupal\administration_language_negotiation\Plugin\AdministrationLanguageNegotiationCondition

Code

public function validateConfigurationForm(array &$form, FormStateInterface $form_state) {
  parent::validateConfigurationForm($form, $form_state);
  $form_state
    ->setValue($this
    ->getPluginId(), array_filter(array_map('trim', explode(PHP_EOL, $form_state
    ->getValue($this
    ->getPluginId())))));
}