@sap-ux/backend-proxy-middleware 0.6.12 → 0.6.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/base/proxy.js +3 -4
- package/package.json +3 -3
package/dist/base/proxy.js
CHANGED
|
@@ -204,6 +204,7 @@ exports.initI18n = initI18n;
|
|
|
204
204
|
* @param backend reference to the backend configuration that the the function may enhance
|
|
205
205
|
*/
|
|
206
206
|
function enhanceConfigsForDestination(proxyOptions, backend) {
|
|
207
|
+
var _a;
|
|
207
208
|
return __awaiter(this, void 0, void 0, function* () {
|
|
208
209
|
proxyOptions.target = btp_utils_1.getDestinationUrlForAppStudio(backend.destination);
|
|
209
210
|
if (backend.destinationInstance) {
|
|
@@ -215,10 +216,8 @@ function enhanceConfigsForDestination(proxyOptions, backend) {
|
|
|
215
216
|
if (destination) {
|
|
216
217
|
// in case of a full url destination remove the path defined in the destination from the forwarded call
|
|
217
218
|
if (btp_utils_1.isFullUrlDestination(destination)) {
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
backend.pathReplace = backend.path.replace(destPath, '');
|
|
221
|
-
}
|
|
219
|
+
backend.path = new URL(destination.Host).pathname.replace(/\/$/, '');
|
|
220
|
+
backend.pathReplace = (_a = backend.pathReplace) !== null && _a !== void 0 ? _a : '/';
|
|
222
221
|
}
|
|
223
222
|
}
|
|
224
223
|
else {
|
package/package.json
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"bugs": {
|
|
10
10
|
"url": "https://github.com/SAP/open-ux-tools/issues?q=is%3Aopen+is%3Aissue+label%3Abug+label%3Abackend-proxy-middleware"
|
|
11
11
|
},
|
|
12
|
-
"version": "0.6.
|
|
12
|
+
"version": "0.6.13",
|
|
13
13
|
"license": "Apache-2.0",
|
|
14
14
|
"author": "@SAP/ux-tools-team",
|
|
15
15
|
"main": "dist/index.js",
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
"!dist/**/*.map"
|
|
22
22
|
],
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@sap-ux/axios-extension": "0.9.
|
|
25
|
-
"@sap-ux/btp-utils": "0.10.
|
|
24
|
+
"@sap-ux/axios-extension": "0.9.1",
|
|
25
|
+
"@sap-ux/btp-utils": "0.10.4",
|
|
26
26
|
"@sap-ux/logger": "0.2.2",
|
|
27
27
|
"@sap-ux/store": "0.3.2",
|
|
28
28
|
"chalk": "4.1.2",
|