Log when passwords are being set/unset

This commit is contained in:
Daniel Berteaud 2015-07-14 11:47:39 +02:00
parent 489ad3aaae
commit 38f3083937
1 changed files with 2 additions and 2 deletions

View File

@ -445,8 +445,8 @@ helper modify_room => sub {
foreach my $field (keys %$room){
if (($old_room->{$field} // '' ) ne ($room->{$field} // '')){
if ($field =~ m/_password$/){
$old_room->{$field} = '<hidden>';
$room->{$field} = '<hidden>';
$old_room->{$field} = ($old_room->{$field}) ? '<hidden>' : '<unset>';
$room->{$field} = ($room->{$field}) ? '<hidden>' : '<unset>';
}
$mods .= $field . ": " . $old_room->{$field} . ' -> ' . $room->{$field} . "\n";
}