Ignore typing indicators from blocked group members.
This commit is contained in:
parent
5cd4726e23
commit
f140f054e5
1 changed files with 4 additions and 2 deletions
|
@ -1781,12 +1781,14 @@ public final class PushProcessMessageJob extends BaseJob {
|
||||||
} else if (content.getCallMessage().isPresent()) {
|
} else if (content.getCallMessage().isPresent()) {
|
||||||
return sender.isBlocked();
|
return sender.isBlocked();
|
||||||
} else if (content.getTypingMessage().isPresent()) {
|
} else if (content.getTypingMessage().isPresent()) {
|
||||||
|
if (sender.isBlocked()) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
if (content.getTypingMessage().get().getGroupId().isPresent()) {
|
if (content.getTypingMessage().get().getGroupId().isPresent()) {
|
||||||
GroupId groupId = GroupId.push(content.getTypingMessage().get().getGroupId().get());
|
GroupId groupId = GroupId.push(content.getTypingMessage().get().getGroupId().get());
|
||||||
Recipient groupRecipient = Recipient.externalGroup(context, groupId);
|
Recipient groupRecipient = Recipient.externalGroup(context, groupId);
|
||||||
return groupRecipient.isBlocked() || !groupRecipient.isActiveGroup();
|
return groupRecipient.isBlocked() || !groupRecipient.isActiveGroup();
|
||||||
} else {
|
|
||||||
return sender.isBlocked();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue