Remove get_device call in switchbot (#83881)

This commit is contained in:
J. Nick Koston 2022-12-12 13:51:10 -10:00 committed by GitHub
parent 938475d988
commit 9b5c5938ce
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -86,7 +86,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
address: str = entry.data[CONF_ADDRESS]
ble_device = bluetooth.async_ble_device_from_address(
hass, address.upper(), connectable
) or await switchbot.get_device(address)
)
if not ble_device:
raise ConfigEntryNotReady(
f"Could not find Switchbot {sensor_type} with address {address}"