Skip to content

Commit

Permalink
fix npe
Browse files Browse the repository at this point in the history
  • Loading branch information
imndx committed Dec 22, 2024
1 parent 736cc04 commit 237040b
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,9 @@ public void onChanged(Object o) {
}

public void scrollToNextUnreadConversation() {
if(layoutManager == null || adapter == null){
return;
}
int start = layoutManager.findFirstVisibleItemPosition();
int nextUnreadConversationPosition = adapter.getNextUnreadConversationPosition(start);
// 支持循环滚动,后面没有未读会话时,从头开始找
Expand Down

0 comments on commit 237040b

Please sign in to comment.