Skip to content

Commit

Permalink
Fix a bug re: Path.join (#46)
Browse files Browse the repository at this point in the history
  • Loading branch information
chaosrealm authored Aug 14, 2024
1 parent f96da3f commit 785fcf5
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"url": "https://github.com/cortexclick/cortex-sdk",
"type": "git"
},
"version": "0.0.11",
"version": "0.0.12",
"type": "module",
"main": "./dist/index.js",
"types": "./dist/index.d.ts",
Expand Down
8 changes: 7 additions & 1 deletion src/api-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,13 @@ export class CortexApiClient {
throw new Error("Request body too large");
}

const url = Path.join(this.apiUrl, this.apiVersion, "org", this.org, path);
const url = Path.posix.join(
this.apiUrl,
this.apiVersion,
"org",
this.org,
path,
);
return fetch(url, {
method: "POST",
headers: {
Expand Down

0 comments on commit 785fcf5

Please sign in to comment.