jaredhanson/passport — pull request #150 by luman75 (2013-06-19 11:02:52+00:00)
Title: Deserialize user might need to handle logout.

There are situations sometimes when user deserialize function might detect problems with current information in cookies and wants to logout user. Becouse there is limited access to req we introduced additional attribue to err object called 'passportLogout'. If this attribute it set to the err object session error handler simply cleans the current session.

Example of usage:
```
passportDeserializeUser = function(id, done) {
return findById(id, function(err, user) {
if (err) {
err.passportLogout = true;
}
return done(err, user);
});
};

```