1
0
Fork 0

Fix bad to/cc when undo dislike

This commit is contained in:
Chocobozzz 2017-11-30 14:15:17 +01:00
parent f00984c007
commit fef2c7164e
No known key found for this signature in database
GPG key ID: 583A612D890159BE
3 changed files with 4 additions and 4 deletions

View file

@ -44,7 +44,7 @@ async function inboxController (req: express.Request, res: express.Response, nex
}
// Only keep activities we are able to process
logger.debug('Filtering activities...', { activities })
logger.debug('Filtering %d activities...', activities.length)
activities = activities.filter(a => isActivityValid(a))
logger.debug('We keep %d activities.', activities.length, { activities })

View file

@ -67,9 +67,9 @@ async function sendUndoDislikeToOrigin (byAccount: AccountInstance, video: Video
const accountsInvolvedInVideo = await getAccountsInvolvedInVideo(video, t)
const audience = getOriginVideoAudience(video, accountsInvolvedInVideo)
const dislikeActivity = createDislikeActivityData(byAccount, video)
const object = await createActivityData(undoUrl, byAccount, dislikeActivity, t, audience)
const object = await createActivityData(undoUrl, byAccount, dislikeActivity, t)
const data = await undoActivityData(undoUrl, byAccount, object, t)
const data = await undoActivityData(undoUrl, byAccount, object, t, audience)
return unicastTo(data, byAccount, video.VideoChannel.Account.sharedInboxUrl, t)
}

View file

@ -7,7 +7,7 @@ const activityPubValidator = [
body('').custom((value, { req }) => isRootActivityValid(req.body)),
(req: express.Request, res: express.Response, next: express.NextFunction) => {
logger.debug('Checking activity pub parameters', { parameters: req.body })
logger.debug('Checking activity pub parameters')
if (areValidationErrors(req, res)) return