diff options
author | Nassim Bounouas <NassimBounouas@users.noreply.github.com> | 2019-06-21 08:49:35 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2019-06-21 08:49:35 +0200 |
commit | 4e9fa5b7e9ca6030a5fe2e9b0520bf8fa18e5877 (patch) | |
tree | f7fb09aa655f954b8d9833cd2215f6fada5721a6 /server/lib | |
parent | d1ea2a988d05e1eca4066efb99c5f943f5267a78 (diff) | |
download | PeerTube-4e9fa5b7e9ca6030a5fe2e9b0520bf8fa18e5877.tar.gz PeerTube-4e9fa5b7e9ca6030a5fe2e9b0520bf8fa18e5877.tar.zst PeerTube-4e9fa5b7e9ca6030a5fe2e9b0520bf8fa18e5877.zip |
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
Diffstat (limited to 'server/lib')
-rw-r--r-- | server/lib/emailer.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/lib/emailer.ts b/server/lib/emailer.ts index c4a5a5853..73c2bcb1b 100644 --- a/server/lib/emailer.ts +++ b/server/lib/emailer.ts | |||
@@ -402,7 +402,7 @@ class Emailer { | |||
402 | return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) | 402 | return JobQueue.Instance.createJob({ type: 'email', payload: emailPayload }) |
403 | } | 403 | } |
404 | 404 | ||
405 | addContactFormJob (fromEmail: string, fromName: string, body: string) { | 405 | addContactFormJob (fromEmail: string, fromName: string, subject: string, body: string) { |
406 | const text = 'Hello dear admin,\n\n' + | 406 | const text = 'Hello dear admin,\n\n' + |
407 | fromName + ' sent you a message' + | 407 | fromName + ' sent you a message' + |
408 | '\n\n---------------------------------------\n\n' + | 408 | '\n\n---------------------------------------\n\n' + |
@@ -415,7 +415,7 @@ class Emailer { | |||
415 | fromDisplayName: fromEmail, | 415 | fromDisplayName: fromEmail, |
416 | replyTo: fromEmail, | 416 | replyTo: fromEmail, |
417 | to: [ CONFIG.ADMIN.EMAIL ], | 417 | to: [ CONFIG.ADMIN.EMAIL ], |
418 | subject: CONFIG.EMAIL.OBJECT.PREFIX + 'Contact form submitted', | 418 | subject: CONFIG.EMAIL.OBJECT.PREFIX + subject, |
419 | text | 419 | text |
420 | } | 420 | } |
421 | 421 | ||