]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/lib/emailer.ts
Add plugin auth migrations
[github/Chocobozzz/PeerTube.git] / server / lib / emailer.ts
index 2c0641f3af3df7d377b8a93b856820039e610b0a..45d57fd28a7a7b3479c20fc90587f851466f8149 100644 (file)
@@ -3,7 +3,6 @@ import { isTestInstance } from '../helpers/core-utils'
 import { bunyanLogger, logger } from '../helpers/logger'
 import { CONFIG, isEmailEnabled } from '../initializers/config'
 import { JobQueue } from './job-queue'
-import { EmailPayload } from './job-queue/handlers/email'
 import { readFileSync } from 'fs-extra'
 import { WEBSERVER } from '../initializers/constants'
 import {
@@ -16,15 +15,7 @@ import {
 } from '../typings/models/video'
 import { MActorFollowActors, MActorFollowFull, MUser } from '../typings/models'
 import { MVideoImport, MVideoImportVideo } from '@server/typings/models/video/video-import'
-
-type SendEmailOptions = {
-  to: string[]
-  subject: string
-  text: string
-
-  fromDisplayName?: string
-  replyTo?: string
-}
+import { EmailPayload } from '@shared/models'
 
 class Emailer {
 
@@ -292,7 +283,7 @@ class Emailer {
     const videoUrl = WEBSERVER.URL + videoAbuse.Video.getWatchStaticPath()
 
     const text = 'Hi,\n\n' +
-      `${WEBSERVER.HOST} received an abuse for the following video ${videoUrl}\n\n` +
+      `${WEBSERVER.HOST} received an abuse for the following video: ${videoUrl}\n\n` +
       'Cheers,\n' +
       `${CONFIG.EMAIL.BODY.SIGNATURE}`
 
@@ -507,6 +498,5 @@ class Emailer {
 // ---------------------------------------------------------------------------
 
 export {
-  Emailer,
-  SendEmailOptions
+  Emailer
 }