Skip to content

Commit

Permalink
small fix
Browse files Browse the repository at this point in the history
  • Loading branch information
victordigio committed Nov 7, 2017
1 parent 1f6711d commit e420180
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -221,8 +221,9 @@ abstract class PresenterAdapter<T : Any>() : RecyclerView.Adapter<ViewHolder<T>>

fun removeItem(item: T){
if(this.data.contains(item)){
notifyItemRemoved(getPositionWithHeaders(this.data.indexOf(item)))
val pos = this.data.indexOf(item)
this.data.remove(item)
notifyItemRemoved(getPositionWithHeaders(pos))
}
}

Expand Down

0 comments on commit e420180

Please sign in to comment.