From 79768c09f62b6afe20fd05041147d086a48a1845 Mon Sep 17 00:00:00 2001 From: hoellen Date: Sun, 9 Dec 2018 19:49:23 +0100 Subject: [PATCH] fix alias matching behaviour --- core/admin/mailu/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/admin/mailu/models.py b/core/admin/mailu/models.py index 18e995bf..1463af8e 100644 --- a/core/admin/mailu/models.py +++ b/core/admin/mailu/models.py @@ -426,7 +426,7 @@ class Alias(Base, Email): ) ) ) - ).first() + ).order_by(sqlalchemy.func.char_length(cls.localpart).desc()).first() class Token(Base):