Skip to content

Commit

Permalink
Avoid adding empty Project queryparam
Browse files Browse the repository at this point in the history
  • Loading branch information
gjsjohnmurray committed Jul 18, 2024
1 parent a850ba2 commit 71d5632
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/commands/serverActions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,9 @@ export async function serverActions(): Promise<void> {
const token = await getCSPToken(api, addin.id);
let params = `Namespace=${nsEncoded}`;
params += `&User=${encodeURIComponent(username)}`;
params += `&Project=${encodeURIComponent(project)}`;
if (project !== "") {
params += `&Project=${encodeURIComponent(project)}`;
}
params += `&CSPCHD=${token}`;
vscode.env.openExternal(vscode.Uri.parse(`${serverUrl}${addin.id}?${params}`));
}
Expand Down

0 comments on commit 71d5632

Please sign in to comment.