recent replies needs stripTags true

changed [self] to _
v1.18.x
barisusakli 10 years ago
parent 6eef866320
commit 15c2b124e3

@ -269,8 +269,8 @@ var socket,
selector = selector || $('a');
selector.each(function() {
var href = $(this).attr('href');
if (href && app.userslug) {
$(this).attr('href', href.replace(/\[self\]/g, app.userslug));
if (href && app.userslug && href.indexOf('_') !== -1) {
$(this).attr('href', href.replace(/_/g, app.userslug));
}
});
};

@ -17,9 +17,17 @@ module.exports = function(Categories) {
return callback(null, []);
}
posts.getPostsFromSet('cid:' + cid + ':pids', uid, 0, count - 1, function(err, data) {
callback(err, data ? data.posts : []);
});
async.waterfall([
function(next) {
db.getSortedSetRevRange('cid:' + cid + ':pids', 0, count - 1, next);
},
function(pids, next) {
privileges.posts.filter('read', pids, uid, next);
},
function(pids, next) {
posts.getPostSummaryByPids(pids, uid, {stripTags: true}, next);
}
], callback);
};
Categories.getRecentTopicReplies = function(categoryData, uid, callback) {

Loading…
Cancel
Save