mirror of
				https://github.com/mihonapp/mihon.git
				synced 2025-10-31 14:27:57 +01:00 
			
		
		
		
	bump version, changelog, hide merged sources
This commit is contained in:
		| @@ -152,7 +152,7 @@ class EHentai(override val id: Long, | ||||
|                         throttleFunc() | ||||
|  | ||||
|                         val resp = client.newCall(exGet(baseUrl + url)).execute() | ||||
|                         if (!resp.isSuccessful) error("HTTP error (${resp.code})!") | ||||
|                         if (!resp.isSuccessful) break //error("HTTP error (${resp.code})!") | ||||
|                         doc = resp.asJsoup() | ||||
|  | ||||
|                         val parentLink = doc!!.select("#gdd .gdt1").find { el -> | ||||
|   | ||||
| @@ -336,7 +336,7 @@ class Hitomi : HttpSource(), LewdSource<HitomiSearchMetadata, Document>, UrlImpo | ||||
|     } | ||||
|  | ||||
|     override fun pageListRequest(chapter: SChapter): Request { | ||||
|         return GET("$LTN_BASE_URL/manga/${HitomiSearchMetadata.hlIdFromUrl(chapter.url)}.js") | ||||
|         return GET("$LTN_BASE_URL/galleries/${HitomiSearchMetadata.hlIdFromUrl(chapter.url)}.js") | ||||
|     } | ||||
|  | ||||
|     /** | ||||
| @@ -362,11 +362,14 @@ class Hitomi : HttpSource(), LewdSource<HitomiSearchMetadata, Document>, UrlImpo | ||||
|         val hlId = response.request.url.pathSegments.last().removeSuffix(".js").toLong() | ||||
|         val str = response.body!!.string() | ||||
|         val json = jsonParser.parse(str.removePrefix("var galleryinfo =")) | ||||
|         return json.array.mapIndexed { index, jsonElement -> | ||||
|         return json.array.mapIndexed { index, jsonElement ->  | ||||
|             val hash = jsonElement["hash"].string | ||||
|             val hashPath1 = hash.takeLast(1) | ||||
|             val hashPath2 = hash.takeLast(3).take(2) | ||||
|             Page( | ||||
|                     index, | ||||
|                     "", | ||||
|             "https://${subdomainFromGalleryId(hlId)}a.hitomi.la/manga/$hlId/${jsonElement["name"].string}" | ||||
|             "https://${subdomainFromGalleryId(hlId)}a.hitomi.la/webp/$hashPath1/$hashPath2/$hash.webp" | ||||
|             ) | ||||
|         } | ||||
|     } | ||||
|   | ||||
| @@ -93,9 +93,9 @@ class HitomiSearchMetadata: RaisedSearchMetadata() { | ||||
|         const val BASE_URL = "https://hitomi.la" | ||||
|  | ||||
|         fun hlIdFromUrl(url: String) | ||||
|                 = url.split('/').last().substringBeforeLast('.') | ||||
|                 = url.split('/').last().split('-').last().substringBeforeLast('.') | ||||
|  | ||||
|         fun urlFromHlId(id: String) | ||||
|                 = "$BASE_URL/galleries/$id.html" | ||||
|     } | ||||
| } | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user