Răsfoiți Sursa

type conversion of string to ObjectId

shinoka7 6 ani în urmă
părinte
comite
91f7bb3b30
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  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.commentPosition = position;
       newComment.isMarkdown = isMarkdown || false;
-      newComment.replyTo = replyTo;
+      newComment.replyTo = ObjectId(replyTo);
 
       newComment.save((err, data) => {
         if (err) {