title: Mongoose - Promise then() not triggered on save
body: <p>I'm using ExpressJS + Mongoose + TypeScript. I have created a schema as below</p>
  
  <pre><code>const schema: Schema = new Schema({
      firstName: {
          type: String,
          required: true
      },
      lastName: {
          type: String,
          required: true
      },
      email: {
          type: String,
          required: true
      },
      gender: {
          type: Boolean,
          required: true
      },
      mobile: {
          type: String,
          required: false
      },
      password: {
          type: String,
          required: true
      },
      activationKey: {
          type: String,
          required: false
      },
      isActivated: {
          type: Boolean,
          required: true
      },
      imagePath: {
          type: String,
          required: false
      },
  });
  </code></pre>
  
  <p>I'm using the below code to save (insert) a new entry</p>
  
  <pre><code>MongoClient.connect('mongodb://MyUsername:MyPassword@ds135757.mlab.com:35777/my-db-us', (err, db) =&gt; {
      if (err) {
          console.log('mongoose error: ' + err);
      } else {
          console.log('mongoose db: ' + db);
  
          const user = new User({
              firstName: 'ee',
              lastName: 'ee',
              email: 'eee@fff.com',
              gender: true,
              mobile: '333',
              password: '333',
              isActivated: true
          });
  
          user.save().then((someValue) =&gt; {
              console.log('saved');
          }).catch((err) =&gt; {
              console.log('not saved:' + err);
          });
      }
  });
  </code></pre>
  
  <p><strong>Console Messages</strong></p>
  
  <p><em>When correct data is sent. saved isn't printed</em></p>
  
  <pre><code>mongoose db: [object Object]
  </code></pre>
  
  <p><em>When incorrect data is sent</em></p>
  
  <pre><code>mongoose db: [object Object]
  not saved:ValidationError: gender: Path `gender` is required.
  </code></pre>
  
  <p><em>When unable to connect to MongoDB if internet is disconnected</em></p>
  
  <pre><code>mongoose error: MongoError: failed to connect to server [ds135777.mlab.com:35777] on first connect [MongoError: connection 0 to ds135777.mlab.com:35777 timed out]
  </code></pre>
  
  <p><strong>Module versions</strong></p>
  
  <pre><code>"mongodb": "^2.2.34",
  "@types/mongodb": "^3.0.5",
  "mongoose": "^5.0.4",
  "@types/mongoose": "^5.0.2",
  </code></pre>
  
  <hr>
  
  <p><strong>Re-written example (Solution)</strong></p>
  
  <pre><code>const mongoose = require('mongoose');
  mongoose.connect('mongodb://MyUsername:MyPassword@ds135757.mlab.com:35777/my-db-us', function(err) {
      if (err) {
          console.log('err: ' + err);
      } else {
          console.log('connected');
          const user = new User({
              firstName: 'ee',
              lastName: 'ee',
              email: 'eee@fff.com',
              gender: true,
              mobile: '333',
              password: '333',
              isActivated: true
          });
  
          user.save().then((someValue) =&gt; {
              console.log('saved');
          }).catch((err) =&gt; {
              console.log('not saved:' + err);
          });
      }
  });
  </code></pre>
  
  <p>The messages printed are </p>
  
  <pre><code>connected
  saved
  </code></pre>