mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-02-23 19:26:17 +00:00
Fix crash if recipient appears multiple times in group update description.
Without starting from start index, if the same recipient appears multiple times in the recipient list, this function will crash.
This commit is contained in:
@@ -871,7 +871,7 @@ final class GroupsV2UpdateMessageProducer {
|
||||
|
||||
for (RecipientId recipientId : recipientIds) {
|
||||
String placeholder = makePlaceholder(recipientId);
|
||||
int placeHolderStart = template.indexOf(placeholder);
|
||||
int placeHolderStart = template.indexOf(placeholder, startIndex);
|
||||
String beforeChunk = template.substring(startIndex, placeHolderStart);
|
||||
|
||||
builder.append(beforeChunk);
|
||||
|
||||
Reference in New Issue
Block a user