From 4b9c6cfd7177d373864fdbefb5e4e859872f6df5 Mon Sep 17 00:00:00 2001 From: Zedifus Date: Tue, 28 Nov 2023 02:22:25 +0000 Subject: [PATCH] Fix sonar finding Use the opposite operator ("not in") instead. Boolean checks should not be inverted python:S1940 --- app/classes/shared/main_models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/classes/shared/main_models.py b/app/classes/shared/main_models.py index f57b2bfd..c166b7fb 100644 --- a/app/classes/shared/main_models.py +++ b/app/classes/shared/main_models.py @@ -18,7 +18,7 @@ class DatabaseBuilder: logger.info("Fresh Install Detected - Creating Default Settings") Console.info("Fresh Install Detected - Creating Default Settings") default_data = self.helper.find_default_password() - if not password in default_data: + if password not in default_data: Console.help( "No default password found. Using password created " "by Crafty. Find it in app/config/default-creds.txt"