Skip to content
Snippets Groups Projects
Commit 2b9fbd0f authored by robban64's avatar robban64
Browse files

add: protected route for sockets

parent 0ae34deb
No related branches found
No related tags found
1 merge request!115Resolve "Add authorization to socketio"
......@@ -39,7 +39,7 @@ def protect_route(allowed_views=None):
claims = get_jwt_claims()
view = claims.get("view")
if not _is_allowed(allowed_views, view):
logger.warning(f"View {view} is not allowed to access route only accessible by {allowed_views}")
logger.warning(f"View '{view}' is not allowed to access route only accessible by '{allowed_views}'")
return
return func(*args, **kwargs)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment