From 8de926108170c2a0cd6cf098dd6b7d79191b437a Mon Sep 17 00:00:00 2001 From: Moxie Marlinspike Date: Fri, 4 Aug 2017 09:22:58 -0700 Subject: [PATCH] MMS addresses can be email addresses Fixes #6853 // FREEBIE --- src/org/thoughtcrime/securesms/database/MmsDatabase.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/org/thoughtcrime/securesms/database/MmsDatabase.java b/src/org/thoughtcrime/securesms/database/MmsDatabase.java index 90889b2986..248ae23aaf 100644 --- a/src/org/thoughtcrime/securesms/database/MmsDatabase.java +++ b/src/org/thoughtcrime/securesms/database/MmsDatabase.java @@ -280,7 +280,7 @@ public class MmsDatabase extends MessagingDatabase { PhoneNumberUtil.MatchType match; if (localNumber == null) match = PhoneNumberUtil.MatchType.NO_MATCH; - else match = PhoneNumberUtil.getInstance().isNumberMatch(localNumber, cc.toPhoneString()); + else match = PhoneNumberUtil.getInstance().isNumberMatch(localNumber, cc.serialize()); if (match == PhoneNumberUtil.MatchType.NO_MATCH || match == PhoneNumberUtil.MatchType.NOT_A_NUMBER) @@ -295,7 +295,7 @@ public class MmsDatabase extends MessagingDatabase { PhoneNumberUtil.MatchType match; if (localNumber == null) match = PhoneNumberUtil.MatchType.NO_MATCH; - else match = PhoneNumberUtil.getInstance().isNumberMatch(localNumber, to.toPhoneString()); + else match = PhoneNumberUtil.getInstance().isNumberMatch(localNumber, to.serialize()); if (match == PhoneNumberUtil.MatchType.NO_MATCH || match == PhoneNumberUtil.MatchType.NOT_A_NUMBER)