From acb60bf20d3db74e2689f95e23850ce170827969 Mon Sep 17 00:00:00 2001 From: Max Wipfli Date: Fri, 6 May 2022 00:29:39 +0200 Subject: fix: modify user agent string on Linux (#99) On Linux, the user agent includes 'X11; Ubuntu; Linux ${arch}'. This user agent string break the Google Calendar service because the server decides to serve to mobile site instead of the desktop site based on that string. On my non-Ubuntu Linux machine, the UA used is almost identical, except for the 'Ubuntu; ' part. Removing that part from the default UA we use fixes that particular error and seems no to break any other services. --- src/helpers/userAgent-helpers.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/helpers') diff --git a/src/helpers/userAgent-helpers.ts b/src/helpers/userAgent-helpers.ts index c1e8e02da..52568555c 100644 --- a/src/helpers/userAgent-helpers.ts +++ b/src/helpers/userAgent-helpers.ts @@ -28,7 +28,7 @@ function windows() { function linux() { const archString = is64Bit ? 'x86_64' : osArch; - return `X11; Ubuntu; Linux ${archString}`; + return `X11; Linux ${archString}`; } export default function userAgent() { -- cgit v1.2.3-54-g00ecf