diff options
author | 2021-09-19 00:41:52 +0200 | |
---|---|---|
committer | 2021-09-19 00:57:47 +0200 | |
commit | c5d2a889d4cb44f995d74051f83628b505383093 (patch) | |
tree | b1bab2b6d7f99ab00b0ca9860079f71472ac79ae /recipes/tweetdeck | |
parent | Fix images opening in browser instead of in Discord (#712) (diff) | |
download | ferdium-recipes-c5d2a889d4cb44f995d74051f83628b505383093.tar.gz ferdium-recipes-c5d2a889d4cb44f995d74051f83628b505383093.tar.zst ferdium-recipes-c5d2a889d4cb44f995d74051f83628b505383093.zip |
fix: privileged API access
Privileged browser APIs should be accessed from webview.js via the Ferdi
parameter to the exported function.
If any service is broken (e.g., screen sharing), then most likely we
have to fix recipe.js or screenshare.js
Diffstat (limited to 'recipes/tweetdeck')
-rw-r--r-- | recipes/tweetdeck/package.json | 2 | ||||
-rw-r--r-- | recipes/tweetdeck/webview.js | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/recipes/tweetdeck/package.json b/recipes/tweetdeck/package.json index a438716..5400bac 100644 --- a/recipes/tweetdeck/package.json +++ b/recipes/tweetdeck/package.json | |||
@@ -1,7 +1,7 @@ | |||
1 | { | 1 | { |
2 | "id": "tweetdeck", | 2 | "id": "tweetdeck", |
3 | "name": "Tweetdeck", | 3 | "name": "Tweetdeck", |
4 | "version": "1.2.0", | 4 | "version": "1.2.1", |
5 | "license": "MIT", | 5 | "license": "MIT", |
6 | "config": { | 6 | "config": { |
7 | "serviceURL": "https://tweetdeck.twitter.com/", | 7 | "serviceURL": "https://tweetdeck.twitter.com/", |
diff --git a/recipes/tweetdeck/webview.js b/recipes/tweetdeck/webview.js index b60415d..54b7997 100644 --- a/recipes/tweetdeck/webview.js +++ b/recipes/tweetdeck/webview.js | |||
@@ -1,9 +1,9 @@ | |||
1 | // Tweetdeck redirect fix | ||
2 | Ferdi.ipcRenderer.on('redirect-url', (event, url) => { | ||
3 | window.location.assign(url); | ||
4 | }); | ||
5 | |||
6 | module.exports = Ferdi => { | 1 | module.exports = Ferdi => { |
2 | // Tweetdeck redirect fix | ||
3 | Ferdi.ipcRenderer.on('redirect-url', (event, url) => { | ||
4 | window.location.assign(url); | ||
5 | }); | ||
6 | |||
7 | const getMessages = function getMessages() { | 7 | const getMessages = function getMessages() { |
8 | const elements = document.querySelectorAll('.msg-unread-count'); | 8 | const elements = document.querySelectorAll('.msg-unread-count'); |
9 | let count = 0; | 9 | let count = 0; |