blob: e09407dc531441939a0df91aee5f321a57005d62 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
module.exports = (Ferdi) => {
const getMessages = () => {
let directCount = 0;
const element = document.querySelector('.ws-navigation-button__indicator.ws-navigation-button-indicator');
if (element) {
directCount = Ferdi.safeParseInt(element.innerText);
}
Ferdi.setBadge(directCount);
}
Ferdi.loop(getMessages);
};
|