-
Notifications
You must be signed in to change notification settings - Fork 25
Description
Describe the bug
Everything else is working perfect. However, when I scroll faster on the recyclerview I get the following error:
java.lang.ArrayIndexOutOfBoundsException: length=5; index=5 at com.app.selfcial.Adapters.PostsAdapter$7.onComplete(PostsAdapter.java:592) at com.google.android.gms.tasks.zzi.run(com.google.android.gms:play-services-tasks@@18.0.1:1) at android.os.Handler.handleCallback(Handler.java:883) at android.os.Handler.dispatchMessage(Handler.java:100) at android.os.Looper.loop(Looper.java:223) at android.app.ActivityThread.main(ActivityThread.java:7562) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:539) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:950)
To Reproduce
Steps to reproduce the behavior:
- Click on a reaction
- Save it in Firebase with reaction id
- setCurrentReaction based on the saved id
- Scroll a bit bit faster the recyelerview
Expected behavior
It should work same as when scrolling slow
Smartphone (please complete the following information):
- Device: Xiaomi Redmi 8
- OS: Android 10