mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-11 16:35:47 +01:00
closes #5086
This commit is contained in:
@@ -89,10 +89,13 @@ SocketHelpers.sendNotificationToPostOwner = function (pid, fromuid, command, not
|
|||||||
},
|
},
|
||||||
function (_postData, next) {
|
function (_postData, next) {
|
||||||
postData = _postData;
|
postData = _postData;
|
||||||
privileges.posts.can('read', pid, postData.uid, next);
|
async.parallel({
|
||||||
|
canRead: async.apply(privileges.posts.can, 'read', pid, postData.uid),
|
||||||
|
isIgnoring: async.apply(topics.isIgnoring, [postData.tid], postData.uid),
|
||||||
|
}, next);
|
||||||
},
|
},
|
||||||
function (canRead, next) {
|
function (results, next) {
|
||||||
if (!canRead || !postData.uid || fromuid === parseInt(postData.uid, 10)) {
|
if (!results.canRead || results.isIgnoring[0] || !postData.uid || fromuid === parseInt(postData.uid, 10)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
async.parallel({
|
async.parallel({
|
||||||
|
|||||||
Reference in New Issue
Block a user