mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-05 02:39:33 +02:00
Feature/subject in contact form (#1926)
* #1915 Add a subject to contact form and add it to email sent * #1915 Add subject to contact form tests * #1915 Contact form test corrected && tslint correction
This commit is contained in:
parent
d1ea2a988d
commit
4e9fa5b7e9
10 changed files with 42 additions and 8 deletions
|
@ -402,7 +402,7 @@ class Emailer {
|
|||
return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload })
|
||||
}
|
||||
|
||||
addContactFormJob (fromEmail: string, fromName: string, body: string) {
|
||||
addContactFormJob (fromEmail: string, fromName: string, subject: string, body: string) {
|
||||
const text = 'Hello dear admin,\n\n' +
|
||||
fromName + ' sent you a message' +
|
||||
'\n\n---------------------------------------\n\n' +
|
||||
|
@ -415,7 +415,7 @@ class Emailer {
|
|||
fromDisplayName: fromEmail,
|
||||
replyTo: fromEmail,
|
||||
to: [ CONFIG.ADMIN.EMAIL ],
|
||||
subject: CONFIG.EMAIL.OBJECT.PREFIX + 'Contact form submitted',
|
||||
subject: CONFIG.EMAIL.OBJECT.PREFIX + subject,
|
||||
text
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue