Skip to content

Commit 2f1a63e

Browse files
committed
Confilict resolved
2 parents 9d0898b + 8204a15 commit 2f1a63e

File tree

3 files changed

+5563
-2
lines changed

3 files changed

+5563
-2
lines changed

README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
# Pupil
22

33
![Banner](https://github.com/tom5079/Pupil/blob/gh-pages/assets/images/pupil-banner.png?raw=true)
4-
*Pupil, Hitomi.la viewer for Android*
4+
*Pupil, Hitomi.la viewer for Android*
5+
6+
[![](https://discordapp.com/api/guilds/610452916612104194/embed.png?style=banner2)](https://discord.gg/Stj4b5v)
7+
I can speak English, Japanese and Korean. If you have any questions, head over to my discord server or DM me!
58

69
# Screenshot
710
![Main Screen](https://github.com/tom5079/Pupil/blob/gh-pages/assets/images/main-screenshot.png?raw=true)

app/src/main/java/xyz/quaver/pupil/util/download/Cache.kt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ import kotlinx.io.InputStream
3131
import xyz.quaver.Code
3232
import xyz.quaver.hitomi.GalleryBlock
3333
import xyz.quaver.hitomi.Reader
34+
import xyz.quaver.proxy
3435
import xyz.quaver.pupil.util.getCachedGallery
3536
import xyz.quaver.pupil.util.getDownloadDirectory
3637
import xyz.quaver.pupil.util.json
@@ -80,7 +81,9 @@ class Cache(context: Context) : ContextWrapper(context) {
8081
withContext(Dispatchers.IO) {
8182
val thumbnails = getGalleryBlock(galleryID)?.thumbnails
8283
try {
83-
Base64.encodeToString(URL(thumbnails?.firstOrNull()).readBytes(), Base64.DEFAULT)
84+
Base64.encodeToString(URL(thumbnails?.firstOrNull()).openConnection(proxy).getInputStream().use {
85+
it.readBytes()
86+
}, Base64.DEFAULT)
8487
} catch (e: Exception) {
8588
null
8689
}

0 commit comments

Comments
 (0)