Make go2rtc supported streams a frozenset (#127439)

Avoids the linear search of the tuple
pull/127448/head
J. Nick Koston 2024-10-03 08:08:17 -05:00 committed by GitHub
parent 49882112ac
commit 7cd4f78767
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 28 additions and 26 deletions

View File

@ -15,32 +15,34 @@ from homeassistant.helpers.aiohttp_client import async_get_clientsession
from .const import CONF_BINARY
from .server import Server
_SUPPORTED_STREAMS = (
"bubble",
"dvrip",
"expr",
"ffmpeg",
"gopro",
"homekit",
"http",
"https",
"httpx",
"isapi",
"ivideon",
"kasa",
"nest",
"onvif",
"roborock",
"rtmp",
"rtmps",
"rtmpx",
"rtsp",
"rtsps",
"rtspx",
"tapo",
"tcp",
"webrtc",
"webtorrent",
_SUPPORTED_STREAMS = frozenset(
(
"bubble",
"dvrip",
"expr",
"ffmpeg",
"gopro",
"homekit",
"http",
"https",
"httpx",
"isapi",
"ivideon",
"kasa",
"nest",
"onvif",
"roborock",
"rtmp",
"rtmps",
"rtmpx",
"rtsp",
"rtsps",
"rtspx",
"tapo",
"tcp",
"webrtc",
"webtorrent",
)
)