From b40dc6c271c372648c46379d2f198c6e39e58cd3 Mon Sep 17 00:00:00 2001 From: epenet <6771947+epenet@users.noreply.github.com> Date: Tue, 30 Nov 2021 08:10:50 +0100 Subject: [PATCH] Use dataclass properties in rainmachine discovery (#60578) Co-authored-by: epenet --- homeassistant/components/rainmachine/config_flow.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/homeassistant/components/rainmachine/config_flow.py b/homeassistant/components/rainmachine/config_flow.py index 6b11e82d023..39884681967 100644 --- a/homeassistant/components/rainmachine/config_flow.py +++ b/homeassistant/components/rainmachine/config_flow.py @@ -70,7 +70,7 @@ class RainMachineFlowHandler(config_entries.ConfigFlow, domain=DOMAIN): self, discovery_info: zeroconf.ZeroconfServiceInfo ) -> FlowResult: """Handle discovery via zeroconf.""" - ip_address = discovery_info[zeroconf.ATTR_HOST] + ip_address = discovery_info.host self._async_abort_entries_match({CONF_IP_ADDRESS: ip_address}) # Handle IP change