fix bug where revoke check is called too often

This commit is contained in:
Jonas Weinz 2019-04-01 18:59:43 +02:00 committed by GitHub
parent c7127b88df
commit ef5696f61d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -672,7 +672,7 @@ class ConnectionHandler(object):
async def revoke_check(self): async def revoke_check(self):
now = datetime.datetime.now() now = datetime.datetime.now()
if self.lastCheck + self.revoke_check_timedelta < now: if self.lastCheck + self.revoke_check_timedelta < now:
now = datetime.datetime.now() self.lastCheck = datetime.datetime.now()
self.match_manager.check_matches_lifespan() self.match_manager.check_matches_lifespan()
self.session_manager.revoke_inactive_sessions() self.session_manager.revoke_inactive_sessions()
self.user_manager.revoke_inactive_accounts() self.user_manager.revoke_inactive_accounts()