user: hash email key for User.get_by_email() fixes #4132

This commit is contained in:
Daniel Dourvaris 2016-07-28 09:19:07 +03:00
parent 708038952c
commit 391379c4ab

View file

@ -721,7 +721,7 @@ class User(Base, BaseModel):
if cache:
q = q.options(FromCache("sql_cache_short",
"get_email_key_%s" % email))
"get_email_key_%s" % _hash_key(email)))
ret = q.scalar()
if ret is None: