From 5f4e2673f3f7e853a8301e5835f0b47d8eb85fa2 Mon Sep 17 00:00:00 2001 From: Sunil Mohan Adapa Date: Thu, 10 Sep 2020 21:48:45 -0700 Subject: [PATCH] quassel: Don't handle certificates if not installed Tests: - Without these changes, with Quassel not-installed, change the domain name. Notice that certificate events for Quassel fails due to missing domain information. - With these changes, with Quassel not-installed, change the domain name. Notice that certificate events for Quassel don't result in any actions. - With these changes, with Quassel installed, change the domain name. Notice that certificate events for Quassel succeed. Signed-off-by: Sunil Mohan Adapa Reviewed-by: James Valleroy --- plinth/modules/quassel/__init__.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/plinth/modules/quassel/__init__.py b/plinth/modules/quassel/__init__.py index bee065c40..8b39c6668 100644 --- a/plinth/modules/quassel/__init__.py +++ b/plinth/modules/quassel/__init__.py @@ -134,6 +134,10 @@ def get_domain(): def get_domains(): """Return a list with the configured domain for quassel.""" + setup_helper = globals()['setup_helper'] + if setup_helper.get_state() == 'needs-setup': + return [] + domain = get_domain() if domain: return [domain]