aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/whatsapp/index.js
diff options
context:
space:
mode:
authorLibravatar Vijay A <avijayr@protonmail.com>2021-07-31 15:28:23 +0530
committerLibravatar Vijay A <avijayr@protonmail.com>2021-07-31 15:28:23 +0530
commit97697e3d069972844b2912a93022f4a4904a40d6 (patch)
tree53faff30fbac9d72042f593dfe1c547809f4f121 /recipes/whatsapp/index.js
parentAllow any url in the custom-service to allow for sites like 'http://translate... (diff)
downloadferdium-recipes-97697e3d069972844b2912a93022f4a4904a40d6.tar.gz
ferdium-recipes-97697e3d069972844b2912a93022f4a4904a40d6.tar.zst
ferdium-recipes-97697e3d069972844b2912a93022f4a4904a40d6.zip
Fixed eslintrc as root for this folder; Reformatted all files.
Diffstat (limited to 'recipes/whatsapp/index.js')
-rw-r--r--recipes/whatsapp/index.js36
1 files changed, 17 insertions, 19 deletions
diff --git a/recipes/whatsapp/index.js b/recipes/whatsapp/index.js
index a0ff71f..96c95a3 100644
--- a/recipes/whatsapp/index.js
+++ b/recipes/whatsapp/index.js
@@ -1,20 +1,18 @@
1"use strict"; 1module.exports = (Franz) => class Messenger extends Franz {
2 overrideUserAgent() {
3 return window.navigator.userAgent.replace(/(Ferdi|Electron)\/\S+( \([^)]+\))?/g, '').trim();
4 }
2 5
3module.exports = (Franz) => 6 modifyRequestHeaders() {
4 class Messenger extends Franz { 7 return [
5 overrideUserAgent() { 8 {
6 return window.navigator.userAgent.replace(/(Ferdi|Electron)\/\S+( \([^)]+\))?/g, "").trim(); 9 headers: {
7 } 10 'user-agent': window.navigator.userAgent.replace(/(Ferdi|Electron)\/\S+( \([^)]+\))?/g, '').trim(),
8 modifyRequestHeaders() { 11 },
9 return [ 12 requestFilters: {
10 { 13 urls: ['*://*/*'],
11 headers: { 14 },
12 'user-agent': window.navigator.userAgent.replace(/(Ferdi|Electron)\/\S+( \([^)]+\))?/g, "").trim(), 15 },
13 }, 16 ];
14 requestFilters: { 17 }
15 urls: ['*://*/*'], 18};
16 }
17 }
18 ]
19 }
20 };