diff options
Diffstat (limited to 'recipes/messenger')
-rw-r--r-- | recipes/messenger/package.json | 2 | ||||
-rw-r--r-- | recipes/messenger/webview.js | 11 |
2 files changed, 8 insertions, 5 deletions
diff --git a/recipes/messenger/package.json b/recipes/messenger/package.json index 49d6b3a..293bca1 100644 --- a/recipes/messenger/package.json +++ b/recipes/messenger/package.json | |||
@@ -1,7 +1,7 @@ | |||
1 | { | 1 | { |
2 | "id": "messenger", | 2 | "id": "messenger", |
3 | "name": "Messenger", | 3 | "name": "Messenger", |
4 | "version": "1.7.2", | 4 | "version": "1.7.3", |
5 | "license": "MIT", | 5 | "license": "MIT", |
6 | "config": { | 6 | "config": { |
7 | "serviceURL": "https://messenger.com", | 7 | "serviceURL": "https://messenger.com", |
diff --git a/recipes/messenger/webview.js b/recipes/messenger/webview.js index 27b57e8..3c8d2c0 100644 --- a/recipes/messenger/webview.js +++ b/recipes/messenger/webview.js | |||
@@ -1,7 +1,7 @@ | |||
1 | function hideInstallMessage() { | 1 | function hideInstallMessage() { |
2 | const installMessage = document.querySelector('.usczdcwk'); | 2 | const installMessage = document.querySelector('.usczdcwk'); |
3 | if (installMessage.style.display != 'none') { | 3 | if (installMessage) { |
4 | installMessage.style.display = 'none' | 4 | installMessage.style.display = installMessage.style.display != 'none' ? 'none': installMessage.style.display; |
5 | } | 5 | } |
6 | } | 6 | } |
7 | 7 | ||
@@ -27,9 +27,12 @@ module.exports = Ferdium => { | |||
27 | Ferdium.setBadge(count); | 27 | Ferdium.setBadge(count); |
28 | }; | 28 | }; |
29 | 29 | ||
30 | Ferdium.loop(getMessages); | 30 | const loopRoutine = () => { |
31 | getMessages() | ||
32 | hideInstallMessage() | ||
33 | }; | ||
31 | 34 | ||
32 | Ferdium.loop(hideInstallMessage); | 35 | Ferdium.loop(loopRoutine); |
33 | 36 | ||
34 | localStorage.setItem( | 37 | localStorage.setItem( |
35 | '_cs_desktopNotifsEnabled', | 38 | '_cs_desktopNotifsEnabled', |