mirror of
				https://github.com/NodeBB/NodeBB.git
				synced 2025-11-03 20:45:58 +01:00 
			
		
		
		
	live tiles on home page, ninjaed from andrew might need to randomize starting times, can be disabled by removing the slider class from the div, maybe this should be a setting in admin/categories
This commit is contained in:
		@@ -200,6 +200,8 @@ var	RDB = require('./redis.js'),
 | 
			
		||||
		});
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	
 | 
			
		||||
 | 
			
		||||
	Categories.getModerators = function(cid, callback) {
 | 
			
		||||
		RDB.smembers('cid:' + cid + ':moderators', function(err, mods) {
 | 
			
		||||
			if (mods.length === 0)
 | 
			
		||||
@@ -274,11 +276,11 @@ var	RDB = require('./redis.js'),
 | 
			
		||||
		});	
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	Categories.getRecentReplies = function(cid, callback) {
 | 
			
		||||
		RDB.zrevrange('categories:recent_posts:cid:' + cid, 0, 4, function(err, pids) {
 | 
			
		||||
	Categories.getRecentReplies = function(cid, count, callback) {
 | 
			
		||||
		RDB.zrevrange('categories:recent_posts:cid:' + cid, 0, count, function(err, pids) {
 | 
			
		||||
 | 
			
		||||
			if (pids.length == 0) {
 | 
			
		||||
				callback(false);
 | 
			
		||||
				callback([]);
 | 
			
		||||
				return;
 | 
			
		||||
			}
 | 
			
		||||
			posts.getPostSummaryByPids(pids, function(posts) {
 | 
			
		||||
@@ -330,5 +332,7 @@ var	RDB = require('./redis.js'),
 | 
			
		||||
			});
 | 
			
		||||
		}		
 | 
			
		||||
	};
 | 
			
		||||
	
 | 
			
		||||
	
 | 
			
		||||
 | 
			
		||||
}(exports));
 | 
			
		||||
		Reference in New Issue
	
	Block a user