mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-01 19:46:01 +01:00
feat: pass modified params, only affects filter hooks
This commit is contained in:
@@ -99,7 +99,7 @@ Hooks.fire = async function (hook, params) {
|
|||||||
const result = await hookTypeToMethod[hookType](hook, hookList, params);
|
const result = await hookTypeToMethod[hookType](hook, hookList, params);
|
||||||
|
|
||||||
if (hook !== 'action:plugins.firehook') {
|
if (hook !== 'action:plugins.firehook') {
|
||||||
Hooks.fire('action:plugins.firehook', { hook: hook, params: params });
|
Hooks.fire('action:plugins.firehook', { hook: hook, params: result || params });
|
||||||
}
|
}
|
||||||
if (result !== undefined) {
|
if (result !== undefined) {
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
Reference in New Issue
Block a user