mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-06-24 13:50:05 +02:00
crash fix
This commit is contained in:
@@ -61,6 +61,9 @@ module.exports = function(Topics) {
|
||||
return callback(err);
|
||||
}
|
||||
var teasers = topics.map(function(topic, index) {
|
||||
if (!topic) {
|
||||
return null;
|
||||
}
|
||||
if (tidToPost[topic.tid]) {
|
||||
tidToPost[topic.tid].index = counts[index];
|
||||
if (tidToPost[topic.tid].content) {
|
||||
@@ -109,4 +112,4 @@ module.exports = function(Topics) {
|
||||
Topics.setTopicField(tid, 'teaserPid', pid, callback);
|
||||
});
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user