fix: 【光环助手V5.13.0】评论 新增 IP属地展示(0822测试3,4) https://git.shanqu.cc/pm/halo/halo-app-issues/-/issues/2008

This commit is contained in:
张玉久
2022-08-22 16:44:46 +08:00
parent 15565281a9
commit 4fef613390
3 changed files with 28 additions and 21 deletions

View File

@ -131,20 +131,28 @@ public class MessageDetailAdapter extends BaseRecyclerAdapter<ViewHolder> {
mHotCommentList.addAll(response);
notifyDataSetChanged();
}
addNormalComment(); // 考虑到断网刷新问题
addNormalComment(true); // 考虑到断网刷新问题
}
@Override
public void onFailure(HttpException e) {
addNormalComment();
addNormalComment(true);
}
});
}
public void addNormalComment() {
addNormalComment(false);
}
public void addNormalComment(boolean isRefresh) {
if (isLoading) {
return;
}
if (isRefresh){
mNormalCommentList.clear();
mPage = 1;
}
isLoading = true;
RetrofitManager.getInstance().getApi().getComment(mConcernEntity.getId(), 10, mPage, Utils.getTime(mContext))
.subscribeOn(Schedulers.io())