title: Mongoose nested schema only save value of document without including the nested object
body: <p>Im trying to add a key to specify if mobile number and email address has been verified, but when I save it to the database, there is no verified but only the value of email address and mobile number, how do i add the verified object into it? or is there better method to tell whether mobile number and email has been verified?</p>
  <pre><code>    const mongoose = require(&quot;mongoose&quot;); 
      const UserSchema = mongoose.Schema({   username:{
      type: String,
      required: true,
      unique: [true,'Sorry username is taken please try another']   },
      phone: {
      verified:{
        type: Boolean,
        default: false
      },
      number:{
        type: String,
        required: true,
        unique: [true,'Mobile already registered']
      },
      type: Array
      },   
      email: {
      verified:{
        type: Boolean,
        default: false
      },
      address:{
        type: String,
        required: true,
        unique: [true,'Email already registered']
      },
      type: Array   },
      dateCreated: {
      type: Date,
      default: Date.now()   } }) 
      module.exports = mongoose.model(&quot;users&quot;, UserSchema);
  </code></pre>