mirror of
				https://github.com/NodeBB/NodeBB.git
				synced 2025-11-03 20:45:58 +01:00 
			
		
		
		
	added back feeds, removed duplicate post var in feed
This commit is contained in:
		@@ -42,7 +42,6 @@
 | 
				
			|||||||
					author: topicData.posts[0].username,
 | 
										author: topicData.posts[0].username,
 | 
				
			||||||
					ttl: Feed.defaults.ttl
 | 
										ttl: Feed.defaults.ttl
 | 
				
			||||||
				}),
 | 
									}),
 | 
				
			||||||
				topic_posts = topicData.posts.concat(topicData.posts),
 | 
					 | 
				
			||||||
				dateStamp;
 | 
									dateStamp;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
			// Add pubDate if topic contains posts
 | 
								// Add pubDate if topic contains posts
 | 
				
			||||||
@@ -50,7 +49,7 @@
 | 
				
			|||||||
				feed.pubDate = new Date(parseInt(topicData.posts[0].timestamp, 10)).toUTCString();
 | 
									feed.pubDate = new Date(parseInt(topicData.posts[0].timestamp, 10)).toUTCString();
 | 
				
			||||||
			}
 | 
								}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
			async.each(topic_posts, function(postData, next) {
 | 
								async.each(topicData.posts, function(postData, next) {
 | 
				
			||||||
				if (postData.deleted === '0') {
 | 
									if (postData.deleted === '0') {
 | 
				
			||||||
					dateStamp = new Date(parseInt(postData.edited === '0' ? postData.timestamp : postData.edited, 10)).toUTCString();
 | 
										dateStamp = new Date(parseInt(postData.edited === '0' ? postData.timestamp : postData.edited, 10)).toUTCString();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -85,8 +85,8 @@ var RDB = require('./redis'),
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
						var cid = topicData.cid;
 | 
											var cid = topicData.cid;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
						//feed.updateTopic(tid);
 | 
											feed.updateTopic(tid);
 | 
				
			||||||
						//feed.updateRecent();
 | 
											feed.updateRecent();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
						RDB.zadd('categories:recent_posts:cid:' + cid, timestamp, pid);
 | 
											RDB.zadd('categories:recent_posts:cid:' + cid, timestamp, pid);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user