diff --git a/app/src/main/java/me/ccrama/redditslide/Fragments/SubmissionsView.java b/app/src/main/java/me/ccrama/redditslide/Fragments/SubmissionsView.java index 2e629ed9e7..0534389e04 100644 --- a/app/src/main/java/me/ccrama/redditslide/Fragments/SubmissionsView.java +++ b/app/src/main/java/me/ccrama/redditslide/Fragments/SubmissionsView.java @@ -17,6 +17,7 @@ import android.view.View; import android.view.ViewGroup; +import java.util.Iterator; import java.util.concurrent.ExecutionException; import me.ccrama.redditslide.Activities.Submit; @@ -138,7 +139,15 @@ public void onClick(View v) { fab.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { - adapter.dataSet.posts.removeAll(adapter.seen); + int i = 0; + Iterator it = adapter.dataSet.posts.iterator(); + while (it.hasNext()) { + i++; + if (adapter.seen.contains(it.next())) { + it.remove(); + //adapter.notifyItemRemoved(i); + } + } adapter.notifyDataSetChanged(); } });