aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/api/videos/channel.ts
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2017-11-20 09:43:39 +0100
committerChocobozzz <florian.bigard@gmail.com>2017-11-27 19:40:52 +0100
commit54141398354e6e7b94aa3065a705a1251390111c (patch)
tree8d30d1b9ea8acbe04f6d404125b04fc0c9897b70 /server/controllers/api/videos/channel.ts
parenteb8b27c93e61a896a08923dc1ca3c87ba8cf4948 (diff)
downloadPeerTube-54141398354e6e7b94aa3065a705a1251390111c.tar.gz
PeerTube-54141398354e6e7b94aa3065a705a1251390111c.tar.zst
PeerTube-54141398354e6e7b94aa3065a705a1251390111c.zip
Refractor activity pub lib/helpers
Diffstat (limited to 'server/controllers/api/videos/channel.ts')
-rw-r--r--server/controllers/api/videos/channel.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/server/controllers/api/videos/channel.ts b/server/controllers/api/videos/channel.ts
index 8f3df2550..ce2656e71 100644
--- a/server/controllers/api/videos/channel.ts
+++ b/server/controllers/api/videos/channel.ts
@@ -17,7 +17,7 @@ import {
17 videoChannelsUpdateValidator 17 videoChannelsUpdateValidator
18} from '../../../middlewares' 18} from '../../../middlewares'
19import { AccountInstance, VideoChannelInstance } from '../../../models' 19import { AccountInstance, VideoChannelInstance } from '../../../models'
20import { sendUpdateVideoChannel } from '../../../lib/activitypub/send-request' 20import { sendUpdateVideoChannel } from '../../../lib/activitypub/send/send-update'
21 21
22const videoChannelRouter = express.Router() 22const videoChannelRouter = express.Router()
23 23
@@ -128,9 +128,9 @@ async function updateVideoChannel (req: express.Request, res: express.Response)
128 if (videoChannelInfoToUpdate.name !== undefined) videoChannelInstance.set('name', videoChannelInfoToUpdate.name) 128 if (videoChannelInfoToUpdate.name !== undefined) videoChannelInstance.set('name', videoChannelInfoToUpdate.name)
129 if (videoChannelInfoToUpdate.description !== undefined) videoChannelInstance.set('description', videoChannelInfoToUpdate.description) 129 if (videoChannelInfoToUpdate.description !== undefined) videoChannelInstance.set('description', videoChannelInfoToUpdate.description)
130 130
131 await videoChannelInstance.save(sequelizeOptions) 131 const videoChannelInstanceUpdated = await videoChannelInstance.save(sequelizeOptions)
132 132
133 await sendUpdateVideoChannel(videoChannelInstance, t) 133 await sendUpdateVideoChannel(videoChannelInstanceUpdated, t)
134 }) 134 })
135 135
136 logger.info('Video channel with name %s and uuid %s updated.', videoChannelInstance.name, videoChannelInstance.uuid) 136 logger.info('Video channel with name %s and uuid %s updated.', videoChannelInstance.name, videoChannelInstance.uuid)