Fix displaying group quit messages

This commit is contained in:
AsamK 2021-05-01 16:02:21 +02:00
parent 08962fd1dc
commit a96bd91770

View file

@ -1754,6 +1754,7 @@ public class Manager implements Closeable {
// Store uuid if we don't have it already // Store uuid if we don't have it already
resolveRecipientTrusted(envelope.getSourceAddress()); resolveRecipientTrusted(envelope.getSourceAddress());
} }
final var notAGroupMember = isNotAGroupMember(envelope, content);
if (!envelope.isReceipt()) { if (!envelope.isReceipt()) {
try { try {
content = decryptMessage(envelope); content = decryptMessage(envelope);
@ -1779,7 +1780,7 @@ public class Manager implements Closeable {
account.save(); account.save();
if (isMessageBlocked(envelope, content)) { if (isMessageBlocked(envelope, content)) {
logger.info("Ignoring a message from blocked user/group: {}", envelope.getTimestamp()); logger.info("Ignoring a message from blocked user/group: {}", envelope.getTimestamp());
} else if (isNotAGroupMember(envelope, content)) { } else if (notAGroupMember) {
logger.info("Ignoring a message from a non group member: {}", envelope.getTimestamp()); logger.info("Ignoring a message from a non group member: {}", envelope.getTimestamp());
} else { } else {
handler.handleMessage(envelope, content, exception); handler.handleMessage(envelope, content, exception);