From 57cfff78858b2360d9e038e2a504b761cb51da47 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 31 May 2019 14:02:26 +0200 Subject: Remove unused actor uuid field --- server/controllers/api/users/index.ts | 3 +-- server/controllers/api/video-channel.ts | 11 +++++------ 2 files changed, 6 insertions(+), 8 deletions(-) (limited to 'server/controllers') diff --git a/server/controllers/api/users/index.ts b/server/controllers/api/users/index.ts index a04f77841..2e03587ce 100644 --- a/server/controllers/api/users/index.ts +++ b/server/controllers/api/users/index.ts @@ -190,8 +190,7 @@ async function createUser (req: express.Request, res: express.Response) { user: { id: user.id, account: { - id: account.id, - uuid: account.Actor.uuid + id: account.id } } }).end() diff --git a/server/controllers/api/video-channel.ts b/server/controllers/api/video-channel.ts index 3d6dbfe70..c98a39be2 100644 --- a/server/controllers/api/video-channel.ts +++ b/server/controllers/api/video-channel.ts @@ -143,15 +143,14 @@ async function addVideoChannel (req: express.Request, res: express.Response) { }) setAsyncActorKeys(videoChannelCreated.Actor) - .catch(err => logger.error('Cannot set async actor keys for account %s.', videoChannelCreated.Actor.uuid, { err })) + .catch(err => logger.error('Cannot set async actor keys for account %s.', videoChannelCreated.Actor.url, { err })) auditLogger.create(getAuditIdFromRes(res), new VideoChannelAuditView(videoChannelCreated.toFormattedJSON())) - logger.info('Video channel with uuid %s created.', videoChannelCreated.Actor.uuid) + logger.info('Video channel %s created.', videoChannelCreated.Actor.url) return res.json({ videoChannel: { - id: videoChannelCreated.id, - uuid: videoChannelCreated.Actor.uuid + id: videoChannelCreated.id } }).end() } @@ -180,7 +179,7 @@ async function updateVideoChannel (req: express.Request, res: express.Response) new VideoChannelAuditView(videoChannelInstanceUpdated.toFormattedJSON()), oldVideoChannelAuditKeys ) - logger.info('Video channel with name %s and uuid %s updated.', videoChannelInstance.name, videoChannelInstance.Actor.uuid) + logger.info('Video channel %s updated.', videoChannelInstance.Actor.url) }) } catch (err) { logger.debug('Cannot update the video channel.', { err }) @@ -205,7 +204,7 @@ async function removeVideoChannel (req: express.Request, res: express.Response) await videoChannelInstance.destroy({ transaction: t }) auditLogger.delete(getAuditIdFromRes(res), new VideoChannelAuditView(videoChannelInstance.toFormattedJSON())) - logger.info('Video channel with name %s and uuid %s deleted.', videoChannelInstance.name, videoChannelInstance.Actor.uuid) + logger.info('Video channel %s deleted.', videoChannelInstance.Actor.url) }) return res.type('json').status(204).end() -- cgit v1.2.3