From d4a2db8e16baf9dd4ff37b86b8936108d0e6e63c Mon Sep 17 00:00:00 2001 From: Shulammite-Aso Date: Sat, 19 Feb 2022 03:10:52 +0000 Subject: [PATCH] change hostname and remove http block --- components/dashboard/src/settings/Integrations.tsx | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/components/dashboard/src/settings/Integrations.tsx b/components/dashboard/src/settings/Integrations.tsx index 92adb1b108..0cb9a06b50 100644 --- a/components/dashboard/src/settings/Integrations.tsx +++ b/components/dashboard/src/settings/Integrations.tsx @@ -558,16 +558,14 @@ export function GitIntegrationModal(props: ({ const updateHostValue = (host: string) => { if (mode === "new") { - let verifiedHost = host; + let newHostValue = host; if (host.startsWith("https://")) { - verifiedHost = host.replace("https://",""); - } else if (host.startsWith("http://")) { - verifiedHost = host.replace("http://",""); + newHostValue = host.replace("https://",""); } - setHost(verifiedHost); - setRedirectURL(callbackUrl(verifiedHost)); + setHost(newHostValue); + setRedirectURL(callbackUrl(newHostValue)); setErrorMessage(undefined); } }