diff options
author | 2020-09-19 19:35:36 +0200 | |
---|---|---|
committer | 2020-09-19 18:35:36 +0100 | |
commit | df53953c342c3bab7e36e752c7b2d38dd17bba1d (patch) | |
tree | c42ebae9a736176aacf384dcca715201b995c3f1 /uncompressed/slack | |
parent | Add Nextcloud Carnet recipe (#263) (diff) | |
download | ferdium-recipes-df53953c342c3bab7e36e752c7b2d38dd17bba1d.tar.gz ferdium-recipes-df53953c342c3bab7e36e752c7b2d38dd17bba1d.tar.zst ferdium-recipes-df53953c342c3bab7e36e752c7b2d38dd17bba1d.zip |
Fix wrong notifications count for Slack (#271)
Diffstat (limited to 'uncompressed/slack')
-rw-r--r-- | uncompressed/slack/package.json | 2 | ||||
-rw-r--r-- | uncompressed/slack/webview.js | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/uncompressed/slack/package.json b/uncompressed/slack/package.json index 987ce6a..8463e88 100644 --- a/uncompressed/slack/package.json +++ b/uncompressed/slack/package.json | |||
@@ -1,7 +1,7 @@ | |||
1 | { | 1 | { |
2 | "id": "slack", | 2 | "id": "slack", |
3 | "name": "Slack", | 3 | "name": "Slack", |
4 | "version": "1.0.15", | 4 | "version": "1.0.16", |
5 | "description": "Slack", | 5 | "description": "Slack", |
6 | "main": "index.js", | 6 | "main": "index.js", |
7 | "author": "Stefan Malzner <stefan@adlk.io>", | 7 | "author": "Stefan Malzner <stefan@adlk.io>", |
diff --git a/uncompressed/slack/webview.js b/uncompressed/slack/webview.js index 2b54c71..f7bccfc 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:not([data-sidebar-link-id="Punreads"]):not([data-sidebar-link-id="Pdrafts"])`).length; | 44 | const directMessages = document.querySelectorAll(`${SELECTOR_CHANNELS_UNREAD} .p-channel_sidebar__badge, .p-channel_sidebar__link--unread:not([data-sidebar-link-id="Punreads"]):not([data-sidebar-link-id="Pdrafts"]):not([data-sidebar-link-id="Pdms"])`).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 | }; |