diff --git a/app/src/main/java/io/legado/app/help/BookHelp.kt b/app/src/main/java/io/legado/app/help/BookHelp.kt index e3728eeab..ea636cb83 100644 --- a/app/src/main/java/io/legado/app/help/BookHelp.kt +++ b/app/src/main/java/io/legado/app/help/BookHelp.kt @@ -122,7 +122,7 @@ object BookHelp { cacheFolderName, book.getFolderName(), cacheImageFolderName, - "${MD5Utils.md5Encode16(src)}${getImageSuffix(src)}" + "${MD5Utils.md5Encode16(src)}.${getImageSuffix(src)}" ).writeBytes(it) } } catch (e: Exception) { @@ -137,14 +137,14 @@ object BookHelp { cacheFolderName, book.getFolderName(), cacheImageFolderName, - "${MD5Utils.md5Encode16(src)}${getImageSuffix(src)}" + "${MD5Utils.md5Encode16(src)}.${getImageSuffix(src)}" ) } fun getImageSuffix(src: String): String { var suffix = src.substringAfterLast(".").substringBefore(",") if (suffix.length > 5) { - suffix = ".jpg" + suffix = "jpg" } return suffix }