diff --git a/ui/v2/src/core/StashService.ts b/ui/v2/src/core/StashService.ts index 2595d62cc..d7c2796e0 100644 --- a/ui/v2/src/core/StashService.ts +++ b/ui/v2/src/core/StashService.ts @@ -23,9 +23,12 @@ export class StashService { if (process.env.REACT_APP_HTTPS === "true") { platformUrl.protocol = "https:"; - wsPlatformUrl.protocol = "wss:"; } } + + if (platformUrl.protocol === "https:") { + wsPlatformUrl.protocol = "wss:"; + } const url = platformUrl.toString().slice(0, -1) + "/graphql"; const wsUrl = wsPlatformUrl.toString().slice(0, -1) + "/graphql";