aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared
diff options
context:
space:
mode:
Diffstat (limited to 'shared')
-rw-r--r--shared/extra-utils/users/user-notifications.ts6
-rw-r--r--shared/extra-utils/videos/video-blacklist.ts4
-rw-r--r--shared/models/users/user-flag.model.ts2
-rw-r--r--shared/models/users/user-notification.model.ts6
-rw-r--r--shared/models/users/user-right.enum.ts2
-rw-r--r--shared/models/users/user-role.ts2
-rw-r--r--shared/models/videos/blacklist/video-blacklist.model.ts6
7 files changed, 14 insertions, 14 deletions
diff --git a/shared/extra-utils/users/user-notifications.ts b/shared/extra-utils/users/user-notifications.ts
index bd00894c4..6f85bd450 100644
--- a/shared/extra-utils/users/user-notifications.ts
+++ b/shared/extra-utils/users/user-notifications.ts
@@ -455,7 +455,7 @@ async function checkNewVideoAbuseForModerators (base: CheckerBaseParams, videoUU
455} 455}
456 456
457async function checkVideoAutoBlacklistForModerators (base: CheckerBaseParams, videoUUID: string, videoName: string, type: CheckerType) { 457async function checkVideoAutoBlacklistForModerators (base: CheckerBaseParams, videoUUID: string, videoName: string, type: CheckerType) {
458 const notificationType = UserNotificationType.VIDEO_AUTO_BLACKLIST_FOR_MODERATORS 458 const notificationType = UserNotificationType.VIDEO_AUTO_BLOCK_FOR_MODERATORS
459 459
460 function notificationChecker (notification: UserNotification, type: CheckerType) { 460 function notificationChecker (notification: UserNotification, type: CheckerType) {
461 if (type === 'presence') { 461 if (type === 'presence') {
@@ -486,8 +486,8 @@ async function checkNewBlacklistOnMyVideo (
486 blacklistType: 'blacklist' | 'unblacklist' 486 blacklistType: 'blacklist' | 'unblacklist'
487) { 487) {
488 const notificationType = blacklistType === 'blacklist' 488 const notificationType = blacklistType === 'blacklist'
489 ? UserNotificationType.BLACKLIST_ON_MY_VIDEO 489 ? UserNotificationType.BLOCK_ON_MY_VIDEO
490 : UserNotificationType.UNBLACKLIST_ON_MY_VIDEO 490 : UserNotificationType.UNBLOCK_ON_MY_VIDEO
491 491
492 function notificationChecker (notification: UserNotification) { 492 function notificationChecker (notification: UserNotification) {
493 expect(notification).to.not.be.undefined 493 expect(notification).to.not.be.undefined
diff --git a/shared/extra-utils/videos/video-blacklist.ts b/shared/extra-utils/videos/video-blacklist.ts
index ba139ef95..c06b2aa5d 100644
--- a/shared/extra-utils/videos/video-blacklist.ts
+++ b/shared/extra-utils/videos/video-blacklist.ts
@@ -1,5 +1,5 @@
1import * as request from 'supertest' 1import * as request from 'supertest'
2import { VideoBlacklistType } from '../../models/videos' 2import { VideoBlockType } from '../../models/videos'
3import { makeGetRequest } from '..' 3import { makeGetRequest } from '..'
4 4
5function addVideoToBlacklist ( 5function addVideoToBlacklist (
@@ -45,7 +45,7 @@ function getBlacklistedVideosList (parameters: {
45 url: string 45 url: string
46 token: string 46 token: string
47 sort?: string 47 sort?: string
48 type?: VideoBlacklistType 48 type?: VideoBlockType
49 specialStatus?: number 49 specialStatus?: number
50}) { 50}) {
51 const { url, token, sort, type, specialStatus = 200 } = parameters 51 const { url, token, sort, type, specialStatus = 200 } = parameters
diff --git a/shared/models/users/user-flag.model.ts b/shared/models/users/user-flag.model.ts
index f5759f18f..e8b5a5c50 100644
--- a/shared/models/users/user-flag.model.ts
+++ b/shared/models/users/user-flag.model.ts
@@ -1,4 +1,4 @@
1export enum UserAdminFlag { 1export enum UserAdminFlag {
2 NONE = 0, 2 NONE = 0,
3 BY_PASS_VIDEO_AUTO_BLACKLIST = 1 << 0 3 BYPASS_VIDEO_AUTO_BLOCK = 1 << 0
4} 4}
diff --git a/shared/models/users/user-notification.model.ts b/shared/models/users/user-notification.model.ts
index e9be1ca7f..2329503a8 100644
--- a/shared/models/users/user-notification.model.ts
+++ b/shared/models/users/user-notification.model.ts
@@ -5,8 +5,8 @@ export enum UserNotificationType {
5 NEW_COMMENT_ON_MY_VIDEO = 2, 5 NEW_COMMENT_ON_MY_VIDEO = 2,
6 NEW_VIDEO_ABUSE_FOR_MODERATORS = 3, 6 NEW_VIDEO_ABUSE_FOR_MODERATORS = 3,
7 7
8 BLACKLIST_ON_MY_VIDEO = 4, 8 BLOCK_ON_MY_VIDEO = 4,
9 UNBLACKLIST_ON_MY_VIDEO = 5, 9 UNBLOCK_ON_MY_VIDEO = 5,
10 10
11 MY_VIDEO_PUBLISHED = 6, 11 MY_VIDEO_PUBLISHED = 6,
12 12
@@ -17,7 +17,7 @@ export enum UserNotificationType {
17 NEW_FOLLOW = 10, 17 NEW_FOLLOW = 10,
18 COMMENT_MENTION = 11, 18 COMMENT_MENTION = 11,
19 19
20 VIDEO_AUTO_BLACKLIST_FOR_MODERATORS = 12, 20 VIDEO_AUTO_BLOCK_FOR_MODERATORS = 12,
21 21
22 NEW_INSTANCE_FOLLOWER = 13, 22 NEW_INSTANCE_FOLLOWER = 13,
23 23
diff --git a/shared/models/users/user-right.enum.ts b/shared/models/users/user-right.enum.ts
index 2f88a65de..3fb760709 100644
--- a/shared/models/users/user-right.enum.ts
+++ b/shared/models/users/user-right.enum.ts
@@ -20,7 +20,7 @@ export enum UserRight {
20 MANAGE_ACCOUNTS_BLOCKLIST, 20 MANAGE_ACCOUNTS_BLOCKLIST,
21 MANAGE_SERVERS_BLOCKLIST, 21 MANAGE_SERVERS_BLOCKLIST,
22 22
23 MANAGE_VIDEO_BLACKLIST, 23 MANAGE_VIDEO_BLOCKS,
24 24
25 REMOVE_ANY_VIDEO, 25 REMOVE_ANY_VIDEO,
26 REMOVE_ANY_VIDEO_CHANNEL, 26 REMOVE_ANY_VIDEO_CHANNEL,
diff --git a/shared/models/users/user-role.ts b/shared/models/users/user-role.ts
index 2b08b5850..30ec5edce 100644
--- a/shared/models/users/user-role.ts
+++ b/shared/models/users/user-role.ts
@@ -19,7 +19,7 @@ const userRoleRights: { [ id in UserRole ]: UserRight[] } = {
19 ], 19 ],
20 20
21 [UserRole.MODERATOR]: [ 21 [UserRole.MODERATOR]: [
22 UserRight.MANAGE_VIDEO_BLACKLIST, 22 UserRight.MANAGE_VIDEO_BLOCKS,
23 UserRight.MANAGE_VIDEO_ABUSES, 23 UserRight.MANAGE_VIDEO_ABUSES,
24 UserRight.REMOVE_ANY_VIDEO, 24 UserRight.REMOVE_ANY_VIDEO,
25 UserRight.REMOVE_ANY_VIDEO_CHANNEL, 25 UserRight.REMOVE_ANY_VIDEO_CHANNEL,
diff --git a/shared/models/videos/blacklist/video-blacklist.model.ts b/shared/models/videos/blacklist/video-blacklist.model.ts
index a6e0ef175..e6090b1e9 100644
--- a/shared/models/videos/blacklist/video-blacklist.model.ts
+++ b/shared/models/videos/blacklist/video-blacklist.model.ts
@@ -1,15 +1,15 @@
1import { Video } from '../video.model' 1import { Video } from '../video.model'
2 2
3export enum VideoBlacklistType { 3export enum VideoBlockType {
4 MANUAL = 1, 4 MANUAL = 1,
5 AUTO_BEFORE_PUBLISHED = 2 5 AUTO_BEFORE_PUBLISHED = 2
6} 6}
7 7
8export interface VideoBlacklist { 8export interface VideoBlocklist {
9 id: number 9 id: number
10 unfederated: boolean 10 unfederated: boolean
11 reason?: string 11 reason?: string
12 type: VideoBlacklistType 12 type: VideoBlockType
13 13
14 video: Video 14 video: Video
15 15