Fixed off-by-one crash when navigating to message from FTS.

Related to #8145
pull/1/head
Greyson Parrelli 7 years ago
parent da60cac833
commit a1b2887bf3

@ -465,7 +465,7 @@ public class ConversationFragment extends Fragment
int limit = args.getInt(KEY_LIMIT, PARTIAL_CONVERSATION_LIMIT);
int offset = 0;
if (limit != 0 && startingPosition > limit) {
if (limit != 0 && startingPosition >= limit) {
offset = Math.max(startingPosition - (limit / 2) + 1, 0);
startingPosition -= offset - 1;
}

Loading…
Cancel
Save