aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/roundcube/webview.js
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/roundcube/webview.js')
-rw-r--r--recipes/roundcube/webview.js3
1 files changed, 1 insertions, 2 deletions
diff --git a/recipes/roundcube/webview.js b/recipes/roundcube/webview.js
index 8a2ffef..ce9872a 100644
--- a/recipes/roundcube/webview.js
+++ b/recipes/roundcube/webview.js
@@ -3,8 +3,7 @@ module.exports = Ferdi => {
3 const directElements = document.querySelectorAll('.unreadcount'); 3 const directElements = document.querySelectorAll('.unreadcount');
4 let direct = 0; 4 let direct = 0;
5 for (let i = 0; i < directElements.length; i += 1) { 5 for (let i = 0; i < directElements.length; i += 1) {
6 const n = parseInt(directElements[i].innerHTML); 6 direct += Ferdi.safeParseInt(directElements[i].innerHTML);
7 direct += isNaN(n) ? 0 : n;
8 } 7 }
9 Ferdi.setBadge(direct); 8 Ferdi.setBadge(direct);
10 }; 9 };