Skip to content

Commit

Permalink
Merge pull request #42 from PermanentOrg/fix-prod-cors
Browse files Browse the repository at this point in the history
Allow www origin for production requests
  • Loading branch information
cecilia-donnelly authored Jun 14, 2023
2 parents 6000d66 + 8230f02 commit f64ff1b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const env = process.env["ENV"] ?? "";
const app = express();
app.use(
cors({
origin: `https://${env === "production" ? "" : `${env}.`}permanent.org`,
origin: `https://${env === "production" ? "www" : `${env}`}.permanent.org`,
})
);
app.use(expressWinston.logger({ level: "http", winstonInstance: logger }));
Expand Down

0 comments on commit f64ff1b

Please sign in to comment.