Merge pull request #5091 from vector-im/feature/adm/timeline-item-crash

Timeline recycling crash
This commit is contained in:
Benoit Marty 2022-01-28 13:40:16 +01:00 committed by GitHub
commit c487add2cd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 0 deletions

1
changelog.d/5091.bugfix Normal file
View File

@ -0,0 +1 @@
Fixing crashes when quickly scrolling or restoring the room timeline

View File

@ -109,6 +109,7 @@ abstract class MessageTextItem : AbsMessageItem<MessageTextItem.Holder>() {
val textFuture = PrecomputedTextCompat.getTextFuture(message, TextViewCompat.getTextMetricsParams(this), null)
setTextFuture(textFuture)
} else {
setTextFuture(null)
text = message
}
}