Replies: 2 comments
-
Follow the Github markdown guide and please format your code blocks properly. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Hi, Like said before you should format your code to be more readable please. Looking at mail code you can give an array to cc like this: |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi There,
I am trying to send a message using adonisjs mail, but need to add to message the .cc() recipients based on an array.
const users_cc = ['[email protected]', '[email protected]']
await Mail.send(
'emails.evento',
{
user: user[0].nome,
data: data,
},
(message) => {
message
.from('[email protected]')
.to(users)
.cc(users_cc)
.subject('Cadastro em evento')
}
)
How could I loop into users_cc adding message.cc(users_cc[0]), message.cc(users_cc[1]), and so on?
Many thanks,
Gines
Beta Was this translation helpful? Give feedback.
All reactions