These are chat archives for Automattic/mongoose

Sep 2017
matthew harwood
Sep 15 2017 00:44
Paul "Joey" Clark
Sep 15 2017 09:29

My init middleware checks for certain fields and does things if they are empty.

But unfortunately if I have used .select(‘foo’) then of course most of the fields are empty!

How can I detect if I have a full document or a document that came from a .select()?

Scott Gilroy
Sep 15 2017 17:45
@joeytwiddle Use to test the path (field) you are interested in.