Node.js based forum software built for the modern web
added filter:teasers.get
barisusakli7dde2295178e
diff --git a/src/topics/teaser.js b/src/topics/teaser.jsindex 0d67ad6360..adb4f77b5c 100644--- a/src/topics/teaser.js+++ b/src/topics/teaser.js@@ -7,6 +7,7 @@ var async = require('async'),db = require('../database'),user = require('../user'),posts = require('../posts'),+ plugins = require('../plugins'),utils = require('../../public/src/utils');@@ -61,7 +62,9 @@ module.exports = function(Topics) {return tidToPost[topic.tid];});- callback(null, teasers);+ plugins.fireHook('filter:teasers.get', {teasers: teasers}, function(err, data) {+ callback(err, data ? data.teasers : null);+ });});});};