Compare commits

...

2 Commits

Author SHA1 Message Date
39f9505c00 Merge pull request 'fix: check index exists.' (#183) from fix-index into master
All checks were successful
Check master code / build (push) Successful in 8m3s
Reviewed-on: #183
2025-02-16 13:37:42 +00:00
6a6d447456 fix: check index exists.
All checks were successful
Check PR code / Lint (pull_request) Successful in 3m57s
Check PR code / build (pull_request) Successful in 13m44s
2025-02-16 13:57:42 +01:00
2 changed files with 10 additions and 6 deletions

4
.gitignore vendored
View File

@ -323,4 +323,6 @@ fabric.properties
crowdin.properties
.kotlin/
build-cache/
build-cache/
act

View File

@ -161,12 +161,14 @@ class ReaderActivity :
override fun onPageSelected(position: Int) {
super.onPageSelected(position)
if (allItems[position].starred) {
canRemoveFromFavorite()
} else {
canFavorite()
if (!allItems.isNullOrEmpty() && allItems.size >= position) {
if (allItems[position].starred) {
canRemoveFromFavorite()
} else {
canFavorite()
}
readItem(allItems[position])
}
readItem(allItems[position])
}
},
)