Group Migration: Don't bump to top of list if we're not in group

This commit is contained in:
Scott Nonnenberg 2022-03-01 16:13:17 -08:00 committed by GitHub
parent cfa0711909
commit 1656b61a82
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2696,11 +2696,11 @@ async function updateGroup(
const startingRevision = conversation.get('revision');
const endingRevision = newAttributes.revision;
const isInitialDataFetch =
!isNumber(startingRevision) && isNumber(endingRevision);
const isInGroup = !updates.newAttributes.left;
const isInitialDataFetch =
isInGroup && !isNumber(startingRevision) && isNumber(endingRevision);
const justJoinedGroup =
!conversation.hasMember(ourUuid.toString()) && isInGroup;
isInGroup && !conversation.hasMember(ourUuid.toString());
// Ensure that all generated messages are ordered properly.
// Before the provided timestamp so update messages appear before the