Fix notification count update

This commit is contained in:
Tor Hveem 2016-08-11 14:08:07 +02:00
parent 99d0081ee9
commit e903acfb0d
No known key found for this signature in database
GPG Key ID: 7C3ECF7851B7F195
1 changed files with 4 additions and 2 deletions

View File

@ -359,9 +359,11 @@ weechat.factory('handlers', ['$rootScope', '$log', 'models', 'plugins', 'notific
// 1 is message
buffer.unread = l.count[1];
// 2 is private
buffer.notification = l.count[2];
// Use += so count[2] or count[3] doesn't overwrite each other
buffer.notification += l.count[2];
// 3 is highlight
buffer.notification = l.count[3];
// Use += so count[2] or count[3] doesn't overwrite each other
buffer.notification += l.count[3];
/* Since there is unread messages, we can guess
* what the last read line is and update it accordingly
*/