diff options
author | Chocobozzz <me@florianbigard.com> | 2019-04-11 14:26:41 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2019-04-11 14:26:41 +0200 |
commit | 74dc3bca2b14f5fd3fe80c394dfc34177a46db77 (patch) | |
tree | e4b307beb6255420c9993a2aed470438317f100f /server/lib/user.ts | |
parent | 6dd9de95dfa39bd5c1faed00d1dbd52cd112bae0 (diff) | |
download | PeerTube-74dc3bca2b14f5fd3fe80c394dfc34177a46db77.tar.gz PeerTube-74dc3bca2b14f5fd3fe80c394dfc34177a46db77.tar.zst PeerTube-74dc3bca2b14f5fd3fe80c394dfc34177a46db77.zip |
Don't expose constants directly in initializers/
Diffstat (limited to 'server/lib/user.ts')
-rw-r--r-- | server/lib/user.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/server/lib/user.ts b/server/lib/user.ts index 6fbe3ed03..ce0d60518 100644 --- a/server/lib/user.ts +++ b/server/lib/user.ts | |||
@@ -1,7 +1,7 @@ | |||
1 | import * as Sequelize from 'sequelize' | 1 | import * as Sequelize from 'sequelize' |
2 | import * as uuidv4 from 'uuid/v4' | 2 | import * as uuidv4 from 'uuid/v4' |
3 | import { ActivityPubActorType } from '../../shared/models/activitypub' | 3 | import { ActivityPubActorType } from '../../shared/models/activitypub' |
4 | import { sequelizeTypescript, SERVER_ACTOR_NAME } from '../initializers' | 4 | import { SERVER_ACTOR_NAME } from '../initializers/constants' |
5 | import { AccountModel } from '../models/account/account' | 5 | import { AccountModel } from '../models/account/account' |
6 | import { UserModel } from '../models/account/user' | 6 | import { UserModel } from '../models/account/user' |
7 | import { buildActorInstance, getAccountActivityPubUrl, setAsyncActorKeys } from './activitypub' | 7 | import { buildActorInstance, getAccountActivityPubUrl, setAsyncActorKeys } from './activitypub' |
@@ -12,6 +12,7 @@ import { ActorModel } from '../models/activitypub/actor' | |||
12 | import { UserNotificationSettingModel } from '../models/account/user-notification-setting' | 12 | import { UserNotificationSettingModel } from '../models/account/user-notification-setting' |
13 | import { UserNotificationSetting, UserNotificationSettingValue } from '../../shared/models/users' | 13 | import { UserNotificationSetting, UserNotificationSettingValue } from '../../shared/models/users' |
14 | import { createWatchLaterPlaylist } from './video-playlist' | 14 | import { createWatchLaterPlaylist } from './video-playlist' |
15 | import { sequelizeTypescript } from '../initializers/database' | ||
15 | 16 | ||
16 | async function createUserAccountAndChannelAndPlaylist (userToCreate: UserModel, validateUser = true) { | 17 | async function createUserAccountAndChannelAndPlaylist (userToCreate: UserModel, validateUser = true) { |
17 | const { user, account, videoChannel } = await sequelizeTypescript.transaction(async t => { | 18 | const { user, account, videoChannel } = await sequelizeTypescript.transaction(async t => { |