trim inline meta data to fix sniffing (required for DM messages)

This commit is contained in:
David Kaspar
2025-03-18 12:55:31 +00:00
parent 2f29a21d72
commit cdf2b10fd2
@@ -120,7 +120,7 @@ object MediaSaverToDisk {
check(response.isSuccessful)
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) {
val contentType = response.header("Content-Type") ?: getMimeTypeFromExtension(url)
val contentType = response.header("Content-Type") ?: getMimeTypeFromExtension(trimInlineMetaData(url))
check(contentType.isNotBlank()) { "Can't find out the content type" }
val realType =