mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-07 14:35:47 +01:00
fix filter condition
This commit is contained in:
@@ -244,9 +244,9 @@ var async = require('async'),
|
|||||||
}
|
}
|
||||||
|
|
||||||
topics = topics.filter(function(topic) {
|
topics = topics.filter(function(topic) {
|
||||||
return !topic.category.disabled ||
|
return !topic.category.disabled &&
|
||||||
!topic.deleted || (topic.deleted && isAdminOrMod[topic.cid]) ||
|
(!topic.deleted || (topic.deleted && isAdminOrMod[topic.cid]) ||
|
||||||
parseInt(topic.uid, 10) === parseInt(uid, 10);
|
parseInt(topic.uid, 10) === parseInt(uid, 10));
|
||||||
});
|
});
|
||||||
|
|
||||||
plugins.fireHook('filter:topics.get', topics, callback);
|
plugins.fireHook('filter:topics.get', topics, callback);
|
||||||
|
|||||||
Reference in New Issue
Block a user