Skip to content
Snippets Groups Projects
Commit e97ee736 authored by Geoffrey Métais's avatar Geoffrey Métais
Browse files

Set adapter only if needed

parent 353e48d6
No related branches found
No related tags found
No related merge requests found
......@@ -187,7 +187,8 @@ public abstract class BaseBrowserFragment extends SortableFragment<BaseBrowserAd
@Override
public void onActivityCreated(@Nullable Bundle savedInstanceState) {
super.onActivityCreated(savedInstanceState);
mAdapter = new BaseBrowserAdapter(this);
if (mAdapter == null)
mAdapter = new BaseBrowserAdapter(this);
mLayoutManager = new LinearLayoutManager(getActivity());
mRecyclerView.setLayoutManager(mLayoutManager);
mRecyclerView.setAdapter(mAdapter);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment