From 768bf2b22cfe827482a375d53186b88d9183c848 Mon Sep 17 00:00:00 2001 From: missytake Date: Thu, 18 Jan 2024 17:09:23 +0100 Subject: [PATCH] greeterbot: better comparison method Co-authored-by: holger krekel --- chatmaild/src/chatmaild/doveauth.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chatmaild/src/chatmaild/doveauth.py b/chatmaild/src/chatmaild/doveauth.py index c937cbeb..138497bc 100644 --- a/chatmaild/src/chatmaild/doveauth.py +++ b/chatmaild/src/chatmaild/doveauth.py @@ -46,7 +46,7 @@ def is_allowed_to_create(config: Config, user, cleartext_password) -> bool: len(localpart) > config.username_max_length or len(localpart) < config.username_min_length ): - if localpart != "echo" and localpart != "hello": + if localpart not in ("echo", "hello"): logging.warning( "localpart %s has to be between %s and %s chars long", localpart,