Fix need_renew

This commit is contained in:
Maël Kervella 2018-05-25 13:47:37 +00:00
parent b27e5cc92e
commit fe1ee23c7c

View file

@ -58,7 +58,7 @@ class Re2oAPIClient:
True is the token expiration time is within less than `TIME_FOR_RENEW`
seconds
"""
return self.token['expiration'] > \
return self.token['expiration'] < \
datetime.datetime.now(datetime.timezone.utc) + \
datetime.timedelta(seconds=TIME_FOR_RENEW)