Skip to content

Commit

Permalink
fix: contact form
Browse files Browse the repository at this point in the history
  • Loading branch information
baptadn committed Apr 28, 2024
1 parent 74d7fcb commit 62c200b
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 914 deletions.
12 changes: 12 additions & 0 deletions back/api/contact/config/routes.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"routes": [
{
"method": "POST",
"path": "/contacts",
"handler": "contact.create",
"config": {
"policies": []
}
}
]
}
4 changes: 2 additions & 2 deletions back/api/contact/controllers/contact.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ module.exports = {

await strapi.plugins["email"].services.email.sendTemplatedEmail(
{
to: "[email protected]",
from: entity.from,
from: process.env.EMAIL_SENDER,
to: process.env.EMAIL_SENDER,
},
template,
{
Expand Down
Loading

0 comments on commit 62c200b

Please sign in to comment.