These are chat archives for Automattic/mongoose

24th
Sep 2016
Ravi Gupta
@meeravi007
Sep 24 2016 17:57
This is ny schema
category:{
_id:mongoose.Schema.Types.ObjectId,
categoryName:String,
v:Number
},
topic:{
_id:mongoose.Schema.Types.ObjectId,
topic:String,
v:Number
},
question:String,
options : [{
option:String,
correctOption:Boolean
}],
when i'm saving in db getting error CastError: Cast to Object failed for value "{"_id":"57e57f6578c50d298c171d96","topic":"NewTopic","__v":0}" at path "topic"