From e8f0d80fc988d8e43bb1eff27cb45288d446f1c1 Mon Sep 17 00:00:00 2001 From: Erik Montnemery Date: Thu, 5 May 2022 08:52:20 +0200 Subject: [PATCH] Fix Meater (#71324) --- homeassistant/components/meater/sensor.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/homeassistant/components/meater/sensor.py b/homeassistant/components/meater/sensor.py index 17e8db9e473..8c719d588d8 100644 --- a/homeassistant/components/meater/sensor.py +++ b/homeassistant/components/meater/sensor.py @@ -146,13 +146,13 @@ async def async_setup_entry( if not coordinator.last_update_success: return - devices = coordinator.data + devices: dict[str, MeaterProbe] = coordinator.data entities = [] known_probes: set = hass.data[DOMAIN]["known_probes"] # Add entities for temperature probes which we've not yet seen for dev in devices: - if dev.id in known_probes: + if dev in known_probes: continue entities.extend( @@ -161,7 +161,7 @@ async def async_setup_entry( for sensor_description in SENSOR_TYPES ] ) - known_probes.add(dev.id) + known_probes.add(dev) async_add_entities(entities)