diff options
author | Bennett <hello@vantezzen.io> | 2020-02-13 13:34:25 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-13 13:34:25 +0100 |
commit | 83f946f546247572a787d451ca9ec6649c600849 (patch) | |
tree | 710e0a3d7761bffb72fc1f5275d4116bb70b3f5c /uncompressed/slack/webview.js | |
parent | Merge pull request #38 from Serubin/master (diff) | |
download | ferdium-recipes-83f946f546247572a787d451ca9ec6649c600849.tar.gz ferdium-recipes-83f946f546247572a787d451ca9ec6649c600849.tar.zst ferdium-recipes-83f946f546247572a787d451ca9ec6649c600849.zip |
Update slack: Fix incorrect notification count (#41)
* Update slack: Fix incorrect notification count
https://github.com/meetfranz/recipe-slack/pull/13
* Revert "Update slack: Fix incorrect notification count"
This reverts commit 54d8bad9420198abca55a41123cf110caa7aba02.
* Update slack: Fix incorrect notification count https://github.com/meetfranz/recipe-slack/pull/13
* Update slack plugin version
* Properly update slack plugin version
* Properly update slack version number
Co-authored-by: Solomon <github@serubin.net>
Diffstat (limited to 'uncompressed/slack/webview.js')
-rw-r--r-- | uncompressed/slack/webview.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/uncompressed/slack/webview.js b/uncompressed/slack/webview.js index 174d81c..e64ff4d 100644 --- a/uncompressed/slack/webview.js +++ b/uncompressed/slack/webview.js | |||
@@ -41,7 +41,7 @@ const SELECTOR_CHANNELS_UNREAD = '.p-channel_sidebar__channel--unread:not(.p-cha | |||
41 | 41 | ||
42 | module.exports = Franz => { | 42 | module.exports = Franz => { |
43 | const getMessages = () => { | 43 | const getMessages = () => { |
44 | const directMessages = document.querySelectorAll(`${SELECTOR_CHANNELS_UNREAD} .p-channel_sidebar__badge, .p-channel_sidebar__link--unread`).length; | 44 | const directMessages = document.querySelectorAll(`${SELECTOR_CHANNELS_UNREAD} .p-channel_sidebar__badge, .p-channel_sidebar__link--unread:not([data-sidebar-link-id="Punreads"]`).length; |
45 | const allMessages = document.querySelectorAll(SELECTOR_CHANNELS_UNREAD).length - directMessages; | 45 | const allMessages = document.querySelectorAll(SELECTOR_CHANNELS_UNREAD).length - directMessages; |
46 | Franz.setBadge(directMessages, allMessages); | 46 | Franz.setBadge(directMessages, allMessages); |
47 | }; | 47 | }; |