Skip to content

Commit

Permalink
MDL-67882 message: Add notification setting changes to config_log
Browse files Browse the repository at this point in the history
  • Loading branch information
brendanheywood committed Mar 24, 2021
1 parent fc335f5 commit f0aae55
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions admin/message.php
Expand Up @@ -119,10 +119,19 @@
// Save processors enabled/disabled status.
foreach ($allprocessors as $processor) {
$enabled = isset($form->{$processor->name});
if ($enabled != $processor->enabled) {
add_to_config_log($processor->name, $processor->enabled, $enabled, 'core');
}
\core_message\api::update_processor_status($processor, $enabled);
}

foreach ($newpreferences as $name => $value) {
$old = isset($preferences->$name) ? $preferences->$name : '';

if ($old != $value) {
add_to_config_log($name, $old, $value, 'core');
}

set_config($name, $value, 'message');
}
$transaction->allow_commit();
Expand Down

0 comments on commit f0aae55

Please sign in to comment.