diff options
author | 2020-04-13 15:46:42 +0100 | |
---|---|---|
committer | 2020-04-13 15:46:42 +0100 | |
commit | 2f926c9a2b5bb8f46809e88215859506e80c510e (patch) | |
tree | ce5df9426d380e494858ebb27dd9b3dd8cefa727 /uncompressed/nextdoor/webview.js | |
parent | Replaces tab indents with spaces (diff) | |
download | ferdium-recipes-2f926c9a2b5bb8f46809e88215859506e80c510e.tar.gz ferdium-recipes-2f926c9a2b5bb8f46809e88215859506e80c510e.tar.zst ferdium-recipes-2f926c9a2b5bb8f46809e88215859506e80c510e.zip |
Updates Nextdoor to 1.0.1: Fixes notification disappearing
Diffstat (limited to 'uncompressed/nextdoor/webview.js')
-rw-r--r-- | uncompressed/nextdoor/webview.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/uncompressed/nextdoor/webview.js b/uncompressed/nextdoor/webview.js index c17e99d..e20c6b5 100644 --- a/uncompressed/nextdoor/webview.js +++ b/uncompressed/nextdoor/webview.js | |||
@@ -2,7 +2,11 @@ | |||
2 | 2 | ||
3 | module.exports = Franz => { | 3 | module.exports = Franz => { |
4 | const getMessages = function getMessages() { | 4 | const getMessages = function getMessages() { |
5 | const unread = document.getElementsByClassName('notification-badge')[0].innerText; | 5 | var unread = 0 |
6 | const notificationBadge = document.getElementsByClassName('notification-badge')[0] | ||
7 | if (notificationBadge != undefined) { | ||
8 | unread = notificationBadge.innerText; | ||
9 | } | ||
6 | Franz.setBadge(parseInt(unread, 10)); | 10 | Franz.setBadge(parseInt(unread, 10)); |
7 | }; | 11 | }; |
8 | 12 | ||