From 7be4fb4bfa6d85af6acb4bd1ca4c201530dd488f Mon Sep 17 00:00:00 2001 From: Jenny Date: Fri, 2 Oct 2020 09:57:56 +0100 Subject: [PATCH] Fix broken live attribute (#9) --- 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 d03c95d..525af68 100644 --- a/custom_components/youtube/sensor.py +++ b/custom_components/youtube/sensor.py @@ -119,7 +119,7 @@ async def is_live(channel_id, name, hass, session): async with async_timeout.timeout(10, loop=hass.loop): response = await session.get(url) info = await response.text() - if 'live-promo' in info: + if 'BADGE_STYLE_TYPE_LIVE_NOW' in info: returnvalue = True _LOGGER.debug('%s - Channel is live', name) except Exception as error: # pylint: disable=broad-except