mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-07 17:26:32 +00:00
Fix: Websocket detection case sensitive (#1040)
This commit is contained in:
parent
0da924f10b
commit
3ed7cbe2ed
@ -209,8 +209,8 @@ def _is_websocket(request: web.Request) -> bool:
|
||||
headers = request.headers
|
||||
|
||||
if (
|
||||
headers.get(hdrs.CONNECTION) == "Upgrade"
|
||||
and headers.get(hdrs.UPGRADE) == "websocket"
|
||||
headers.get(hdrs.CONNECTION, "").lower() == "upgrade"
|
||||
and headers.get(hdrs.UPGRADE, "").lower() == "websocket"
|
||||
):
|
||||
return True
|
||||
return False
|
||||
|
Loading…
x
Reference in New Issue
Block a user