diff options
Diffstat (limited to 'server/lib')
-rw-r--r-- | server/lib/emailer.ts | 4 | ||||
-rw-r--r-- | server/lib/moderation.ts | 2 | ||||
-rw-r--r-- | server/lib/notifier.ts | 6 |
3 files changed, 6 insertions, 6 deletions
diff --git a/server/lib/emailer.ts b/server/lib/emailer.ts index 48ba7421e..c6ad03328 100644 --- a/server/lib/emailer.ts +++ b/server/lib/emailer.ts | |||
@@ -5,7 +5,7 @@ import { join } from 'path' | |||
5 | import { VideoChannelModel } from '@server/models/video/video-channel' | 5 | import { VideoChannelModel } from '@server/models/video/video-channel' |
6 | import { MVideoBlacklistLightVideo, MVideoBlacklistVideo } from '@server/types/models/video/video-blacklist' | 6 | import { MVideoBlacklistLightVideo, MVideoBlacklistVideo } from '@server/types/models/video/video-blacklist' |
7 | import { MVideoImport, MVideoImportVideo } from '@server/types/models/video/video-import' | 7 | import { MVideoImport, MVideoImportVideo } from '@server/types/models/video/video-import' |
8 | import { Abuse, EmailPayload } from '@shared/models' | 8 | import { UserAbuse, EmailPayload } from '@shared/models' |
9 | import { SendEmailOptions } from '../../shared/models/server/emailer.model' | 9 | import { SendEmailOptions } from '../../shared/models/server/emailer.model' |
10 | import { isTestInstance, root } from '../helpers/core-utils' | 10 | import { isTestInstance, root } from '../helpers/core-utils' |
11 | import { bunyanLogger, logger } from '../helpers/logger' | 11 | import { bunyanLogger, logger } from '../helpers/logger' |
@@ -283,7 +283,7 @@ class Emailer { | |||
283 | } | 283 | } |
284 | 284 | ||
285 | addAbuseModeratorsNotification (to: string[], parameters: { | 285 | addAbuseModeratorsNotification (to: string[], parameters: { |
286 | abuse: Abuse | 286 | abuse: UserAbuse |
287 | abuseInstance: MAbuseFull | 287 | abuseInstance: MAbuseFull |
288 | reporter: string | 288 | reporter: string |
289 | }) { | 289 | }) { |
diff --git a/server/lib/moderation.ts b/server/lib/moderation.ts index 4fc9cd747..b140d5aa9 100644 --- a/server/lib/moderation.ts +++ b/server/lib/moderation.ts | |||
@@ -213,7 +213,7 @@ async function createAbuse (options: { | |||
213 | await sendAbuse(reporterAccount.Actor, abuseInstance, abuseInstance.FlaggedAccount, transaction) | 213 | await sendAbuse(reporterAccount.Actor, abuseInstance, abuseInstance.FlaggedAccount, transaction) |
214 | } | 214 | } |
215 | 215 | ||
216 | const abuseJSON = abuseInstance.toFormattedJSON() | 216 | const abuseJSON = abuseInstance.toFormattedAdminJSON() |
217 | auditLogger.create(reporterAccount.Actor.getIdentifier(), new AbuseAuditView(abuseJSON)) | 217 | auditLogger.create(reporterAccount.Actor.getIdentifier(), new AbuseAuditView(abuseJSON)) |
218 | 218 | ||
219 | Notifier.Instance.notifyOnNewAbuse({ | 219 | Notifier.Instance.notifyOnNewAbuse({ |
diff --git a/server/lib/notifier.ts b/server/lib/notifier.ts index c567e1c20..8f165d2fd 100644 --- a/server/lib/notifier.ts +++ b/server/lib/notifier.ts | |||
@@ -10,7 +10,7 @@ import { | |||
10 | } from '@server/types/models/user' | 10 | } from '@server/types/models/user' |
11 | import { MVideoBlacklistLightVideo, MVideoBlacklistVideo } from '@server/types/models/video/video-blacklist' | 11 | import { MVideoBlacklistLightVideo, MVideoBlacklistVideo } from '@server/types/models/video/video-blacklist' |
12 | import { MVideoImportVideo } from '@server/types/models/video/video-import' | 12 | import { MVideoImportVideo } from '@server/types/models/video/video-import' |
13 | import { Abuse } from '@shared/models' | 13 | import { UserAbuse } from '@shared/models' |
14 | import { UserNotificationSettingValue, UserNotificationType, UserRight } from '../../shared/models/users' | 14 | import { UserNotificationSettingValue, UserNotificationType, UserRight } from '../../shared/models/users' |
15 | import { VideoPrivacy, VideoState } from '../../shared/models/videos' | 15 | import { VideoPrivacy, VideoState } from '../../shared/models/videos' |
16 | import { logger } from '../helpers/logger' | 16 | import { logger } from '../helpers/logger' |
@@ -73,7 +73,7 @@ class Notifier { | |||
73 | .catch(err => logger.error('Cannot notify mentions of comment %s.', comment.url, { err })) | 73 | .catch(err => logger.error('Cannot notify mentions of comment %s.', comment.url, { err })) |
74 | } | 74 | } |
75 | 75 | ||
76 | notifyOnNewAbuse (parameters: { abuse: Abuse, abuseInstance: MAbuseFull, reporter: string }): void { | 76 | notifyOnNewAbuse (parameters: { abuse: UserAbuse, abuseInstance: MAbuseFull, reporter: string }): void { |
77 | this.notifyModeratorsOfNewAbuse(parameters) | 77 | this.notifyModeratorsOfNewAbuse(parameters) |
78 | .catch(err => logger.error('Cannot notify of new abuse %d.', parameters.abuseInstance.id, { err })) | 78 | .catch(err => logger.error('Cannot notify of new abuse %d.', parameters.abuseInstance.id, { err })) |
79 | } | 79 | } |
@@ -350,7 +350,7 @@ class Notifier { | |||
350 | } | 350 | } |
351 | 351 | ||
352 | private async notifyModeratorsOfNewAbuse (parameters: { | 352 | private async notifyModeratorsOfNewAbuse (parameters: { |
353 | abuse: Abuse | 353 | abuse: UserAbuse |
354 | abuseInstance: MAbuseFull | 354 | abuseInstance: MAbuseFull |
355 | reporter: string | 355 | reporter: string |
356 | }) { | 356 | }) { |