diff options
Diffstat (limited to 'recipes/discord')
-rw-r--r-- | recipes/discord/package.json | 2 | ||||
-rw-r--r-- | recipes/discord/webview.js | 6 |
2 files changed, 3 insertions, 5 deletions
diff --git a/recipes/discord/package.json b/recipes/discord/package.json index 73a859c..c644d66 100644 --- a/recipes/discord/package.json +++ b/recipes/discord/package.json | |||
@@ -1,7 +1,7 @@ | |||
1 | { | 1 | { |
2 | "id": "discord", | 2 | "id": "discord", |
3 | "name": "Discord", | 3 | "name": "Discord", |
4 | "version": "1.4.0", | 4 | "version": "1.4.1", |
5 | "license": "MIT", | 5 | "license": "MIT", |
6 | "config": { | 6 | "config": { |
7 | "serviceURL": "https://discordapp.com/login", | 7 | "serviceURL": "https://discordapp.com/login", |
diff --git a/recipes/discord/webview.js b/recipes/discord/webview.js index 480329d..9c96f9f 100644 --- a/recipes/discord/webview.js +++ b/recipes/discord/webview.js | |||
@@ -93,10 +93,10 @@ module.exports = (Ferdi, settings) => { | |||
93 | 93 | ||
94 | if (link || button) { | 94 | if (link || button) { |
95 | const url = link ? link.getAttribute('href') : button.getAttribute('title'); | 95 | const url = link ? link.getAttribute('href') : button.getAttribute('title'); |
96 | event.preventDefault(); | ||
97 | event.stopPropagation(); | ||
98 | 96 | ||
99 | if (url.includes('views/imgpsh_fullsize_anim')) { | 97 | if (url.includes('views/imgpsh_fullsize_anim')) { |
98 | event.preventDefault(); | ||
99 | event.stopPropagation(); | ||
100 | let win = new Ferdi.BrowserWindow({ | 100 | let win = new Ferdi.BrowserWindow({ |
101 | width: 800, | 101 | width: 800, |
102 | height: window.innerHeight, | 102 | height: window.innerHeight, |
@@ -109,8 +109,6 @@ module.exports = (Ferdi, settings) => { | |||
109 | win.on('closed', () => { | 109 | win.on('closed', () => { |
110 | win = null; | 110 | win = null; |
111 | }); | 111 | }); |
112 | } else { | ||
113 | window.open(url); | ||
114 | } | 112 | } |
115 | } | 113 | } |
116 | }, true); | 114 | }, true); |