minor redis adjustments
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2020-11-28 20:17:17 +01:00
parent 791003f89e
commit 73c1636063
7 changed files with 38 additions and 2 deletions

View File

@@ -7,6 +7,8 @@ __copyright__ = "Copyright 2020, onSpot Team"
__module_name__ = "singlelistapi"
__version__text__ = "1"
from datetime import timedelta
import musicbrainzngs
from flask import request, current_app, abort
@@ -25,6 +27,7 @@ class SingleListApi(APIInteractionResource):
except Exception as e:
current_app.logger.info(e)
abort(401, "unauthorized")
flaskred.expire(request.headers.get('Authorization'), timedelta(minutes=15))
try:
list_type = flaskred.get(listid).decode('UTF-8')
except Exception as e: