From 3a825f4f25d782f55a4c5bad7729801e5f4bd612 Mon Sep 17 00:00:00 2001 From: Aria Moradi Date: Wed, 12 May 2021 10:39:21 +0430 Subject: [PATCH] fix manga thumbnail loading bug --- .../kotlin/ir/armor/tachidesk/impl/util/CachedImageResponse.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/src/main/kotlin/ir/armor/tachidesk/impl/util/CachedImageResponse.kt b/server/src/main/kotlin/ir/armor/tachidesk/impl/util/CachedImageResponse.kt index 9eaf5ad..32b4525 100644 --- a/server/src/main/kotlin/ir/armor/tachidesk/impl/util/CachedImageResponse.kt +++ b/server/src/main/kotlin/ir/armor/tachidesk/impl/util/CachedImageResponse.kt @@ -24,7 +24,7 @@ object CachedImageResponse { private fun findFileNameStartingWith(directoryPath: String, fileName: String): String? { File(directoryPath).listFiles().forEach { file -> - if (file.name.startsWith(fileName)) + if (file.name.startsWith("$fileName.")) return "$directoryPath/${file.name}" } return null