Skip to content

Commit

Permalink
test. createProxyMiddelware
Browse files Browse the repository at this point in the history
  • Loading branch information
eirikv committed Aug 8, 2024
1 parent 0bcc782 commit f702460
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions server/src/proxy/decorator-intern-proxy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,8 @@ const setup = (app: Express) => {
'/modiacontextholder/redirect',
async (req, _, next) => {
const accessToken = await requestOboToken(process.env.MODIACONTEXTHOLDER_API_SCOPE, req);
req.headers['authorization'] = undefined;
req.headers['Authorization'] = `Bearer ${accessToken}`;
req.headers['cookie'] = 'innlogget-part=VEILEDER; ' + req.headers['cookie'];
req.headers.authorization = `Bearer ${accessToken}`;
req.headers.cookie = 'innlogget-part=VEILEDER; ' + req.headers.cookie;
next();
},
createProxyMiddleware({
Expand Down

0 comments on commit f702460

Please sign in to comment.