mongoose.Types.ObjectId is the ObjectId constructor function, what you want to use in schema definitions is mongoose.Schema.Types.
確定! 回上一頁