From 332cb46af543be4aa10f428b89373951003119fe Mon Sep 17 00:00:00 2001 From: Jenny Date: Mon, 19 Oct 2020 23:49:54 +0100 Subject: [PATCH] fix live attribute again (#13) --- custom_components/youtube/sensor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/custom_components/youtube/sensor.py b/custom_components/youtube/sensor.py index a14fad2..e49d2dc 100644 --- a/custom_components/youtube/sensor.py +++ b/custom_components/youtube/sensor.py @@ -117,7 +117,7 @@ async def is_live(url, name, hass, session): async with async_timeout.timeout(10, loop=hass.loop): response = await session.get(url) info = await response.text() - if '{"key":"is_viewed_live","value":"True"}' in info: + if 'Started streaming' in info: returnvalue = True _LOGGER.debug('%s - Latest Video is live', name) except Exception as error: # pylint: disable=broad-except