Closing MongoDB connection in findOne callback

When I'm running the following code, sometimes MongoDB will error out saying Connection was destroyed by application

Is it ok to db.close() immediately in the callback?

User.findOne({ username: username }, function (err, user) {
      db.close();
      if (err) {
        console.log('local.js user findone err', err);
        return done(err);
      }

      if (!user)
        return done(null, false, { message: 'Incorrect username.' });
      bcrypt.compare(password, user.password, function (err, res) {
        if (err)
          return done(err);
        if (!res)
          return done(null, false, { message: 'Incorrect password.' });
        return done(null, user);
      });
    });
});