@ts-ghost/core-api
Advanced tools
Comparing version 5.0.6 to 5.0.7
@@ -1151,3 +1151,7 @@ 'use strict'; | ||
this._baseURL = void 0; | ||
this._baseURL = new URL(`/ghost/api/${config.endpoint}/`, config.url); | ||
let prefixPath = new URL(config.url).pathname; | ||
if (prefixPath.slice(-1) === "/") { | ||
prefixPath = prefixPath.slice(0, -1); | ||
} | ||
this._baseURL = new URL(`${prefixPath}/ghost/api/${config.endpoint}/`, config.url); | ||
} | ||
@@ -1154,0 +1158,0 @@ get baseURL() { |
@@ -1151,3 +1151,7 @@ 'use strict'; | ||
this._baseURL = void 0; | ||
this._baseURL = new URL(`/ghost/api/${config.endpoint}/`, config.url); | ||
let prefixPath = new URL(config.url).pathname; | ||
if (prefixPath.slice(-1) === "/") { | ||
prefixPath = prefixPath.slice(0, -1); | ||
} | ||
this._baseURL = new URL(`${prefixPath}/ghost/api/${config.endpoint}/`, config.url); | ||
} | ||
@@ -1154,0 +1158,0 @@ get baseURL() { |
@@ -19,3 +19,3 @@ { | ||
}, | ||
"version": "5.0.6", | ||
"version": "5.0.7", | ||
"main": "./dist/index.js", | ||
@@ -29,10 +29,10 @@ "module": "./dist/index.mjs", | ||
"@ts-ghost/tsconfig": "*", | ||
"@types/node": "^20.2.1", | ||
"@vitest/coverage-c8": "^0.31.1", | ||
"eslint": "^8.41.0", | ||
"@types/node": "^20.4.2", | ||
"@vitest/coverage-c8": "^0.32.4", | ||
"eslint": "^8.45.0", | ||
"tsup": "^6.7.0", | ||
"typescript": "5.0.4", | ||
"vite": "^4.3.8", | ||
"vite-tsconfig-paths": "^4.0.7", | ||
"vitest": "^0.31.1", | ||
"typescript": "5.1.3", | ||
"vite": "^4.4.4", | ||
"vite-tsconfig-paths": "^4.2.0", | ||
"vitest": "^0.32.4", | ||
"vitest-fetch-mock": "^0.2.2" | ||
@@ -39,0 +39,0 @@ }, |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
6782
443744