Skip to content

Commit

Permalink
Merge pull request #4 from icefoganalytics/main
Browse files Browse the repository at this point in the history
Fixes
  • Loading branch information
datajohnson authored Dec 18, 2024
2 parents 9c5a612 + 16f9d4a commit 20fc275
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/api/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ app.use(express.urlencoded({ extended: true })); // for parsing application/x-ww
app.use(
helmet.contentSecurityPolicy({
directives: {
"default-src": ["'self'", `${AUTH0_DOMAIN}`],
"default-src": ["'self'", `${AUTH0_DOMAIN.replace(/\/$/, "")}`],
"base-uri": ["'self'"],
"block-all-mixed-content": [],
"font-src": ["'self'", "https:", "data:"],
Expand All @@ -23,7 +23,7 @@ app.use(
"script-src-attr": ["'none'"],
"style-src": ["'self'", "https:", "'unsafe-inline'"],
"worker-src": ["'self'", "blob:"],
"connect-src": ["'self'", `${AUTH0_DOMAIN}`],
"connect-src": ["'self'", `${AUTH0_DOMAIN.replace(/\/$/, "")}`],
},
})
);
Expand Down
4 changes: 4 additions & 0 deletions src/api/src/services/email-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,10 @@ export class EmailService {
/``RESULTS_URL``/,
`<a href="${FRONTEND_URL}/results/${questionToken}">${FRONTEND_URL}/results/${questionToken}</a>`
);
body = body.replace(
/``RATING_URL``/,
`<a href="${FRONTEND_URL}/rating/${token}">${FRONTEND_URL}/rating/${token}</a>`
);

await this.sendEmail(recipient.fullName, recipient.email, subject, body);
}
Expand Down

0 comments on commit 20fc275

Please sign in to comment.