diff options
author | 2021-07-12 05:09:17 +0530 | |
---|---|---|
committer | 2021-07-12 05:09:17 +0530 | |
commit | bb4037a57bba79d04e873f2198d19a368d8f6b02 (patch) | |
tree | baad72b60084318267dcc6b19b9ca3d9e82d83fa /src/models/UserAgent.js | |
parent | Upgraded nodejs to '14.17.3' (diff) | |
download | ferdium-app-bb4037a57bba79d04e873f2198d19a368d8f6b02.tar.gz ferdium-app-bb4037a57bba79d04e873f2198d19a368d8f6b02.tar.zst ferdium-app-bb4037a57bba79d04e873f2198d19a368d8f6b02.zip |
Use 'useragent-generator' to generate the user-agent string rather than manually building it. (#1592)
Diffstat (limited to 'src/models/UserAgent.js')
-rw-r--r-- | src/models/UserAgent.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/models/UserAgent.js b/src/models/UserAgent.js index f1d08e306..6f91d4ed0 100644 --- a/src/models/UserAgent.js +++ b/src/models/UserAgent.js | |||
@@ -5,7 +5,7 @@ import { | |||
5 | observable, | 5 | observable, |
6 | } from 'mobx'; | 6 | } from 'mobx'; |
7 | 7 | ||
8 | import defaultUserAgent, { isChromeless } from '../helpers/userAgent-helpers'; | 8 | import defaultUserAgent from '../helpers/userAgent-helpers'; |
9 | 9 | ||
10 | const debug = require('debug')('Ferdi:UserAgent'); | 10 | const debug = require('debug')('Ferdi:UserAgent'); |
11 | 11 | ||
@@ -76,7 +76,7 @@ export default class UserAgent { | |||
76 | } | 76 | } |
77 | 77 | ||
78 | @action _handleNavigate(url, forwardingHack = false) { | 78 | @action _handleNavigate(url, forwardingHack = false) { |
79 | if (isChromeless(url)) { | 79 | if (url.startsWith('https://accounts.google.com')) { |
80 | if (!this.chromelessUserAgent) { | 80 | if (!this.chromelessUserAgent) { |
81 | debug('Setting user agent to chromeless for url', url); | 81 | debug('Setting user agent to chromeless for url', url); |
82 | this.chromelessUserAgent = true; | 82 | this.chromelessUserAgent = true; |