Skip to content

Commit

Permalink
Update LatestFragment.java
Browse files Browse the repository at this point in the history
[ci skip]
  • Loading branch information
danimahardhika authored Oct 30, 2017
1 parent bb0c9d0 commit 4ac10b0
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -256,12 +256,13 @@ protected void onPostExecute(Boolean aBoolean) {
mProgress.setVisibility(View.GONE);
if (aBoolean) {
if (mPosition == (mWallpapers.size() - 1)) {
if (mSwipe.isRefreshing()) {
if (mAdapter != null) {
mAdapter.setWallpapers(mWallpapers);
} else {
mAdapter = new LatestAdapter(getActivity(), mWallpapers);
mRecyclerView.setAdapter(mAdapter);
return;
}

mAdapter = new LatestAdapter(getActivity(), mWallpapers);
mRecyclerView.setAdapter(mAdapter);
}
}
}
Expand Down

0 comments on commit 4ac10b0

Please sign in to comment.