fix: remove lean for popluate

This commit is contained in:
Innei
2023-08-23 16:21:22 +08:00
parent 7ee1a42419
commit d4d64a2f37

View File

@@ -314,7 +314,7 @@ export class CommentService implements OnModuleInit {
const refType = comment.refType
const refModel = this.getModelByRefType(refType)
const refDoc = await refModel.findById(comment.ref).lean()
const refDoc = await refModel.findById(comment.ref)
const time = new Date(comment.created!)
const parent: CommentModel | null = await this.commentModel
.findOne({ _id: comment.parent })