Skip to content

Commit

Permalink
fix: add req.headers (#6921)
Browse files Browse the repository at this point in the history
Signed-off-by: Udit Takkar <udit.07814802719@cse.mait.ac.in>
  • Loading branch information
Udit-takkar authored Feb 7, 2023
1 parent bdb4a73 commit cfc3644
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/web/middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ const middleware: NextMiddleware = async (req) => {
}

if (url.pathname.startsWith("/auth/login")) {
const moreHeaders = new Headers();
const moreHeaders = new Headers(req.headers);
// Use this header to actually enforce CSP, otherwise it is running in Report Only mode on all pages.
moreHeaders.set("x-csp-enforce", "true");
return NextResponse.next({
Expand Down

0 comments on commit cfc3644

Please sign in to comment.