Skip to content

Commit

Permalink
[LogViewer] Prevent an NPE thrown when device configuration changes
Browse files Browse the repository at this point in the history
Signed-off-by: Muntashir Al-Islam <[email protected]>
  • Loading branch information
MuntashirAkon committed Mar 18, 2024
1 parent a46e62e commit a94bb14
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,9 @@ public void onAttach(@NonNull Context context) {
@CallSuper
@Override
public void onDestroy() {
mRecyclerView.removeOnScrollListener(mRecyclerViewScrollListener);
if (mRecyclerView != null) {
mRecyclerView.removeOnScrollListener(mRecyclerViewScrollListener);
}
super.onDestroy();
}

Expand Down

0 comments on commit a94bb14

Please sign in to comment.