mirror of
https://codeberg.org/tom79/Fedilab.git
synced 2024-12-22 16:50:04 +02:00
Fix a crash
This commit is contained in:
parent
ce607226d9
commit
bbba486be1
1 changed files with 3 additions and 0 deletions
|
@ -225,6 +225,9 @@ public class NotificationAdapter extends RecyclerView.Adapter<RecyclerView.ViewH
|
||||||
@Override
|
@Override
|
||||||
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder viewHolder, int position) {
|
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder viewHolder, int position) {
|
||||||
Notification notification = notificationList.get(position);
|
Notification notification = notificationList.get(position);
|
||||||
|
if (notification == null || notification.account == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (getItemViewType(position) == TYPE_FOLLOW || getItemViewType(position) == TYPE_FOLLOW_REQUEST || getItemViewType(position) == TYPE_ADMIN_REPORT || getItemViewType(position) == TYPE_ADMIN_SIGNUP) {
|
if (getItemViewType(position) == TYPE_FOLLOW || getItemViewType(position) == TYPE_FOLLOW_REQUEST || getItemViewType(position) == TYPE_ADMIN_REPORT || getItemViewType(position) == TYPE_ADMIN_SIGNUP) {
|
||||||
ViewHolderFollow holderFollow = (ViewHolderFollow) viewHolder;
|
ViewHolderFollow holderFollow = (ViewHolderFollow) viewHolder;
|
||||||
SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(context);
|
SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(context);
|
||||||
|
|
Loading…
Reference in a new issue