|
|
@ -43,8 +43,7 @@ module.exports = function (Posts) {
|
|
|
|
'tid': tid,
|
|
|
|
'tid': tid,
|
|
|
|
'content': content,
|
|
|
|
'content': content,
|
|
|
|
'timestamp': timestamp,
|
|
|
|
'timestamp': timestamp,
|
|
|
|
'deleted': 0,
|
|
|
|
'deleted': 0
|
|
|
|
'isMain': isMain
|
|
|
|
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
if (data.toPid) {
|
|
|
|
if (data.toPid) {
|
|
|
@ -108,6 +107,7 @@ module.exports = function (Posts) {
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
function (postData, next) {
|
|
|
|
function (postData, next) {
|
|
|
|
|
|
|
|
postData.isMain = isMain;
|
|
|
|
plugins.fireHook('action:post.save', _.clone(postData));
|
|
|
|
plugins.fireHook('action:post.save', _.clone(postData));
|
|
|
|
next(null, postData);
|
|
|
|
next(null, postData);
|
|
|
|
}
|
|
|
|
}
|
|
|
|