These are chat archives for Automattic/mongoose

9th
Feb 2019
Paul "Joey" Clark
@joeytwiddle
Feb 09 05:12
@Nqsty Perhaps in your two places, one object comes from DB, and one was just created in memory?
Normally when you fetch from the DB, you will always get the ObjectId, unless you use .populate('item') to get the full object.
If you want item to be an object, then use populate
Sascha Gaspar
@Palando
Feb 09 16:53
Hello. When I have a schema with two discriminator kinds (subtypes), is it possible to change a document from one kind to the other?