From abca1778948412171688137eff729ae326ae74f6 Mon Sep 17 00:00:00 2001 From: Jesse Hills <3060199+jesserockz@users.noreply.github.com> Date: Wed, 16 Sep 2020 22:22:06 +1200 Subject: [PATCH] Use device name stored in device_info for tag scan in ESPHome (#40130) --- homeassistant/components/esphome/__init__.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/homeassistant/components/esphome/__init__.py b/homeassistant/components/esphome/__init__.py index 497dc0deda8..64aae3ce522 100644 --- a/homeassistant/components/esphome/__init__.py +++ b/homeassistant/components/esphome/__init__.py @@ -133,9 +133,10 @@ async def async_setup_entry(hass: HomeAssistantType, entry: ConfigEntry) -> bool # Call native tag scan if service_name == "tag_scanned": tag_id = service_data["tag_id"] - device_id = service_data["device_id"] hass.async_create_task( - hass.components.tag.async_scan_tag(tag_id, device_id) + hass.components.tag.async_scan_tag( + tag_id, entry_data.device_info.name + ) ) return