This commit is contained in:
Baris Soner Usakli
2013-07-18 15:14:06 -04:00
parent f90eb72706
commit 285e19fbbf
3 changed files with 7 additions and 5 deletions

View File

@@ -95,6 +95,10 @@ marked.setOptions({
threadTools.delete(tid, -1, function(err) {
if (err) console.log('Error: Could not delete topic (tid: ' + tid + ')');
});
} else {
posts.getPostField(pid, 'timestamp', function(timestamp) {
topics.updateTimestamp(tid, timestamp);
});
}
});
});

View File

@@ -297,7 +297,7 @@ marked.setOptions({
topics.increasePostCount(tid);
topics.setTopicField(tid, 'lastposttime', timestamp);
topics.addToRecent(tid, timestamp);
topics.updateTimestamp(tid, timestamp);
RDB.incr('totalpostcount');
@@ -318,8 +318,6 @@ marked.setOptions({
});
});
user.onNewPostMade(uid, tid, pid, timestamp);
if (callback)

View File

@@ -450,7 +450,7 @@ marked.setOptions({
});
}
Topics.addToRecent = function(tid, timestamp) {
Topics.updateTimestamp = function(tid, timestamp) {
RDB.zadd(schema.topics().recent, timestamp, tid);
}