mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-02 12:05:57 +01:00
fixed conditional in posts.js
This commit is contained in:
@@ -187,7 +187,7 @@ var RDB = require('./redis'),
|
|||||||
|
|
||||||
if (pids.length) {
|
if (pids.length) {
|
||||||
plugins.fireHook('filter:post.getTopic', pids, function(err, posts) {
|
plugins.fireHook('filter:post.getTopic', pids, function(err, posts) {
|
||||||
if (!err & 0 < posts.length) {
|
if (!err && posts.length > 0) {
|
||||||
Posts.getPostsByPids(pids, function(err, posts) {
|
Posts.getPostsByPids(pids, function(err, posts) {
|
||||||
plugins.fireHook('action:post.gotTopic', posts);
|
plugins.fireHook('action:post.gotTopic', posts);
|
||||||
callback(posts);
|
callback(posts);
|
||||||
|
|||||||
Reference in New Issue
Block a user