From 2c6faf70149f007d662e85b5112999a13c2ba8c0 Mon Sep 17 00:00:00 2001 From: Sunil Mohan Adapa Date: Wed, 26 Jul 2023 18:30:41 -0700 Subject: [PATCH] wireguard: Don't enable app when setup is rerun Tests: - Rerun setup after disabling the app. App is not enabled. Signed-off-by: Sunil Mohan Adapa Reviewed-by: James Valleroy --- plinth/modules/wireguard/__init__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plinth/modules/wireguard/__init__.py b/plinth/modules/wireguard/__init__.py index 0dc632196..49297e1e4 100644 --- a/plinth/modules/wireguard/__init__.py +++ b/plinth/modules/wireguard/__init__.py @@ -95,4 +95,5 @@ class WireguardApp(app_module.App): def setup(self, old_version): """Install and configure the app.""" super().setup(old_version) - self.enable() + if not old_version: + self.enable()