Skip to content

Commit

Permalink
- memory leak preventing
Browse files Browse the repository at this point in the history
  • Loading branch information
matzuk committed Dec 1, 2015
1 parent b1c4f63 commit b65d233
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,9 @@ public void onDestroyView() {
pagingSubscription.unsubscribe();
}
// for memory leak prevention (RecycleView is not unsubscibed from adapter DataObserver)
recyclerView.setAdapter(null);
if (recyclerView != null) {
recyclerView.setAdapter(null);
}
super.onDestroyView();
}

Expand Down

0 comments on commit b65d233

Please sign in to comment.