mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2025-01-31 11:24:58 +01:00
Fix crash for huge inline pictures
Change-Id: I9968e7fd95aa11d524a57c2186d518262fed5aa0
This commit is contained in:
parent
fd34eba596
commit
2631d5c3a2
@ -98,7 +98,8 @@ class EventHtmlRenderer @Inject constructor(
|
||||
if (url.isMxcUrl()) {
|
||||
val contentUrlResolver = activeSessionHolder.getActiveSession().contentUrlResolver()
|
||||
val imageUrl = contentUrlResolver.resolveFullSize(url)
|
||||
return Glide.with(context).load(imageUrl)
|
||||
// Override size to avoid crashes for huge pictures
|
||||
return Glide.with(context).load(imageUrl).override(500)
|
||||
}
|
||||
// We don't want to support other url schemes here, so just return a request for null
|
||||
return Glide.with(context).load(null as String?)
|
||||
|
Loading…
x
Reference in New Issue
Block a user