From 4a954eb8e70bda5819f63da9cd841f1579573413 Mon Sep 17 00:00:00 2001 From: "Jannis M. Hoffmann" Date: Mon, 4 Dec 2023 23:15:38 +0100 Subject: add multi language urls update translations use redis as session store add requirements.txt file to pin dependencies add proper subfolder support improve compatibility with python 3.9 correct js for login focus --- src/jwebmail/model/read_mails.py | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'src/jwebmail/model/read_mails.py') diff --git a/src/jwebmail/model/read_mails.py b/src/jwebmail/model/read_mails.py index f82b601..291fa1e 100644 --- a/src/jwebmail/model/read_mails.py +++ b/src/jwebmail/model/read_mails.py @@ -31,13 +31,12 @@ class QMailAuthuser: shell=True, timeout=2, ) - match completed_proc.returncode: - case 0: - return True - case 1: - return False - case n: - raise QMAuthError("authentication error", n) + if completed_proc.returncode == 0: + return True + if completed_proc.returncode == 1: + return False + else: + raise QMAuthError("authentication error", completed_proc.returncode) except TimeoutExpired: return False -- cgit v1.2.3