Node.js based forum software built for the modern web
fix: #7508
Barış Soner Uşaklıb52dba5c920a
diff --git a/src/posts/queue.js b/src/posts/queue.jsindex d2203fdc68..1a3a0dadd8 100644--- a/src/posts/queue.js+++ b/src/posts/queue.js@@ -215,7 +215,7 @@ module.exports = function (Posts) {},function (data, next) {if (!data) {- return callback();+ return callback(null, null);}try {data.data = JSON.parse(data.data);diff --git a/test/posts.js b/test/posts.jsindex 22f84c76ae..1d20bb303f 100644--- a/test/posts.js+++ b/test/posts.js@@ -928,6 +928,13 @@ describe('Post\'s', function () {},], done);});++ it('should not crash if id does not exist', function (done) {+ socketPosts.reject({ uid: globalModUid }, { id: '123123123' }, function (err) {+ assert.ifError(err);+ done();+ });+ });});describe('upload methods', function () {