From c772534a35cf5a6fa87730d3a42800a3c8186b10 Mon Sep 17 00:00:00 2001 From: Sunil Mohan Adapa Date: Tue, 21 Jun 2022 13:35:59 -0700 Subject: [PATCH] mumble: Don't set the root channel name unless it is changed Signed-off-by: Sunil Mohan Adapa Reviewed-by: James Valleroy --- plinth/modules/mumble/views.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plinth/modules/mumble/views.py b/plinth/modules/mumble/views.py index 7fe1db6bc..d7406b61a 100644 --- a/plinth/modules/mumble/views.py +++ b/plinth/modules/mumble/views.py @@ -26,6 +26,7 @@ class MumbleAppView(AppView): def form_valid(self, form): """Apply form changes.""" + old_config = self.get_initial() new_config = form.cleaned_data if mumble.get_domain() != new_config['domain']: @@ -45,7 +46,7 @@ class MumbleAppView(AppView): messages.success(self.request, _('Join password changed')) name = new_config.get('root_channel_name') - if name: + if old_config['root_channel_name'] != new_config['root_channel_name']: privileged.change_root_channel_name(name) messages.success(self.request, _('Root channel name changed.'))