From 3b780c32effb58caf509dace01ca596340bd33fc Mon Sep 17 00:00:00 2001 From: M66B Date: Sun, 28 Jun 2020 08:56:11 +0200 Subject: [PATCH] Accept full domain regex Closes #181 --- app/src/main/java/eu/faircode/email/EntityIdentity.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/eu/faircode/email/EntityIdentity.java b/app/src/main/java/eu/faircode/email/EntityIdentity.java index 35f5c54a3b..fa75f4b00d 100644 --- a/app/src/main/java/eu/faircode/email/EntityIdentity.java +++ b/app/src/main/java/eu/faircode/email/EntityIdentity.java @@ -154,7 +154,8 @@ public class EntityIdentity { if (user.equalsIgnoreCase(cemail[0])) return true; } else { - if (Pattern.matches(sender_extra_regex, cother[0])) + String input = (sender_extra_regex.contains("@") ? other : cother[0]); + if (Pattern.matches(sender_extra_regex, input)) return true; }