recent replies part 2

This commit is contained in:
psychobunny
2013-05-24 12:46:19 -04:00
parent 55c704c6f9
commit 448673b141
6 changed files with 111 additions and 70 deletions

View File

@@ -259,7 +259,11 @@ var RDB = require('./redis.js'),
});
}
Categories.getRecentReplies = function(cid, callback) {
RDB.zrange('categories:recent_posts:cid:' + cid, 0, -1, function(err, replies) {
callback(replies);
});
}
Categories.getCategories = function(cids, callback, current_user) {
if (cids.length === 0) {