From 36c864d873469f171bcc7254e9ee385ab8c4cf7f Mon Sep 17 00:00:00 2001 From: Jack Hamilton Date: Sat, 12 Oct 2024 15:13:53 -0500 Subject: [PATCH] Update app/src/main/java/eu/kanade/presentation/library/LibrarySettingsDialog.kt Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com> --- .../kanade/presentation/library/LibrarySettingsDialog.kt | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/app/src/main/java/eu/kanade/presentation/library/LibrarySettingsDialog.kt b/app/src/main/java/eu/kanade/presentation/library/LibrarySettingsDialog.kt index 3e263ef233..8410cfb40c 100644 --- a/app/src/main/java/eu/kanade/presentation/library/LibrarySettingsDialog.kt +++ b/app/src/main/java/eu/kanade/presentation/library/LibrarySettingsDialog.kt @@ -184,14 +184,10 @@ private fun ColumnScope.SortPage( MR.strings.action_sort_random to LibrarySort.Type.Random, ).plus(trackerSortOption).map { (titleRes, mode) -> if (mode == LibrarySort.Type.Random) { - val enabledIcon = if (sortingMode == LibrarySort.Type.Random) { - Icons.Default.Refresh - } else { - null - } BaseSortItem( label = stringResource(titleRes), - icon = enabledIcon, + icon = Icons.Default.Refresh + .takeIf { sortingMode == LibrarySort.Type.Random }, onClick = { screenModel.setSort(category, mode, LibrarySort.Direction.Ascending) },