mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
closes #4810
This commit is contained in:
@@ -73,17 +73,7 @@ SocketPosts.getRawPost = function(socket, pid, callback) {
|
||||
};
|
||||
|
||||
SocketPosts.getPost = function(socket, pid, callback) {
|
||||
async.waterfall([
|
||||
function(next) {
|
||||
apiController.getObjectByType(socket.uid, 'post', pid, next);
|
||||
},
|
||||
function(postData, next) {
|
||||
if (parseInt(postData.deleted, 10) === 1) {
|
||||
return next(new Error('[[error:no-post]]'));
|
||||
}
|
||||
next(null, postData);
|
||||
}
|
||||
], callback);
|
||||
apiController.getPostData(pid, socket.uid, callback);
|
||||
};
|
||||
|
||||
SocketPosts.loadMoreFavourites = function(socket, data, callback) {
|
||||
|
||||
Reference in New Issue
Block a user