diff options
author | 2022-04-18 06:51:50 -0500 | |
---|---|---|
committer | 2022-04-18 06:51:50 -0500 | |
commit | 18801ed0c02627e87639dc0848cab44dacc18be2 (patch) | |
tree | 15e56ba66c68bf7b4594e6c9fdef44e037b4be31 /recipes/devRant/webview.js | |
parent | Remove deprecated webPreference flag (diff) | |
download | ferdium-recipes-18801ed0c02627e87639dc0848cab44dacc18be2.tar.gz ferdium-recipes-18801ed0c02627e87639dc0848cab44dacc18be2.tar.zst ferdium-recipes-18801ed0c02627e87639dc0848cab44dacc18be2.zip |
Rebranded from 'ferdi' to 'ferdium' (companion changes for the main repo PR #2)
Diffstat (limited to 'recipes/devRant/webview.js')
-rw-r--r-- | recipes/devRant/webview.js | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/recipes/devRant/webview.js b/recipes/devRant/webview.js index 7385db5..efe0d71 100644 --- a/recipes/devRant/webview.js +++ b/recipes/devRant/webview.js | |||
@@ -15,7 +15,7 @@ setTimeout(() => { | |||
15 | } | 15 | } |
16 | }, 1000); | 16 | }, 1000); |
17 | 17 | ||
18 | module.exports = (Ferdi, settings) => { | 18 | module.exports = (Ferdium, settings) => { |
19 | const getMessages = () => { | 19 | const getMessages = () => { |
20 | const elements = document.querySelectorAll('.CxUIE, .unread, ._0LqQ'); | 20 | const elements = document.querySelectorAll('.CxUIE, .unread, ._0LqQ'); |
21 | let count = 0; | 21 | let count = 0; |
@@ -28,11 +28,11 @@ module.exports = (Ferdi, settings) => { | |||
28 | } | 28 | } |
29 | } | 29 | } |
30 | 30 | ||
31 | Ferdi.setBadge(count); | 31 | Ferdium.setBadge(count); |
32 | }; | 32 | }; |
33 | 33 | ||
34 | window.addEventListener('beforeunload', async () => { | 34 | window.addEventListener('beforeunload', async () => { |
35 | Ferdi.clearStorageData(settings.id, { | 35 | Ferdium.clearStorageData(settings.id, { |
36 | storages: [ | 36 | storages: [ |
37 | 'appcache', | 37 | 'appcache', |
38 | 'serviceworkers', | 38 | 'serviceworkers', |
@@ -41,9 +41,9 @@ module.exports = (Ferdi, settings) => { | |||
41 | 'indexdb', | 41 | 'indexdb', |
42 | ], | 42 | ], |
43 | }); | 43 | }); |
44 | Ferdi.releaseServiceWorkers(); | 44 | Ferdium.releaseServiceWorkers(); |
45 | }); | 45 | }); |
46 | 46 | ||
47 | Ferdi.loop(getMessages); | 47 | Ferdium.loop(getMessages); |
48 | Ferdi.injectCSS(_path.default.join(__dirname, 'service.css')); | 48 | Ferdium.injectCSS(_path.default.join(__dirname, 'service.css')); |
49 | }; | 49 | }; |