From 62f0d4fa2ef809bdf7ea86551bfbc7e52a38b4df Mon Sep 17 00:00:00 2001 From: wedge1001 Date: Thu, 2 Jul 2020 21:40:49 +0200 Subject: [PATCH] fixed referer-check --- src/main/kotlin/mdnet/base/server/ImageServer.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/kotlin/mdnet/base/server/ImageServer.kt b/src/main/kotlin/mdnet/base/server/ImageServer.kt index 1240a50..7382fd2 100644 --- a/src/main/kotlin/mdnet/base/server/ImageServer.kt +++ b/src/main/kotlin/mdnet/base/server/ImageServer.kt @@ -106,7 +106,7 @@ class ImageServer(private val cache: DiskLruCache, private val statistics: Atomi } handled.set(true) - if (request.header("Referer")?.startsWith("https://mangadex.org") == true) { + if (request.header("Referer")?.startsWith("https://mangadex.org") == false) { snapshot?.close() Response(Status.FORBIDDEN) } else if (snapshot != null && imageDatum != null) {