From 4bb110f3197c0d1575baa5d95863e7cdb552c548 Mon Sep 17 00:00:00 2001 From: Pascal Hartig Date: Tue, 11 Aug 2020 11:15:43 -0700 Subject: [PATCH] Handle off-Lighthouse version checks Summary: This is tanking our success rates, but is an expected behaviour. Reviewed By: jknoxville Differential Revision: D23001697 fbshipit-source-id: 48bcdb99543d590d544cce8322950568a0ef5c6f --- desktop/app/src/utils/publicVersionChecker.tsx | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/desktop/app/src/utils/publicVersionChecker.tsx b/desktop/app/src/utils/publicVersionChecker.tsx index 599bb739a..e84fbd495 100644 --- a/desktop/app/src/utils/publicVersionChecker.tsx +++ b/desktop/app/src/utils/publicVersionChecker.tsx @@ -70,6 +70,13 @@ export async function checkForUpdate( case 204: return {kind: 'up-to-date'}; case 200: + if (res.url.startsWith('https://www.facebook.com/login/')) { + // We're being redirected because we're not on an authenticated network. + // Treat that as being up-to-date as there's special-casing the UI for + // this is not worth it. + console.log('Skipping version check on non-authenticated network.'); + return {kind: 'up-to-date'}; + } return res.json().then(parseResponse); default: return {