mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-02-25 18:55:32 -06:00
Add filter hooks tests
This commit is contained in:
@@ -210,13 +210,15 @@ async function isVideoCommentAccepted (req: express.Request, res: express.Respon
|
||||
if (isReply) {
|
||||
const acceptReplyParameters = Object.assign(acceptParameters, { parentComment: res.locals.videoComment })
|
||||
|
||||
acceptedResult = await Hooks.wrapObject(
|
||||
isLocalVideoCommentReplyAccepted(acceptReplyParameters),
|
||||
acceptedResult = await Hooks.wrapFun(
|
||||
isLocalVideoCommentReplyAccepted,
|
||||
acceptReplyParameters,
|
||||
'filter:api.video-comment-reply.create.accept.result'
|
||||
)
|
||||
} else {
|
||||
acceptedResult = await Hooks.wrapObject(
|
||||
isLocalVideoThreadAccepted(acceptParameters),
|
||||
acceptedResult = await Hooks.wrapFun(
|
||||
isLocalVideoThreadAccepted,
|
||||
acceptParameters,
|
||||
'filter:api.video-thread.create.accept.result'
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user