From 938022a0f70fe2ace34d4a1c1b1364e90585cb4b Mon Sep 17 00:00:00 2001 From: barisusakli Date: Thu, 12 Jan 2017 14:32:28 +0300 Subject: [PATCH] add postData to action:post.delete, closes #5360 --- src/posts/delete.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/posts/delete.js b/src/posts/delete.js index d3f02a95da..a21f2bb81b 100644 --- a/src/posts/delete.js +++ b/src/posts/delete.js @@ -29,6 +29,7 @@ module.exports = function (Posts) { topics.getTopicFields(_post.tid, ['tid', 'cid', 'pinned'], next); }, function (topicData, next) { + postData.cid = topicData.cid; async.parallel([ function (next) { updateTopicTimestamp(topicData, next); @@ -42,7 +43,7 @@ module.exports = function (Posts) { ], next); }, function (results, next) { - plugins.fireHook('action:post.delete', {pid: pid, uid: uid}); + plugins.fireHook('action:post.delete', {post: _.clone(postData), uid: uid}); next(null, postData); } ], callback);