mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-03-12 15:41:01 +01:00
add filter:search.filterAndSort
This commit is contained in:
@@ -122,7 +122,10 @@ function filterAndSort(pids, data, callback) {
|
||||
|
||||
sortPosts(posts, data);
|
||||
|
||||
pids = posts.map(function (post) {
|
||||
plugins.fireHook('filter:search.filterAndSort', { pids: pids, posts: posts, data: data }, next);
|
||||
},
|
||||
function (result, next) {
|
||||
pids = result.posts.map(function (post) {
|
||||
return post && post.pid;
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user