Skip to content

Commit

Permalink
DEV2-3897 remove trailing slash for get_server_url commands
Browse files Browse the repository at this point in the history
  • Loading branch information
amircodota committed Oct 26, 2023
1 parent 80ec949 commit 8501e10
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/tabnineChatWidget/ChatApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -192,8 +192,16 @@ export function initChatApi(
await getChatCommunicatorAddress(request.kind)
);

let externalServerUrl = (
await vscode.env.asExternalUri(serverUri)
).toString();

if (externalServerUrl.endsWith("/")) {
externalServerUrl = externalServerUrl.slice(0, -1);
}

return {
serverUrl: (await vscode.env.asExternalUri(serverUri)).toString(),
serverUrl: externalServerUrl,
};
}
);
Expand Down

0 comments on commit 8501e10

Please sign in to comment.