Skip to content

Commit 21316e6

Browse files
mmahroussfda-odoo
authored andcommitted
[FIX] client: trim trailing spaces from paths
1 parent f808cfb commit 21316e6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

vscode/client/common/utils.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ export async function validateAddonPath(addonPath) {
7979
for (const folder of workspace.workspaceFolders) {
8080
const PATH_VAR_LOCAL = { ...global.PATH_VARIABLES };
8181
PATH_VAR_LOCAL["workspaceFolder"] = folder.uri.fsPath.replaceAll("\\", "/");
82-
let filledPath = path.resolve(await fillTemplate(addonPath, PATH_VAR_LOCAL)).replaceAll("\\", "/");
82+
let filledPath = path.resolve(await fillTemplate(addonPath, PATH_VAR_LOCAL)).replaceAll("\\", "/").trim();
8383
if (!filledPath) continue;
8484
do {
8585
if (isAddonPath(filledPath)) {
@@ -100,7 +100,7 @@ export async function evaluateOdooPath(odooPath) {
100100

101101
for (const folder of workspace.workspaceFolders) {
102102
global.PATH_VARIABLES["workspaceFolder"] = folder.uri.fsPath.replaceAll("\\", "/");
103-
let filledOdooPath = path.resolve(await fillTemplate(odooPath, global.PATH_VARIABLES)).replaceAll("\\", "/");
103+
let filledOdooPath = path.resolve(await fillTemplate(odooPath, global.PATH_VARIABLES)).replaceAll("\\", "/").trim();
104104
do {
105105
const version = await getOdooVersion(filledOdooPath);
106106
if (version) {

0 commit comments

Comments
 (0)