maxcountryman/flask-login — pull request #162 by djmitche (2014-07-10 18:35:15+00:00)
Title: user_logged_out is never sent

This code runs after the session is purged:
```
user = _get_user()
if user is not None and not user.is_anonymous():
user_logged_out.send(current_app._get_current_object(), user=user)
```
so assuming the very common case that an empty session means an anonymous user, the `user_logged_out` signal is not sent.

In the much less common case of an empty session representing a non-anonymous user, the signal is sent, yet in that case it's inaccurate (the user isn't anonymous, and therefore isn't logged out).

I think the logic should be reversed: `if user is None or user.is_anonynmous()`