You are here

function syslog_logging_settings_submit in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/syslog/syslog.module \syslog_logging_settings_submit()

Form submission handler for system_logging_settings().

See also

syslog_form_system_logging_settings_alter()

1 string reference to 'syslog_logging_settings_submit'
syslog_form_system_logging_settings_alter in core/modules/syslog/syslog.module
Implements hook_form_FORM_ID_alter().

File

core/modules/syslog/syslog.module, line 70
Redirects logging messages to syslog.

Code

function syslog_logging_settings_submit($form, FormStateInterface $form_state) {
  \Drupal::configFactory()
    ->getEditable('syslog.settings')
    ->set('identity', $form_state
    ->getValue('syslog_identity'))
    ->set('facility', $form_state
    ->getValue('syslog_facility'))
    ->set('format', $form_state
    ->getValue('syslog_format'))
    ->save();
}