Call add_user more often

- Ensures add_user is called as part of startup *for all users*.
  This was previously only true for users not already in the db.
- Normalize usernames in whitelist and admin sets
- Call add_user on new users logged in when there is no whitelist.
This commit is contained in:
Min RK
2016-03-08 10:49:02 +01:00
parent a0501c6ee4
commit 96269fac0f
3 changed files with 23 additions and 13 deletions

View File

@@ -200,6 +200,7 @@ class BaseHandler(RequestHandler):
self.db.add(u)
self.db.commit()
user = self._user_from_orm(u)
self.authenticator.add_user(user)
return user
def clear_login_cookie(self, name=None):