aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/lib
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-04-26 16:11:38 +0200
committerChocobozzz <me@florianbigard.com>2018-04-26 16:18:01 +0200
commit08c1efbe32244c321de28b0f2a6aaa3f99f46b58 (patch)
tree10a1b6c12f3e30a20f3d0dd66c698d9bae2aa41f /server/lib
parent7de6afdf542da6968d3f412df9c3318ba19ad229 (diff)
downloadPeerTube-08c1efbe32244c321de28b0f2a6aaa3f99f46b58.tar.gz
PeerTube-08c1efbe32244c321de28b0f2a6aaa3f99f46b58.tar.zst
PeerTube-08c1efbe32244c321de28b0f2a6aaa3f99f46b58.zip
Add video channel management
Diffstat (limited to 'server/lib')
-rw-r--r--server/lib/user.ts4
-rw-r--r--server/lib/video-channel.ts2
2 files changed, 3 insertions, 3 deletions
diff --git a/server/lib/user.ts b/server/lib/user.ts
index d019c4e71..51050de9b 100644
--- a/server/lib/user.ts
+++ b/server/lib/user.ts
@@ -17,9 +17,9 @@ async function createUserAccountAndChannel (userToCreate: UserModel, validateUse
17 const userCreated = await userToCreate.save(userOptions) 17 const userCreated = await userToCreate.save(userOptions)
18 const accountCreated = await createLocalAccountWithoutKeys(userToCreate.username, userToCreate.id, null, t) 18 const accountCreated = await createLocalAccountWithoutKeys(userToCreate.username, userToCreate.id, null, t)
19 19
20 const videoChannelName = `Default ${userCreated.username} channel` 20 const videoChannelDisplayName = `Default ${userCreated.username} channel`
21 const videoChannelInfo = { 21 const videoChannelInfo = {
22 name: videoChannelName 22 displayName: videoChannelDisplayName
23 } 23 }
24 const videoChannel = await createVideoChannel(videoChannelInfo, accountCreated, t) 24 const videoChannel = await createVideoChannel(videoChannelInfo, accountCreated, t)
25 25
diff --git a/server/lib/video-channel.ts b/server/lib/video-channel.ts
index 9f7ed9297..600316cda 100644
--- a/server/lib/video-channel.ts
+++ b/server/lib/video-channel.ts
@@ -14,7 +14,7 @@ async function createVideoChannel (videoChannelInfo: VideoChannelCreate, account
14 const actorInstanceCreated = await actorInstance.save({ transaction: t }) 14 const actorInstanceCreated = await actorInstance.save({ transaction: t })
15 15
16 const videoChannelData = { 16 const videoChannelData = {
17 name: videoChannelInfo.name, 17 name: videoChannelInfo.displayName,
18 description: videoChannelInfo.description, 18 description: videoChannelInfo.description,
19 support: videoChannelInfo.support, 19 support: videoChannelInfo.support,
20 accountId: account.id, 20 accountId: account.id,