Fix crash when receiving GSE before state membership updated.

This commit is contained in:
Cody Henthorne
2024-07-31 16:32:46 -04:00
parent 79c7c2345f
commit e4966da3ef
2 changed files with 6 additions and 1 deletions

View File

@@ -325,7 +325,7 @@ class GroupsV2StateProcessor private constructor(
if (updatedGroupState == null || updatedGroupState == remoteGroupStateDiff.previousGroupState) {
Log.i(TAG, "$logPrefix Local state is at or later than server revision: ${currentLocalState?.revision ?: "null"}")
if (currentLocalState != null) {
if (currentLocalState != null && applyGroupStateDiffResult.remainingRemoteGroupChanges.isEmpty()) {
val endorsements = groupOperations.receiveGroupSendEndorsements(serviceIds.aci, currentLocalState, remoteGroupStateDiff.groupSendEndorsementsResponse)
if (endorsements != null) {