diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsController.kt index 85ad89b870..fd349362d2 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsController.kt @@ -185,7 +185,7 @@ class ExtensionDetailsController(bundle: Bundle? = null) : val prefs = mutableListOf() val block: (@DSL SwitchPreferenceCompat).() -> Unit = { - key = source.getPreferenceKey() + key = source.getPreferenceKey() + "_enabled" title = when { isMultiSource && !isMultiLangSingleSource -> source.toString() else -> LocaleHelper.getSourceDisplayName(source.lang, context) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceItem.kt index 3d344d41cd..e0f24f8117 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceItem.kt @@ -53,12 +53,17 @@ class SourceItem(val source: CatalogueSource, header: LangItem? = null, val isPi override fun equals(other: Any?): Boolean { if (other is SourceItem) { - return source.id == other.source.id && header?.code == other.header?.code + return source.id == other.source.id && + header?.code == other.header?.code && + isPinned == other.isPinned } return false } override fun hashCode(): Int { - return source.id.hashCode() + (header?.code?.hashCode() ?: 0).toInt() + var result = source.id.hashCode() + result = 31 * result + (header?.hashCode() ?: 0) + result = 31 * result + isPinned.hashCode() + return result } }