diff options
-rw-r--r-- | client/src/standalone/videos/embed.ts | 2 | ||||
-rw-r--r-- | server/initializers/constants.ts | 3 | ||||
-rw-r--r-- | server/models/video/video-caption.ts | 2 | ||||
-rw-r--r-- | server/tests/api/server/follows.ts | 2 | ||||
-rw-r--r-- | server/tests/api/videos/video-captions.ts | 2 | ||||
-rw-r--r-- | server/tests/utils/videos/video-abuses.ts | 2 | ||||
-rw-r--r-- | shared/models/users/user.model.ts | 2 | ||||
-rw-r--r-- | shared/models/videos/abuse/video-abuse-create.model.ts (renamed from shared/models/videos/video-abuse-create.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/abuse/video-abuse-state.model.ts (renamed from shared/models/videos/video-abuse-state.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/abuse/video-abuse-update.model.ts (renamed from shared/models/videos/video-abuse-update.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/abuse/video-abuse.model.ts (renamed from shared/models/videos/video-abuse.model.ts) | 4 | ||||
-rw-r--r-- | shared/models/videos/blacklist/video-blacklist-create.model.ts (renamed from shared/models/videos/video-blacklist-create.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/blacklist/video-blacklist-update.model.ts (renamed from shared/models/videos/video-blacklist-update.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/blacklist/video-blacklist.model.ts (renamed from shared/models/videos/video-blacklist.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/caption/video-caption-update.model.ts (renamed from shared/models/videos/video-caption-update.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/caption/video-caption.model.ts (renamed from shared/models/videos/video-caption.model.ts) | 2 | ||||
-rw-r--r-- | shared/models/videos/channel/video-channel-create.model.ts (renamed from shared/models/videos/video-channel-create.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/channel/video-channel-update.model.ts (renamed from shared/models/videos/video-channel-update.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/channel/video-channel.model.ts (renamed from shared/models/videos/video-channel.model.ts) | 6 | ||||
-rw-r--r-- | shared/models/videos/import/video-import-create.model.ts (renamed from shared/models/videos/video-import-create.model.ts) | 2 | ||||
-rw-r--r-- | shared/models/videos/import/video-import-state.enum.ts (renamed from shared/models/videos/video-import-state.enum.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/import/video-import.model.ts (renamed from shared/models/videos/video-import.model.ts) | 4 | ||||
-rw-r--r-- | shared/models/videos/index.ts | 34 | ||||
-rw-r--r-- | shared/models/videos/rate/user-video-rate-update.model.ts (renamed from shared/models/videos/user-video-rate-update.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/rate/user-video-rate.model.ts (renamed from shared/models/videos/user-video-rate.model.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/rate/user-video-rate.type.ts (renamed from shared/models/videos/user-video-rate.type.ts) | 0 | ||||
-rw-r--r-- | shared/models/videos/video.model.ts | 2 |
27 files changed, 34 insertions, 35 deletions
diff --git a/client/src/standalone/videos/embed.ts b/client/src/standalone/videos/embed.ts index 98ce73257..2aabb5fe8 100644 --- a/client/src/standalone/videos/embed.ts +++ b/client/src/standalone/videos/embed.ts | |||
@@ -24,7 +24,7 @@ import { ResultList, VideoDetails } from '../../../../shared' | |||
24 | import { addContextMenu, getVideojsOptions, loadLocale } from '../../assets/player/peertube-player' | 24 | import { addContextMenu, getVideojsOptions, loadLocale } from '../../assets/player/peertube-player' |
25 | import { PeerTubeResolution } from '../player/definitions' | 25 | import { PeerTubeResolution } from '../player/definitions' |
26 | import { VideoJSCaption } from '../../assets/player/peertube-videojs-typings' | 26 | import { VideoJSCaption } from '../../assets/player/peertube-videojs-typings' |
27 | import { VideoCaption } from '../../../../shared/models/videos/video-caption.model' | 27 | import { VideoCaption } from '../../../../shared/models/videos/caption/video-caption.model' |
28 | 28 | ||
29 | /** | 29 | /** |
30 | * Embed API exposes control of the embed player to the outside world via | 30 | * Embed API exposes control of the embed player to the outside world via |
diff --git a/server/initializers/constants.ts b/server/initializers/constants.ts index ff8e64330..bce797159 100644 --- a/server/initializers/constants.ts +++ b/server/initializers/constants.ts | |||
@@ -3,12 +3,11 @@ import { dirname, join } from 'path' | |||
3 | import { JobType, VideoRateType, VideoState } from '../../shared/models' | 3 | import { JobType, VideoRateType, VideoState } from '../../shared/models' |
4 | import { ActivityPubActorType } from '../../shared/models/activitypub' | 4 | import { ActivityPubActorType } from '../../shared/models/activitypub' |
5 | import { FollowState } from '../../shared/models/actors' | 5 | import { FollowState } from '../../shared/models/actors' |
6 | import { VideoPrivacy, VideoAbuseState } from '../../shared/models/videos' | 6 | import { VideoPrivacy, VideoAbuseState, VideoImportState } from '../../shared/models/videos' |
7 | // Do not use barrels, remain constants as independent as possible | 7 | // Do not use barrels, remain constants as independent as possible |
8 | import { buildPath, isTestInstance, root, sanitizeHost, sanitizeUrl } from '../helpers/core-utils' | 8 | import { buildPath, isTestInstance, root, sanitizeHost, sanitizeUrl } from '../helpers/core-utils' |
9 | import { NSFWPolicyType } from '../../shared/models/videos/nsfw-policy.type' | 9 | import { NSFWPolicyType } from '../../shared/models/videos/nsfw-policy.type' |
10 | import { invert } from 'lodash' | 10 | import { invert } from 'lodash' |
11 | import { VideoImportState } from '../../shared/models/videos/video-import-state.enum' | ||
12 | 11 | ||
13 | // Use a variable to reload the configuration if we need | 12 | // Use a variable to reload the configuration if we need |
14 | let config: IConfig = require('config') | 13 | let config: IConfig = require('config') |
diff --git a/server/models/video/video-caption.ts b/server/models/video/video-caption.ts index 4a25097f8..3593646a2 100644 --- a/server/models/video/video-caption.ts +++ b/server/models/video/video-caption.ts | |||
@@ -15,7 +15,7 @@ import { | |||
15 | import { throwIfNotValid } from '../utils' | 15 | import { throwIfNotValid } from '../utils' |
16 | import { VideoModel } from './video' | 16 | import { VideoModel } from './video' |
17 | import { isVideoCaptionLanguageValid } from '../../helpers/custom-validators/video-captions' | 17 | import { isVideoCaptionLanguageValid } from '../../helpers/custom-validators/video-captions' |
18 | import { VideoCaption } from '../../../shared/models/videos/video-caption.model' | 18 | import { VideoCaption } from '../../../shared/models/videos/caption/video-caption.model' |
19 | import { CONFIG, STATIC_PATHS, VIDEO_LANGUAGES } from '../../initializers' | 19 | import { CONFIG, STATIC_PATHS, VIDEO_LANGUAGES } from '../../initializers' |
20 | import { join } from 'path' | 20 | import { join } from 'path' |
21 | import { logger } from '../../helpers/logger' | 21 | import { logger } from '../../helpers/logger' |
diff --git a/server/tests/api/server/follows.ts b/server/tests/api/server/follows.ts index b91cb75c2..1cad8998c 100644 --- a/server/tests/api/server/follows.ts +++ b/server/tests/api/server/follows.ts | |||
@@ -27,7 +27,7 @@ import { | |||
27 | import { rateVideo } from '../../utils/videos/videos' | 27 | import { rateVideo } from '../../utils/videos/videos' |
28 | import { waitJobs } from '../../utils/server/jobs' | 28 | import { waitJobs } from '../../utils/server/jobs' |
29 | import { createVideoCaption, listVideoCaptions, testCaptionFile } from '../../utils/videos/video-captions' | 29 | import { createVideoCaption, listVideoCaptions, testCaptionFile } from '../../utils/videos/video-captions' |
30 | import { VideoCaption } from '../../../../shared/models/videos/video-caption.model' | 30 | import { VideoCaption } from '../../../../shared/models/videos/caption/video-caption.model' |
31 | 31 | ||
32 | const expect = chai.expect | 32 | const expect = chai.expect |
33 | 33 | ||
diff --git a/server/tests/api/videos/video-captions.ts b/server/tests/api/videos/video-captions.ts index ba9ebbdd6..6e441410d 100644 --- a/server/tests/api/videos/video-captions.ts +++ b/server/tests/api/videos/video-captions.ts | |||
@@ -6,7 +6,7 @@ import { checkVideoFilesWereRemoved, doubleFollow, flushAndRunMultipleServers, r | |||
6 | import { flushTests, killallServers, ServerInfo, setAccessTokensToServers } from '../../utils/index' | 6 | import { flushTests, killallServers, ServerInfo, setAccessTokensToServers } from '../../utils/index' |
7 | import { waitJobs } from '../../utils/server/jobs' | 7 | import { waitJobs } from '../../utils/server/jobs' |
8 | import { createVideoCaption, deleteVideoCaption, listVideoCaptions, testCaptionFile } from '../../utils/videos/video-captions' | 8 | import { createVideoCaption, deleteVideoCaption, listVideoCaptions, testCaptionFile } from '../../utils/videos/video-captions' |
9 | import { VideoCaption } from '../../../../shared/models/videos/video-caption.model' | 9 | import { VideoCaption } from '../../../../shared/models/videos/caption/video-caption.model' |
10 | 10 | ||
11 | const expect = chai.expect | 11 | const expect = chai.expect |
12 | 12 | ||
diff --git a/server/tests/utils/videos/video-abuses.ts b/server/tests/utils/videos/video-abuses.ts index 5f138d6b3..14907e6a0 100644 --- a/server/tests/utils/videos/video-abuses.ts +++ b/server/tests/utils/videos/video-abuses.ts | |||
@@ -1,5 +1,5 @@ | |||
1 | import * as request from 'supertest' | 1 | import * as request from 'supertest' |
2 | import { VideoAbuseUpdate } from '../../../../shared/models/videos/video-abuse-update.model' | 2 | import { VideoAbuseUpdate } from '../../../../shared/models/videos/abuse/video-abuse-update.model' |
3 | import { makeDeleteRequest, makePutBodyRequest } from '..' | 3 | import { makeDeleteRequest, makePutBodyRequest } from '..' |
4 | 4 | ||
5 | function reportVideoAbuse (url: string, token: string, videoId: number | string, reason: string, specialStatus = 200) { | 5 | function reportVideoAbuse (url: string, token: string, videoId: number | string, reason: string, specialStatus = 200) { |
diff --git a/shared/models/users/user.model.ts b/shared/models/users/user.model.ts index d3085267f..8eddaa496 100644 --- a/shared/models/users/user.model.ts +++ b/shared/models/users/user.model.ts | |||
@@ -1,5 +1,5 @@ | |||
1 | import { Account } from '../actors' | 1 | import { Account } from '../actors' |
2 | import { VideoChannel } from '../videos/video-channel.model' | 2 | import { VideoChannel } from '../videos/channel/video-channel.model' |
3 | import { UserRole } from './user-role' | 3 | import { UserRole } from './user-role' |
4 | import { NSFWPolicyType } from '../videos/nsfw-policy.type' | 4 | import { NSFWPolicyType } from '../videos/nsfw-policy.type' |
5 | 5 | ||
diff --git a/shared/models/videos/video-abuse-create.model.ts b/shared/models/videos/abuse/video-abuse-create.model.ts index db6458275..db6458275 100644 --- a/shared/models/videos/video-abuse-create.model.ts +++ b/shared/models/videos/abuse/video-abuse-create.model.ts | |||
diff --git a/shared/models/videos/video-abuse-state.model.ts b/shared/models/videos/abuse/video-abuse-state.model.ts index 529f034bd..529f034bd 100644 --- a/shared/models/videos/video-abuse-state.model.ts +++ b/shared/models/videos/abuse/video-abuse-state.model.ts | |||
diff --git a/shared/models/videos/video-abuse-update.model.ts b/shared/models/videos/abuse/video-abuse-update.model.ts index 9b32aae48..9b32aae48 100644 --- a/shared/models/videos/video-abuse-update.model.ts +++ b/shared/models/videos/abuse/video-abuse-update.model.ts | |||
diff --git a/shared/models/videos/video-abuse.model.ts b/shared/models/videos/abuse/video-abuse.model.ts index b2319aa00..4f668795a 100644 --- a/shared/models/videos/video-abuse.model.ts +++ b/shared/models/videos/abuse/video-abuse.model.ts | |||
@@ -1,5 +1,5 @@ | |||
1 | import { Account } from '../actors' | 1 | import { Account } from '../../actors/index' |
2 | import { VideoConstant } from './video-constant.model' | 2 | import { VideoConstant } from '../video-constant.model' |
3 | import { VideoAbuseState } from './video-abuse-state.model' | 3 | import { VideoAbuseState } from './video-abuse-state.model' |
4 | 4 | ||
5 | export interface VideoAbuse { | 5 | export interface VideoAbuse { |
diff --git a/shared/models/videos/video-blacklist-create.model.ts b/shared/models/videos/blacklist/video-blacklist-create.model.ts index 89c69cb56..89c69cb56 100644 --- a/shared/models/videos/video-blacklist-create.model.ts +++ b/shared/models/videos/blacklist/video-blacklist-create.model.ts | |||
diff --git a/shared/models/videos/video-blacklist-update.model.ts b/shared/models/videos/blacklist/video-blacklist-update.model.ts index 0a86cf7b0..0a86cf7b0 100644 --- a/shared/models/videos/video-blacklist-update.model.ts +++ b/shared/models/videos/blacklist/video-blacklist-update.model.ts | |||
diff --git a/shared/models/videos/video-blacklist.model.ts b/shared/models/videos/blacklist/video-blacklist.model.ts index ef4e5e3a2..ef4e5e3a2 100644 --- a/shared/models/videos/video-blacklist.model.ts +++ b/shared/models/videos/blacklist/video-blacklist.model.ts | |||
diff --git a/shared/models/videos/video-caption-update.model.ts b/shared/models/videos/caption/video-caption-update.model.ts index ff5728715..ff5728715 100644 --- a/shared/models/videos/video-caption-update.model.ts +++ b/shared/models/videos/caption/video-caption-update.model.ts | |||
diff --git a/shared/models/videos/video-caption.model.ts b/shared/models/videos/caption/video-caption.model.ts index 4695224ce..d3c73e1a6 100644 --- a/shared/models/videos/video-caption.model.ts +++ b/shared/models/videos/caption/video-caption.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { VideoConstant } from './video-constant.model' | 1 | import { VideoConstant } from '../video-constant.model' |
2 | 2 | ||
3 | export interface VideoCaption { | 3 | export interface VideoCaption { |
4 | language: VideoConstant<string> | 4 | language: VideoConstant<string> |
diff --git a/shared/models/videos/video-channel-create.model.ts b/shared/models/videos/channel/video-channel-create.model.ts index 08cd5fb84..08cd5fb84 100644 --- a/shared/models/videos/video-channel-create.model.ts +++ b/shared/models/videos/channel/video-channel-create.model.ts | |||
diff --git a/shared/models/videos/video-channel-update.model.ts b/shared/models/videos/channel/video-channel-update.model.ts index 3626ce8a9..3626ce8a9 100644 --- a/shared/models/videos/video-channel-update.model.ts +++ b/shared/models/videos/channel/video-channel-update.model.ts | |||
diff --git a/shared/models/videos/video-channel.model.ts b/shared/models/videos/channel/video-channel.model.ts index 6e61183a7..92918f66c 100644 --- a/shared/models/videos/video-channel.model.ts +++ b/shared/models/videos/channel/video-channel.model.ts | |||
@@ -1,6 +1,6 @@ | |||
1 | import { Actor } from '../actors/actor.model' | 1 | import { Actor } from '../../actors/actor.model' |
2 | import { Video } from './video.model' | 2 | import { Video } from '../video.model' |
3 | import { Account } from '../actors' | 3 | import { Account } from '../../actors/index' |
4 | 4 | ||
5 | export interface VideoChannel extends Actor { | 5 | export interface VideoChannel extends Actor { |
6 | displayName: string | 6 | displayName: string |
diff --git a/shared/models/videos/video-import-create.model.ts b/shared/models/videos/import/video-import-create.model.ts index e76084e06..425477389 100644 --- a/shared/models/videos/video-import-create.model.ts +++ b/shared/models/videos/import/video-import-create.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { VideoUpdate } from './video-update.model' | 1 | import { VideoUpdate } from '../video-update.model' |
2 | 2 | ||
3 | export interface VideoImportCreate extends VideoUpdate { | 3 | export interface VideoImportCreate extends VideoUpdate { |
4 | targetUrl?: string | 4 | targetUrl?: string |
diff --git a/shared/models/videos/video-import-state.enum.ts b/shared/models/videos/import/video-import-state.enum.ts index b178fbf3a..b178fbf3a 100644 --- a/shared/models/videos/video-import-state.enum.ts +++ b/shared/models/videos/import/video-import-state.enum.ts | |||
diff --git a/shared/models/videos/video-import.model.ts b/shared/models/videos/import/video-import.model.ts index 293854006..e2a56617d 100644 --- a/shared/models/videos/video-import.model.ts +++ b/shared/models/videos/import/video-import.model.ts | |||
@@ -1,5 +1,5 @@ | |||
1 | import { Video } from './video.model' | 1 | import { Video } from '../video.model' |
2 | import { VideoConstant } from './video-constant.model' | 2 | import { VideoConstant } from '../video-constant.model' |
3 | import { VideoImportState } from './video-import-state.enum' | 3 | import { VideoImportState } from './video-import-state.enum' |
4 | 4 | ||
5 | export interface VideoImport { | 5 | export interface VideoImport { |
diff --git a/shared/models/videos/index.ts b/shared/models/videos/index.ts index b99dd2d8f..6b579cf3e 100644 --- a/shared/models/videos/index.ts +++ b/shared/models/videos/index.ts | |||
@@ -1,16 +1,16 @@ | |||
1 | export * from './user-video-rate-update.model' | 1 | export * from './rate/user-video-rate-update.model' |
2 | export * from './user-video-rate.model' | 2 | export * from './rate/user-video-rate.model' |
3 | export * from './user-video-rate.type' | 3 | export * from './rate/user-video-rate.type' |
4 | export * from './video-abuse-state.model' | 4 | export * from './abuse/video-abuse-state.model' |
5 | export * from './video-abuse-create.model' | 5 | export * from './abuse/video-abuse-create.model' |
6 | export * from './video-abuse.model' | 6 | export * from './abuse/video-abuse.model' |
7 | export * from './video-abuse-update.model' | 7 | export * from './abuse/video-abuse-update.model' |
8 | export * from './video-blacklist.model' | 8 | export * from './blacklist/video-blacklist.model' |
9 | export * from './video-blacklist-create.model' | 9 | export * from './blacklist/video-blacklist-create.model' |
10 | export * from './video-blacklist-update.model' | 10 | export * from './blacklist/video-blacklist-update.model' |
11 | export * from './video-channel-create.model' | 11 | export * from './channel/video-channel-create.model' |
12 | export * from './video-channel-update.model' | 12 | export * from './channel/video-channel-update.model' |
13 | export * from './video-channel.model' | 13 | export * from './channel/video-channel.model' |
14 | export * from './video-create.model' | 14 | export * from './video-create.model' |
15 | export * from './video-privacy.enum' | 15 | export * from './video-privacy.enum' |
16 | export * from './video-rate.type' | 16 | export * from './video-rate.type' |
@@ -18,8 +18,8 @@ export * from './video-resolution.enum' | |||
18 | export * from './video-update.model' | 18 | export * from './video-update.model' |
19 | export * from './video.model' | 19 | export * from './video.model' |
20 | export * from './video-state.enum' | 20 | export * from './video-state.enum' |
21 | export * from './video-caption-update.model' | 21 | export * from './caption/video-caption-update.model' |
22 | export * from './video-import-create.model' | 22 | export * from './import/video-import-create.model' |
23 | export * from './video-import-state.enum' | 23 | export * from './import/video-import-state.enum' |
24 | export * from './video-import.model' | 24 | export * from './import/video-import.model' |
25 | export { VideoConstant } from './video-constant.model' | 25 | export { VideoConstant } from './video-constant.model' |
diff --git a/shared/models/videos/user-video-rate-update.model.ts b/shared/models/videos/rate/user-video-rate-update.model.ts index 85e89271a..85e89271a 100644 --- a/shared/models/videos/user-video-rate-update.model.ts +++ b/shared/models/videos/rate/user-video-rate-update.model.ts | |||
diff --git a/shared/models/videos/user-video-rate.model.ts b/shared/models/videos/rate/user-video-rate.model.ts index d39a1c3d5..d39a1c3d5 100644 --- a/shared/models/videos/user-video-rate.model.ts +++ b/shared/models/videos/rate/user-video-rate.model.ts | |||
diff --git a/shared/models/videos/user-video-rate.type.ts b/shared/models/videos/rate/user-video-rate.type.ts index a4d9c7e39..a4d9c7e39 100644 --- a/shared/models/videos/user-video-rate.type.ts +++ b/shared/models/videos/rate/user-video-rate.type.ts | |||
diff --git a/shared/models/videos/video.model.ts b/shared/models/videos/video.model.ts index 8dfa96069..8e1fbe444 100644 --- a/shared/models/videos/video.model.ts +++ b/shared/models/videos/video.model.ts | |||
@@ -1,7 +1,7 @@ | |||
1 | import { VideoResolution, VideoState } from '../../index' | 1 | import { VideoResolution, VideoState } from '../../index' |
2 | import { Account } from '../actors' | 2 | import { Account } from '../actors' |
3 | import { Avatar } from '../avatars/avatar.model' | 3 | import { Avatar } from '../avatars/avatar.model' |
4 | import { VideoChannel } from './video-channel.model' | 4 | import { VideoChannel } from './channel/video-channel.model' |
5 | import { VideoPrivacy } from './video-privacy.enum' | 5 | import { VideoPrivacy } from './video-privacy.enum' |
6 | import { VideoScheduleUpdate } from './video-schedule-update.model' | 6 | import { VideoScheduleUpdate } from './video-schedule-update.model' |
7 | import { VideoConstant } from './video-constant.model' | 7 | import { VideoConstant } from './video-constant.model' |