Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Dec 24, 2016 · I am currently stuck on how I could assign a user a post when they create when in the website. So basically I want to have a logged in user create a resume and then have that resume assigned to that logged in user as a created_by in the schema. Jan 04, 2014 · As Mongoose's schema option required is false by default the field optionalSubdocument logically shouldn't be required. Only when the field optionalSubdocument exists should the field optionalSubdocument.requiredField be required.