public function SubscriberSettingsForm::submitForm in Simplenews 8
Same name and namespace in other branches
- 8.2 src/Form/SubscriberSettingsForm.php \Drupal\simplenews\Form\SubscriberSettingsForm::submitForm()
- 3.x src/Form/SubscriberSettingsForm.php \Drupal\simplenews\Form\SubscriberSettingsForm::submitForm()
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
- src/
Form/ SubscriberSettingsForm.php, line 57
Class
- SubscriberSettingsForm
- Configure simplenews newsletter settings.
Namespace
Drupal\simplenews\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$this
->config('simplenews.settings')
->set('subscriber.sync_fields', $form_state
->getValue('simplenews_sync_fields'))
->save();
parent::submitForm($form, $form_state);
}