Stop checking very old capabilities.

This commit is contained in:
Greyson Parrelli
2022-09-30 10:49:29 -04:00
parent afe36b982f
commit 52965da8a5
14 changed files with 129 additions and 211 deletions

View File

@@ -242,8 +242,7 @@ public final class GroupSendUtil {
validMembership = false;
}
if (recipient.getSenderKeyCapability() == Recipient.Capability.SUPPORTED &&
recipient.hasServiceId() &&
if (recipient.hasServiceId() &&
access.isPresent() &&
access.get().getTargetUnidentifiedAccess().isPresent() &&
validMembership)
@@ -258,10 +257,6 @@ public final class GroupSendUtil {
Log.i(TAG, "No DistributionId. Using legacy.");
legacyTargets.addAll(senderKeyTargets);
senderKeyTargets.clear();
} else if (Recipient.self().getSenderKeyCapability() != Recipient.Capability.SUPPORTED) {
Log.i(TAG, "All of our devices do not support sender key. Using legacy.");
legacyTargets.addAll(senderKeyTargets);
senderKeyTargets.clear();
} else if (SignalStore.internalValues().removeSenderKeyMinimum()) {
Log.i(TAG, "Sender key minimum removed. Using for " + senderKeyTargets.size() + " recipients.");
} else if (senderKeyTargets.size() < 2) {

View File

@@ -127,7 +127,7 @@ public final class MessageDecryptionUtil {
Log.w(TAG, String.valueOf(envelope.getTimestamp()), e, true);
Recipient sender = Recipient.external(context, e.getSender());
if (sender.supportsMessageRetries() && Recipient.self().supportsMessageRetries() && FeatureFlags.retryReceipts()) {
if (FeatureFlags.retryReceipts()) {
jobs.add(handleRetry(context, sender, envelope, e));
postInternalErrorNotification(context);
} else {