We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 235863f commit 81c7d90Copy full SHA for 81c7d90
1 file changed
app/src/main/java/com/lagradost/cloudstream3/utils/SubtitleUtils.kt
@@ -43,7 +43,7 @@ object SubtitleUtils {
43
cleanDisplay: String
44
): Boolean {
45
// Check if the file has a valid subtitle extension
46
- val hasValidExtension = allowedExtensions.any { name.contains(it, ignoreCase = true) }
+ val hasValidExtension = allowedExtensions.any { name.endsWith(it, ignoreCase = true) }
47
48
// We can't have the exact same file as a subtitle
49
val isNotDisplayName = !name.equals(display, ignoreCase = true)
@@ -57,4 +57,4 @@ object SubtitleUtils {
57
fun cleanDisplayName(name: String): String {
58
return name.substringBeforeLast('.').trim()
59
}
60
-}
+}
0 commit comments