mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-08-04 12:24:00 +01:00
Fix unknown recipient crash.
This commit is contained in:
+5
@@ -65,6 +65,11 @@ class ConversationShortcutRankingUpdateJob private constructor(
|
||||
override fun getFactoryKey() = KEY
|
||||
|
||||
override fun onRun() {
|
||||
if (recipient.id.isUnknown) {
|
||||
Log.w(TAG, "Recipient no longer exists. Skipping shortcut update.")
|
||||
return
|
||||
}
|
||||
|
||||
if (SignalStore.settings.screenLockEnabled) {
|
||||
Log.i(TAG, "Screen lock enabled. Clearing shortcuts.")
|
||||
ConversationUtil.clearAllShortcuts(context)
|
||||
|
||||
@@ -488,7 +488,12 @@ public final class SignalCallManager implements CallManager.Observer, GroupCall.
|
||||
|
||||
keyedExecutor.execute(id.toString(), () -> {
|
||||
try {
|
||||
Recipient group = Recipient.resolved(id);
|
||||
Recipient group = Recipient.resolved(id);
|
||||
if (!group.getGroupId().isPresent()) {
|
||||
Log.w(TAG, "Recipient " + id + " is no longer a group. Skipping peek.");
|
||||
return;
|
||||
}
|
||||
|
||||
GroupId.V2 groupId = group.requireGroupId().requireV2();
|
||||
ExternalGroupCredential credential = GroupManager.getExternalGroupCredential(context, groupId);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user