@sap-ux/backend-proxy-middleware
Advanced tools
Comparing version 0.7.7 to 0.7.8
@@ -251,5 +251,4 @@ "use strict"; | ||
}); | ||
// sending a request to the backend to get cookies | ||
// sending a request to the backend to get token | ||
yield provider.getAtoInfo(); | ||
proxyOptions.headers['cookie'] = provider.cookies.toString(); | ||
} | ||
@@ -310,3 +309,3 @@ else { | ||
if (system) { | ||
yield enhanceConfigForSystem(proxyOptions, system, backend.scp, (refreshToken) => { | ||
yield enhanceConfigForSystem(proxyOptions, system, backend.scp, (refreshToken, accessToken) => { | ||
if (refreshToken) { | ||
@@ -316,2 +315,9 @@ logger.info('Updating refresh token for: ' + localBackend.url); | ||
} | ||
if (accessToken) { | ||
logger.info('Setting access token'); | ||
proxyOptions.headers['authorization'] = `bearer ${accessToken}`; | ||
} | ||
else { | ||
logger.warn('Setting of access token failed.'); | ||
} | ||
}); | ||
@@ -318,0 +324,0 @@ } |
@@ -12,3 +12,3 @@ { | ||
}, | ||
"version": "0.7.7", | ||
"version": "0.7.8", | ||
"license": "Apache-2.0", | ||
@@ -33,5 +33,5 @@ "author": "@SAP/ux-tools-team", | ||
"@sap-ux/axios-extension": "1.8.1", | ||
"@sap-ux/btp-utils": "0.12.1", | ||
"@sap-ux/logger": "0.4.0", | ||
"@sap-ux/store": "0.4.0" | ||
"@sap-ux/store": "0.4.0", | ||
"@sap-ux/btp-utils": "0.12.1" | ||
}, | ||
@@ -38,0 +38,0 @@ "devDependencies": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
57606
833