Fix crash after removing last category while it's active in library (#1450)

(cherry picked from commit 9df21583dc1da6da4041709a6d059848c6c9bda0)

# Conflicts:
#	app/src/main/java/eu/kanade/presentation/library/components/LibraryTabs.kt
This commit is contained in:
Cuong-Tran 2024-11-07 21:20:27 +07:00 committed by Jobobby04
parent be30814d35
commit 66929e097c

View File

@ -21,9 +21,7 @@ internal fun LibraryTabs(
getNumberOfMangaForCategory: (Category) -> Int?,
onTabItemClick: (Int) -> Unit,
) {
// SY -->
val currentPageIndex = pagerState.currentPage.coerceAtMost(categories.lastIndex)
// SY <--
Column(
modifier = Modifier.zIndex(1f),
) {