blob: e20c6b58aec34f4bd39e944143acdf8c74e18fc6 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
"use strict";
module.exports = Franz => {
const getMessages = function getMessages() {
var unread = 0
const notificationBadge = document.getElementsByClassName('notification-badge')[0]
if (notificationBadge != undefined) {
unread = notificationBadge.innerText;
}
Franz.setBadge(parseInt(unread, 10));
};
Franz.loop(getMessages);
};
|