aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/account/account.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2019-04-11 11:33:44 +0200
committerChocobozzz <me@florianbigard.com>2019-04-11 13:45:39 +0200
commit6dd9de95dfa39bd5c1faed00d1dbd52cd112bae0 (patch)
treeb47de7efb8c6c611c63a15a971c6125a278f547a /server/models/account/account.ts
parent2c3abc4fa796555eb7d25f416c4f41ab3e3ad8ca (diff)
downloadPeerTube-6dd9de95dfa39bd5c1faed00d1dbd52cd112bae0.tar.gz
PeerTube-6dd9de95dfa39bd5c1faed00d1dbd52cd112bae0.tar.zst
PeerTube-6dd9de95dfa39bd5c1faed00d1dbd52cd112bae0.zip
Move config in its own file
Diffstat (limited to 'server/models/account/account.ts')
-rw-r--r--server/models/account/account.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/models/account/account.ts b/server/models/account/account.ts
index 7cc40f631..6f425024e 100644
--- a/server/models/account/account.ts
+++ b/server/models/account/account.ts
@@ -25,9 +25,9 @@ import { getSort, throwIfNotValid } from '../utils'
25import { VideoChannelModel } from '../video/video-channel' 25import { VideoChannelModel } from '../video/video-channel'
26import { VideoCommentModel } from '../video/video-comment' 26import { VideoCommentModel } from '../video/video-comment'
27import { UserModel } from './user' 27import { UserModel } from './user'
28import { CONFIG } from '../../initializers'
29import { AvatarModel } from '../avatar/avatar' 28import { AvatarModel } from '../avatar/avatar'
30import { VideoPlaylistModel } from '../video/video-playlist' 29import { VideoPlaylistModel } from '../video/video-playlist'
30import { WEBSERVER } from '../../initializers/constants'
31 31
32export enum ScopeNames { 32export enum ScopeNames {
33 SUMMARY = 'SUMMARY' 33 SUMMARY = 'SUMMARY'
@@ -199,7 +199,7 @@ export class AccountModel extends Model<AccountModel> {
199 static loadByNameWithHost (nameWithHost: string) { 199 static loadByNameWithHost (nameWithHost: string) {
200 const [ accountName, host ] = nameWithHost.split('@') 200 const [ accountName, host ] = nameWithHost.split('@')
201 201
202 if (!host || host === CONFIG.WEBSERVER.HOST) return AccountModel.loadLocalByName(accountName) 202 if (!host || host === WEBSERVER.HOST) return AccountModel.loadLocalByName(accountName)
203 203
204 return AccountModel.loadByNameAndHost(accountName, host) 204 return AccountModel.loadByNameAndHost(accountName, host)
205 } 205 }