Add process for when the createdAt is null.

main
kyori 6 years ago
parent 6325f159f4
commit 6c10b6dbe9
  1. 4
      app/src/main/java/com/keylesspalace/tusky/adapter/NotificationsAdapter.java
  2. 4
      app/src/main/java/com/keylesspalace/tusky/adapter/StatusBaseViewHolder.java

@ -388,8 +388,10 @@ public class NotificationsAdapter extends RecyclerView.Adapter {
sdf = new SimpleDateFormat("HH:mm:ss", Locale.getDefault());
}
time = sdf.format(createdAt);
timestampInfo.setText(time);
} else {
time = "??:??:??";
}
timestampInfo.setText(time);
} else {
// This is the visible timestampInfo.
String readout;

@ -142,8 +142,10 @@ abstract class StatusBaseViewHolder extends RecyclerView.ViewHolder {
sdf = new SimpleDateFormat("HH:mm:ss", Locale.getDefault());
}
time = sdf.format(createdAt);
timestampInfo.setText(time);
} else {
time = "??:??:??";
}
timestampInfo.setText(time);
} else {
// This is the visible timestampInfo.
String readout;

Loading…
Cancel
Save