From 69b9db4e8e6d0c00c333c0991d6f7648b830f8ef Mon Sep 17 00:00:00 2001 From: Secozzi <49240133+Secozzi@users.noreply.github.com> Date: Tue, 2 Jul 2024 19:37:02 +0000 Subject: [PATCH] fix(tracking): Fix crashing for Jellyfin enhanced tracking (#1658) --- .../tachiyomi/data/track/jellyfin/JellyfinInterceptor.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/jellyfin/JellyfinInterceptor.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/jellyfin/JellyfinInterceptor.kt index a40fb89f9..a612fd800 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/jellyfin/JellyfinInterceptor.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/jellyfin/JellyfinInterceptor.kt @@ -2,6 +2,7 @@ package eu.kanade.tachiyomi.data.track.jellyfin import eu.kanade.tachiyomi.BuildConfig import eu.kanade.tachiyomi.animesource.ConfigurableAnimeSource +import eu.kanade.tachiyomi.animesource.sourcePreferences import okhttp3.Interceptor import okhttp3.Response import tachiyomi.domain.source.anime.service.AnimeSourceManager @@ -51,7 +52,7 @@ class JellyfinInterceptor : Interceptor { private fun getApiKey(userId: String): String? { for (i in 1..MAX_JELLYFIN_SOURCES) { val sourceId = getId(i) - val preferences = (sourceManager.get(sourceId) as ConfigurableAnimeSource).getSourcePreferences() + val preferences = (sourceManager.get(sourceId) as ConfigurableAnimeSource).sourcePreferences() val sourceUserId = preferences.getString("user_id", "") if (sourceUserId.isNullOrEmpty()) {