Fixed false assumption for newer Mastodon accounts.

This commit is contained in:
Snowyfox 2022-06-03 01:40:42 -04:00
parent fa9a5edab0
commit 2725d8dc5b
2 changed files with 10 additions and 2 deletions

Binary file not shown.

View File

@ -260,8 +260,7 @@ implements ActionListener {
public void
showNotifications(List<Notification> notifications)
{
assert notifications.size() == rows.size();
for (int o = 0; o < rows.size(); ++o)
for (int o = 0; o < notifications.size(); ++o)
{
Notification n = notifications.get(o);
NotificationComponent c = rows.get(o);
@ -278,6 +277,15 @@ implements ActionListener {
}
c.setText(n.postText);
}
for (int o = notifications.size(); o < rows.size(); ++o)
{
NotificationComponent c = rows.get(o);
c.setName("");
c.setType("");
c.setText("");
}
prev.setEnabled(true);
next.setEnabled(!notifications.isEmpty());
}
// - -%- -