mirror of https://github.com/vector-im/riot-web
Update for new unread count format
parent
67ff769962
commit
83634bf930
|
@ -641,8 +641,8 @@ module.exports = React.createClass({
|
||||||
for (var i = 0; i < rooms.length; ++i) {
|
for (var i = 0; i < rooms.length; ++i) {
|
||||||
if (rooms[i].hasMembershipState(MatrixClientPeg.get().credentials.userId, 'invite')) {
|
if (rooms[i].hasMembershipState(MatrixClientPeg.get().credentials.userId, 'invite')) {
|
||||||
++notifCount;
|
++notifCount;
|
||||||
} else if (rooms[i].unread_notification_count) {
|
} else if (rooms[i].unread_notifications && rooms[i].unread_notifications['notification_count']) {
|
||||||
notifCount += rooms[i].unread_notification_count;
|
notifCount += rooms[i].unread_notifications['notification_count'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
this.favicon.badge(notifCount);
|
this.favicon.badge(notifCount);
|
||||||
|
|
Loading…
Reference in New Issue