feat: add post to hook params

isekai-main
Barış Soner Uşaklı 3 years ago
parent 03453a620f
commit f07b4484cf

@ -40,7 +40,12 @@ async function notifyUids(uid, uids, type, result) {
uids = filterTidCidIgnorers(watchStateUids, watchStates);
uids = await user.blocks.filterUids(uid, uids);
uids = await user.blocks.filterUids(post.topic.uid, uids);
const data = await plugins.hooks.fire('filter:sockets.sendNewPostToUids', { uidsTo: uids, uidFrom: uid, type: type });
const data = await plugins.hooks.fire('filter:sockets.sendNewPostToUids', {
uidsTo: uids,
uidFrom: uid,
type: type,
post: post,
});
post.ip = undefined;

Loading…
Cancel
Save