camelCased get_latest_undeleted_pid method

v1.18.x
Julian Lam 12 years ago
parent 2366e2b209
commit c940ce3329

@ -128,7 +128,7 @@ var RDB = require('./redis.js'),
});
// Delete the thread if it is the last undeleted post
threadTools.get_latest_undeleted_pid(postData.tid, function(err, pid) {
threadTools.getLatestUndeletedPid(postData.tid, function(err, pid) {
if (err && err.message === 'no-undeleted-pids-found') {
threadTools.delete(postData.tid, -1, function(err) {
if (err) winston.error('Could not delete topic (tid: ' + postData.tid + ')', err.stack);
@ -164,7 +164,7 @@ var RDB = require('./redis.js'),
pid: pid
});
threadTools.get_latest_undeleted_pid(postData.tid, function(err, pid) {
threadTools.getLatestUndeletedPid(postData.tid, function(err, pid) {
posts.getPostField(pid, 'timestamp', function(timestamp) {
topics.updateTimestamp(postData.tid, timestamp);
});

@ -297,7 +297,7 @@ var RDB = require('./redis.js'),
});
}
ThreadTools.get_latest_undeleted_pid = function(tid, callback) {
ThreadTools.getLatestUndeletedPid = function(tid, callback) {
RDB.lrange('tid:' + tid + ':posts', 0, -1, function(err, pids) {
if (pids.length === 0) return callback(new Error('no-undeleted-pids-found'));

@ -572,7 +572,7 @@ schema = require('./schema.js'),
}
Topics.getTeaser = function(tid, callback) {
threadTools.get_latest_undeleted_pid(tid, function(err, pid) {
threadTools.getLatestUndeletedPid(tid, function(err, pid) {
if (!err) {
posts.getPostFields(pid, ['content', 'uid', 'timestamp'], function(postData) {

Loading…
Cancel
Save