Fix processing of unsupported messages.

master
Greyson Parrelli 2020-08-04 17:37:25 -04:00
parent dda8808173
commit 3664e6f96d
1 changed files with 7 additions and 4 deletions

View File

@ -236,10 +236,13 @@ public final class PushDecryptMessageJob extends BaseJob {
if (sender == null) throw new NoSenderException();
GroupId groupId = null;
try {
groupId = GroupUtil.idFromGroupContext(e.getGroup().orNull());
} catch (BadGroupIdException ex) {
Log.w(TAG, "Bad group id found in unsupported data message", ex);
if (e.getGroup().isPresent()) {
try {
groupId = GroupUtil.idFromGroupContext(e.getGroup().get());
} catch (BadGroupIdException ex) {
Log.w(TAG, "Bad group id found in unsupported data message", ex);
}
}
return new PushProcessMessageJob.ExceptionMetadata(sender,