Skip to content

Commit

Permalink
fix auth remote addr access
Browse files Browse the repository at this point in the history
  • Loading branch information
NickM-27 committed Dec 6, 2024
1 parent d3b631a commit 65bb997
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion frigate/api/auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,12 @@ def get_remote_addr(request: Request):
return str(ip)

# if there wasn't anything in the route, just return the default
return request.remote_addr or "127.0.0.1"
remote_addr = None

if hasattr(request, "remote_addr"):
remote_addr = request.remote_addr

return remote_addr or "127.0.0.1"


def get_jwt_secret() -> str:
Expand Down

0 comments on commit 65bb997

Please sign in to comment.