Skip to content
Snippets Groups Projects
Unverified Commit 65b6f777 authored by fynngodau's avatar fynngodau Committed by GitHub
Browse files

Fix typo in settings background state function (COMMUNITY) #2033

parent e2eb813b
No related branches found
No related tags found
No related merge requests found
......@@ -21,7 +21,7 @@ data class SettingsBackgroundState(
/**
* Formats the settings icon for background priority
*/
fun getBackgroindPriorityIcon(c: Context): Drawable? = c.getDrawable(
fun getBackgroundPriorityIcon(c: Context): Drawable? = c.getDrawable(
if (isEnabled) R.drawable.ic_settings_background_priority_enabled
else R.drawable.ic_settings_background_priority_disabled
)
......
......@@ -88,7 +88,7 @@
android:layout_height="wrap_content"
app:body="@{@string/settings_background_priority_body_description}"
app:color="@{backgroundState.getBackgroundPriorityIconColor(context)}"
app:icon="@{backgroundState.getBackgroindPriorityIcon(context)}"
app:icon="@{backgroundState.getBackgroundPriorityIcon(context)}"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/settings_notifications"
......
......@@ -44,11 +44,11 @@ class SettingsBackgroundStateTest : BaseTest() {
@Test
fun getBackgroindPriorityIcon() {
createInstance(isEnabled = true).apply {
getBackgroindPriorityIcon(context)
getBackgroundPriorityIcon(context)
verify { context.getDrawable(R.drawable.ic_settings_background_priority_enabled) }
}
createInstance(isEnabled = false).apply {
getBackgroindPriorityIcon(context)
getBackgroundPriorityIcon(context)
verify { context.getDrawable(R.drawable.ic_settings_background_priority_disabled) }
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment