diff --git a/app/src/main/kotlin/org/dokiteam/doki/core/util/ext/String.kt b/app/src/main/kotlin/org/dokiteam/doki/core/util/ext/String.kt index deb4737..90840af 100644 --- a/app/src/main/kotlin/org/dokiteam/doki/core/util/ext/String.kt +++ b/app/src/main/kotlin/org/dokiteam/doki/core/util/ext/String.kt @@ -72,7 +72,7 @@ fun Collection.joinToStringWithLimit(context: Context, limit: Int, transf fun String.isHttpUrl() = startsWith("https://", ignoreCase = true) || startsWith("http://", ignoreCase = true) -fun String.isAnimatedImage() = endsWith(".gif", ignoreCase = true) || endsWith(".webp", ignoreCase = true) +fun String.isAnimatedImage() = substringBefore("?").run { endsWith(".gif", ignoreCase = true) || endsWith(".webp", ignoreCase = true) } fun concatStrings(context: Context, a: String?, b: String?): String? = when { a.isNullOrEmpty() && b.isNullOrEmpty() -> null