From 9727b884b38a7537215ef6f324ef02ba901cef52 Mon Sep 17 00:00:00 2001 From: Ahmed Awan Date: Mon, 1 Jul 2024 13:43:19 -0500 Subject: [PATCH] remove else block and return `None` by the outer conditional --- lib/galaxy/managers/users.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/galaxy/managers/users.py b/lib/galaxy/managers/users.py index 4a9501585ee2..c905443f4498 100644 --- a/lib/galaxy/managers/users.py +++ b/lib/galaxy/managers/users.py @@ -608,8 +608,7 @@ def send_reset_email(self, trans, payload, **kwd): except Exception as e: log.debug(body) return f"Failed to submit email. Please contact the administrator: {util.unicodify(e)}" - else: - return None + return None def get_reset_token(self, trans, email): reset_user = get_user_by_email(trans.sa_session, email, self.app.model.User)