From 58085336a5399a066b04baf679445bb0e047cc5d Mon Sep 17 00:00:00 2001 From: AntsyLich <59261191+AntsyLich@users.noreply.github.com> Date: Mon, 22 Jan 2024 20:20:11 +0600 Subject: [PATCH] Lint --- .../tachiyomi/data/track/bangumi/BangumiInterceptor.kt | 6 ++++-- .../java/eu/kanade/tachiyomi/data/track/komga/KomgaApi.kt | 4 +++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/bangumi/BangumiInterceptor.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/bangumi/BangumiInterceptor.kt index c8a0d15fc..a1822cca0 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/bangumi/BangumiInterceptor.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/bangumi/BangumiInterceptor.kt @@ -4,7 +4,6 @@ import eu.kanade.tachiyomi.BuildConfig import kotlinx.serialization.json.Json import okhttp3.FormBody import okhttp3.Interceptor -import okhttp3.Request import okhttp3.Response import uy.kohesive.injekt.injectLazy @@ -32,7 +31,10 @@ class BangumiInterceptor(private val bangumi: Bangumi) : Interceptor { } return originalRequest.newBuilder() - .header("User-Agent", "antsylich/Mihon/v${BuildConfig.VERSION_NAME} (Android) (http://github.com/mihonapp/mihon)") + .header( + "User-Agent", + "antsylich/Mihon/v${BuildConfig.VERSION_NAME} (Android) (http://github.com/mihonapp/mihon)", + ) .apply { if (originalRequest.method == "GET") { val newUrl = originalRequest.url.newBuilder() diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/komga/KomgaApi.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/komga/KomgaApi.kt index 47c3d7b41..628c4eb53 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/komga/KomgaApi.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/komga/KomgaApi.kt @@ -51,7 +51,9 @@ class KomgaApi( } val progress = client - .newCall(GET("${url.replace("/api/v1/series/", "/api/v2/series/")}/read-progress/tachiyomi", headers)) + .newCall( + GET("${url.replace("/api/v1/series/", "/api/v2/series/")}/read-progress/tachiyomi", headers), + ) .awaitSuccess().let { with(json) { if (url.contains("/api/v1/series/")) {