function LocaleSettingsForm::submitForm

Same name in other branches
  1. 9 core/modules/locale/src/Form/LocaleSettingsForm.php \Drupal\locale\Form\LocaleSettingsForm::submitForm()
  2. 8.9.x core/modules/locale/src/Form/LocaleSettingsForm.php \Drupal\locale\Form\LocaleSettingsForm::submitForm()
  3. 10 core/modules/locale/src/Form/LocaleSettingsForm.php \Drupal\locale\Form\LocaleSettingsForm::submitForm()

Overrides ConfigFormBase::submitForm

File

core/modules/locale/src/Form/LocaleSettingsForm.php, line 121

Class

LocaleSettingsForm
Configure locale settings for this site.

Namespace

Drupal\locale\Form

Code

public function submitForm(array &$form, FormStateInterface $form_state) {
    // Invalidate the cached translation status when the configuration setting
    // of 'use_source' changes.
    if ($form['use_source']['#default_value'] != $form_state->getValue('use_source')) {
        locale_translation_clear_status();
    }
    parent::submitForm($form, $form_state);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.