mirror of
https://github.com/mihonapp/mihon.git
synced 2025-11-15 13:37:29 +01:00
Fix IndexOutOfBoundsException when using Split tall images (#7892)
Also little cleanup
This commit is contained in:
@@ -32,7 +32,7 @@ class WebtoonAdapter(val viewer: WebtoonViewer) : RecyclerView.Adapter<RecyclerV
|
||||
|
||||
val placeAtIndex = items.indexOf(currentStrip) + 1
|
||||
// Stop constantly adding split images
|
||||
if (items[placeAtIndex] is StencilPage) return
|
||||
if (items.getOrNull(placeAtIndex) is StencilPage) return
|
||||
|
||||
val updatedItems = items.toMutableList()
|
||||
updatedItems.addAll(placeAtIndex, newStrips)
|
||||
|
||||
Reference in New Issue
Block a user