From ef107732026525472540410df5a38b715727aa2a Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Thu, 26 Aug 2021 17:02:49 -0500 Subject: [PATCH] Fix creation of new nmap tracker entities (#55297) --- homeassistant/components/nmap_tracker/__init__.py | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/homeassistant/components/nmap_tracker/__init__.py b/homeassistant/components/nmap_tracker/__init__.py index 78465fbe91d..dfd8987484c 100644 --- a/homeassistant/components/nmap_tracker/__init__.py +++ b/homeassistant/components/nmap_tracker/__init__.py @@ -361,13 +361,6 @@ class NmapDeviceScanner: continue formatted_mac = format_mac(mac) - new = formatted_mac not in devices.tracked - if ( - new - and formatted_mac not in devices.tracked - and formatted_mac not in self._known_mac_addresses - ): - continue if ( devices.config_entry_owner.setdefault(formatted_mac, entry_id) @@ -382,6 +375,7 @@ class NmapDeviceScanner: formatted_mac, hostname, name, ipv4, vendor, reason, now, 0 ) + new = formatted_mac not in devices.tracked devices.tracked[formatted_mac] = device devices.ipv4_last_mac[ipv4] = formatted_mac self._last_results.append(device)