mirror of
https://github.com/kiwix/kiwix-android.git
synced 2025-09-22 03:54:18 -04:00
Merge pull request #2600 from s-ayush2903/fix/s-ayush2903/#2174-Issue-Opening-Bouquineux
fix: Issue opening Bouquineux
This commit is contained in:
commit
743b71fccc
@ -132,8 +132,8 @@ class ZimFileReader constructor(
|
||||
}.also { Log.d(TAG, "getting mimetype for $uri = $it") }
|
||||
|
||||
private fun mimeTypeFromReader(it: String) =
|
||||
// Truncate mime-type (everything after the first space
|
||||
jniKiwixReader.getMimeType(it.filePath)?.replace("^([^ ]+).*$", "$1")
|
||||
// Truncate mime-type (everything after the first space and semi-colon(if exists)
|
||||
jniKiwixReader.getMimeType(it.filePath)?.replace("^([^ ]+).*$", "$1")?.substringBefore(";")
|
||||
|
||||
fun getRedirect(url: String) = "${toRedirect(url)}"
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user