🛠️ Fix crash in Reader

* Fixed crash caused by chapter progress calculation

Resolves: #90
This commit is contained in:
Acclorite 2024-09-28 16:22:53 +03:00
parent 4e5b5bcb26
commit e66a514827

View file

@ -638,7 +638,7 @@ class ReaderViewModel @Inject constructor(
val currentIndex = index - startIndex val currentIndex = index - startIndex
val endIndex = endIndex - startIndex val endIndex = endIndex - startIndex
currentIndex / endIndex.toFloat() (currentIndex / endIndex.toFloat()).coerceIn(0f, 1f)
} }
_state.update { _state.update {