diff options
author | 2020-05-25 15:37:51 +0530 | |
---|---|---|
committer | 2020-05-27 13:11:44 +0530 | |
commit | b3769f642d978ecb3305eb3c94d67100203d9539 (patch) | |
tree | 788192fd4a20ca227718fa6b4089103ded152835 /uncompressed/googlemeet/index.js | |
parent | Update Skype with screen sharing (#170) (diff) | |
download | ferdium-recipes-b3769f642d978ecb3305eb3c94d67100203d9539.tar.gz ferdium-recipes-b3769f642d978ecb3305eb3c94d67100203d9539.tar.zst ferdium-recipes-b3769f642d978ecb3305eb3c94d67100203d9539.zip |
fix: Google meet is unusable - Errors out when trying to connect to a audio/video call
- Strip off any Ferdi/Electron text from user-agent using modifyRequestHeaders hook
- Resize icon to 1024x1024px as npm package was complaining
- Bump version number to 1.0.3
Diffstat (limited to 'uncompressed/googlemeet/index.js')
-rw-r--r-- | uncompressed/googlemeet/index.js | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/uncompressed/googlemeet/index.js b/uncompressed/googlemeet/index.js index 4087aa3..df2b452 100644 --- a/uncompressed/googlemeet/index.js +++ b/uncompressed/googlemeet/index.js | |||
@@ -2,10 +2,16 @@ var os = require('os') | |||
2 | 2 | ||
3 | module.exports = Franz => | 3 | module.exports = Franz => |
4 | class Gmail extends Franz { | 4 | class Gmail extends Franz { |
5 | overrideUserAgent() { | 5 | modifyRequestHeaders() { |
6 | if (os.platform() == 'linux') | 6 | return [ |
7 | return "Mozilla/5.0 (X11; Linux x86_64; rv:72.0) Gecko/20100101 Firefox/72.0" | 7 | { |
8 | else | 8 | headers: { |
9 | return "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:72.0) Gecko/20100101 Firefox/72.0"; | 9 | 'user-agent': window.navigator.userAgent.replace(/(Ferdi|Electron)\/\S+ \([^)]+\)/g, '').trim(), |
10 | }, | ||
11 | requestFilters: { | ||
12 | urls: ['*://*/*'], | ||
13 | }, | ||
14 | }, | ||
15 | ]; | ||
10 | } | 16 | } |
11 | }; | 17 | }; |