I have the following mongoose schema records:
var mongoose = require('mongoose');
module.exports = mongoose.model('lM', {
any : mongoose.Schema.Types.Mixed,
},'mlr');
And in my code I am doing as such:
var lm = require('../server/models/records');
new lm().save(lmr);
Being that lmr is a JSON object.
This produces a mongodb database with the name I provided but the records inside that collection contain only:
_id: objectID
_v: 0
The JSON objects is nowhere to be seen. How can I get the JSON object inside the any wrapper in the schema?