Просмотр исходного кода

type conversion of string to ObjectId

shinoka7 6 лет назад
Родитель
Сommit
91f7bb3b30
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      src/server/models/comment.js

+ 1 - 1
src/server/models/comment.js

@@ -29,7 +29,7 @@ module.exports = function(crowi) {
       newComment.comment = comment;
       newComment.comment = comment;
       newComment.commentPosition = position;
       newComment.commentPosition = position;
       newComment.isMarkdown = isMarkdown || false;
       newComment.isMarkdown = isMarkdown || false;
-      newComment.replyTo = replyTo;
+      newComment.replyTo = ObjectId(replyTo);
 
 
       newComment.save((err, data) => {
       newComment.save((err, data) => {
         if (err) {
         if (err) {