Bug fix
This commit is contained in:
@@ -200,6 +200,8 @@ class Cache private constructor(context: Context, val galleryID: Int) : ContextW
|
||||
|
||||
if (!file.exists())
|
||||
file.createNewFile()
|
||||
|
||||
file.writeBytes(data)
|
||||
setMetadata { metadata -> metadata.imageList!![index] = fileName }
|
||||
}
|
||||
|
||||
|
||||
@@ -100,13 +100,11 @@ fun GalleryBlock.formatDownloadFolderTest(format: String): String =
|
||||
|
||||
suspend fun GalleryInfo.getRequestBuilders(): List<Request.Builder> {
|
||||
val galleryID = this.id.toIntOrNull() ?: 0
|
||||
val lowQuality = Preferences["low_quality", true]
|
||||
|
||||
return this.files.map {
|
||||
Request.Builder()
|
||||
.url(
|
||||
runCatching {
|
||||
imageUrlFromImage(galleryID, it, !lowQuality)
|
||||
imageUrlFromImage(galleryID, it, false)
|
||||
}
|
||||
.onFailure {
|
||||
FirebaseCrashlytics.getInstance().recordException(it)
|
||||
|
||||
@@ -56,12 +56,6 @@
|
||||
app:key="nomedia"
|
||||
app:title="@string/settings_nomedia_title"/>
|
||||
|
||||
<SwitchPreferenceCompat
|
||||
app:key="low_quality"
|
||||
app:title="@string/settings_low_quality"
|
||||
app:summary="@string/settings_low_quality_summary"
|
||||
app:defaultValue="true"/>
|
||||
|
||||
</PreferenceCategory>
|
||||
|
||||
<PreferenceCategory
|
||||
|
||||
Reference in New Issue
Block a user