Don't block messages from unknown groups.

We were incorrectly considering unknown groups to have been "left".
This commit is contained in:
Greyson Parrelli 2018-09-25 10:00:14 -07:00
parent c5f53b23fa
commit 6eb8693546
1 changed files with 4 additions and 0 deletions

View File

@ -961,6 +961,10 @@ public class PushDecryptJob extends ContextJob {
Optional<String> groupId = message.getGroupInfo().isPresent() ? Optional.of(GroupUtil.getEncodedId(message.getGroupInfo().get().getGroupId(), false))
: Optional.absent();
if (groupId.isPresent() && groupDatabase.isUnknownGroup(groupId.get())) {
return false;
}
boolean isTextMessage = message.getBody().isPresent();
boolean isMediaMessage = message.getAttachments().isPresent() || message.getQuote().isPresent() || message.getSharedContacts().isPresent();
boolean isExpireMessage = message.isExpirationUpdate();