From 7c165876f15d6618f65a0fa41394ecb0480e24a8 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Tue, 21 May 2013 14:54:35 -0400 Subject: [PATCH] fixed bug where deleted posts still showed up in teasers --- src/topics.js | 20 +++++++++++++++++++- src/webserver.js | 4 ++-- 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/src/topics.js b/src/topics.js index b6afa9e93b..75618dc453 100644 --- a/src/topics.js +++ b/src/topics.js @@ -285,8 +285,26 @@ marked.setOptions({ } else callback([]); } + Topics.get_latest_undeleted_pid = function(tid, callback) { + RDB.lrange('tid:' + tid + ':posts', 0, -1, function(err, pids) { + var pidKeys = []; + for(var x=0,numPids=pids.length;x