mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-13 17:35:46 +01:00
refactor: move plugin hook methods to plugin.hooks.*
This commit is contained in:
@@ -144,7 +144,7 @@ module.exports = function (Posts) {
|
||||
current = 'unvote';
|
||||
}
|
||||
|
||||
plugins.fireHook('action:post.' + hook, {
|
||||
plugins.hooks.fire('action:post.' + hook, {
|
||||
pid: pid,
|
||||
uid: uid,
|
||||
owner: owner,
|
||||
@@ -251,7 +251,7 @@ module.exports = function (Posts) {
|
||||
downvotes: postData.downvotes,
|
||||
}),
|
||||
]);
|
||||
plugins.fireHook('action:post.updatePostVoteCount', { post: postData });
|
||||
plugins.hooks.fire('action:post.updatePostVoteCount', { post: postData });
|
||||
};
|
||||
|
||||
async function updateTopicVoteCount(postData) {
|
||||
|
||||
Reference in New Issue
Block a user