Exemplo n.º 1
0
 def reset_token(self, token):
     DataToken.get(token).delete()
Exemplo n.º 2
0
 def check_token(self, token):
     """Check that the token is valid"""
     t = DataToken.get(token)
     return t and datetime.now() <= (t.date + self.expiration_delay)
Exemplo n.º 3
0
 def reset_token(self, token):
     DataToken.get(token).delete()
Exemplo n.º 4
0
 def check_token(self, token):
     """Check that the token is valid"""
     t = DataToken.get(token)
     return t and datetime.now() <= (t.date + self.expiration_delay)
Exemplo n.º 5
0
 def check_token(self, token):
     """Check that the token is valid"""
     t = DataToken.get(token)
     return t and datetime.now() <= t.date
Exemplo n.º 6
0
 def check_token(self, token):
     """Check that the token is valid"""
     t = DataToken.get(token)
     return t and datetime.now() <= t.date