From 3c1b1515ad58700e1dbdbfc93b899a88883c52a0 Mon Sep 17 00:00:00 2001 From: Huiwen Date: Mon, 16 Oct 2023 14:04:54 +0000 Subject: [PATCH] Fix incorrect start workspace url --- components/gitpod-protocol/src/util/gitpod-host-url.ts | 2 +- components/supervisor/frontend/src/shared/urls.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/components/gitpod-protocol/src/util/gitpod-host-url.ts b/components/gitpod-protocol/src/util/gitpod-host-url.ts index d2d9a496f662af..84b0bed03e217a 100644 --- a/components/gitpod-protocol/src/util/gitpod-host-url.ts +++ b/components/gitpod-protocol/src/util/gitpod-host-url.ts @@ -120,7 +120,7 @@ export class GitpodHostUrl { } asStart(workspaceId = this.workspaceId): GitpodHostUrl { - return this.withoutWorkspacePrefix().with({ + return this.with({ pathname: "/start/", hash: "#" + workspaceId, }); diff --git a/components/supervisor/frontend/src/shared/urls.ts b/components/supervisor/frontend/src/shared/urls.ts index 07d9ff8f10043c..6096e4c51dfa8e 100644 --- a/components/supervisor/frontend/src/shared/urls.ts +++ b/components/supervisor/frontend/src/shared/urls.ts @@ -10,4 +10,4 @@ export const workspaceUrl = new GitpodHostUrl(window.location.href); export const serverUrl = workspaceUrl.withoutWorkspacePrefix(); -export const startUrl = workspaceUrl.asStart(); +export const startUrl = serverUrl.asStart(workspaceUrl.workspaceId);