aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/initializers/database.ts
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2017-11-09 17:51:58 +0100
committerChocobozzz <florian.bigard@gmail.com>2017-11-27 19:40:51 +0100
commite4f97babf701481b55cc10fb3448feab5f97c867 (patch)
treeaf37402a594dc5ff09f71ecb0687e8cfe4cdb471 /server/initializers/database.ts
parent343ad675f2a26c15b86150a9a3552e619d5d44f4 (diff)
downloadPeerTube-e4f97babf701481b55cc10fb3448feab5f97c867.tar.gz
PeerTube-e4f97babf701481b55cc10fb3448feab5f97c867.tar.zst
PeerTube-e4f97babf701481b55cc10fb3448feab5f97c867.zip
Begin activitypub
Diffstat (limited to 'server/initializers/database.ts')
-rw-r--r--server/initializers/database.ts14
1 files changed, 8 insertions, 6 deletions
diff --git a/server/initializers/database.ts b/server/initializers/database.ts
index 141566c3a..52e766394 100644
--- a/server/initializers/database.ts
+++ b/server/initializers/database.ts
@@ -15,8 +15,9 @@ import { BlacklistedVideoModel } from './../models/video/video-blacklist-interfa
15import { VideoFileModel } from './../models/video/video-file-interface' 15import { VideoFileModel } from './../models/video/video-file-interface'
16import { VideoAbuseModel } from './../models/video/video-abuse-interface' 16import { VideoAbuseModel } from './../models/video/video-abuse-interface'
17import { VideoChannelModel } from './../models/video/video-channel-interface' 17import { VideoChannelModel } from './../models/video/video-channel-interface'
18import { UserModel } from './../models/user/user-interface' 18import { UserModel } from '../models/account/user-interface'
19import { UserVideoRateModel } from './../models/user/user-video-rate-interface' 19import { AccountVideoRateModel } from '../models/account/account-video-rate-interface'
20import { AccountFollowModel } from '../models/account/account-follow-interface'
20import { TagModel } from './../models/video/tag-interface' 21import { TagModel } from './../models/video/tag-interface'
21import { RequestModel } from './../models/request/request-interface' 22import { RequestModel } from './../models/request/request-interface'
22import { RequestVideoQaduModel } from './../models/request/request-video-qadu-interface' 23import { RequestVideoQaduModel } from './../models/request/request-video-qadu-interface'
@@ -26,7 +27,7 @@ import { PodModel } from './../models/pod/pod-interface'
26import { OAuthTokenModel } from './../models/oauth/oauth-token-interface' 27import { OAuthTokenModel } from './../models/oauth/oauth-token-interface'
27import { OAuthClientModel } from './../models/oauth/oauth-client-interface' 28import { OAuthClientModel } from './../models/oauth/oauth-client-interface'
28import { JobModel } from './../models/job/job-interface' 29import { JobModel } from './../models/job/job-interface'
29import { AuthorModel } from './../models/video/author-interface' 30import { AccountModel } from './../models/account/account-interface'
30import { ApplicationModel } from './../models/application/application-interface' 31import { ApplicationModel } from './../models/application/application-interface'
31 32
32const dbname = CONFIG.DATABASE.DBNAME 33const dbname = CONFIG.DATABASE.DBNAME
@@ -38,7 +39,7 @@ const database: {
38 init?: (silent: boolean) => Promise<void>, 39 init?: (silent: boolean) => Promise<void>,
39 40
40 Application?: ApplicationModel, 41 Application?: ApplicationModel,
41 Author?: AuthorModel, 42 Account?: AccountModel,
42 Job?: JobModel, 43 Job?: JobModel,
43 OAuthClient?: OAuthClientModel, 44 OAuthClient?: OAuthClientModel,
44 OAuthToken?: OAuthTokenModel, 45 OAuthToken?: OAuthTokenModel,
@@ -48,7 +49,8 @@ const database: {
48 RequestVideoQadu?: RequestVideoQaduModel, 49 RequestVideoQadu?: RequestVideoQaduModel,
49 Request?: RequestModel, 50 Request?: RequestModel,
50 Tag?: TagModel, 51 Tag?: TagModel,
51 UserVideoRate?: UserVideoRateModel, 52 AccountVideoRate?: AccountVideoRateModel,
53 AccountFollow?: AccountFollowModel,
52 User?: UserModel, 54 User?: UserModel,
53 VideoAbuse?: VideoAbuseModel, 55 VideoAbuse?: VideoAbuseModel,
54 VideoChannel?: VideoChannelModel, 56 VideoChannel?: VideoChannelModel,
@@ -126,7 +128,7 @@ async function getModelFiles (modelDirectory: string) {
126 return true 128 return true
127 }) 129 })
128 130
129 const tasks: Bluebird<any>[] = [] 131 const tasks: Promise<any>[] = []
130 132
131 // For each directory we read it and append model in the modelFilePaths array 133 // For each directory we read it and append model in the modelFilePaths array
132 for (const directory of directories) { 134 for (const directory of directories) {