From 4efc1955484089934768eceb41263f24e08ba22b Mon Sep 17 00:00:00 2001 From: arkon Date: Sat, 1 Aug 2020 18:23:46 -0400 Subject: [PATCH] Fix last used source pinned status --- .../eu/kanade/tachiyomi/ui/browse/source/SourcePresenter.kt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/SourcePresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/SourcePresenter.kt index cbfc1b5b9c..c39c14254c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/SourcePresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/SourcePresenter.kt @@ -103,7 +103,10 @@ class SourcePresenter( } private fun updateLastUsedSource(sourceId: Long) { - val source = (sourceManager.get(sourceId) as? CatalogueSource)?.let { SourceItem(it) } + val source = (sourceManager.get(sourceId) as? CatalogueSource)?.let { + val isPinned = it.id.toString() in preferences.pinnedSources().get() + SourceItem(it, null, isPinned) + } source?.let { view?.setLastUsedSource(it) } }