From 7d9cd35c7c1ca1c6168d0afaa66164e9e2c23556 Mon Sep 17 00:00:00 2001 From: Moez Bhatti Date: Sun, 12 Jan 2020 01:21:10 -0500 Subject: [PATCH] Use correct default val for theme observable --- .../src/main/java/com/moez/QKSMS/common/util/Colors.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/presentation/src/main/java/com/moez/QKSMS/common/util/Colors.kt b/presentation/src/main/java/com/moez/QKSMS/common/util/Colors.kt index ed74dace..aee7f9be 100644 --- a/presentation/src/main/java/com/moez/QKSMS/common/util/Colors.kt +++ b/presentation/src/main/java/com/moez/QKSMS/common/util/Colors.kt @@ -89,7 +89,8 @@ class Colors @Inject constructor( fun themeObservable(recipient: Recipient? = null): Observable { val pref = when { - recipient == null || !prefs.autoColor.get() -> prefs.theme() + recipient == null -> prefs.theme() + prefs.autoColor.get() -> prefs.theme(recipient.id, prefs.theme().get()) else -> prefs.theme(recipient.id, generateColor(recipient)) } return pref.asObservable()