diff --git a/homeassistant/components/danfoss_air/binary_sensor.py b/homeassistant/components/danfoss_air/binary_sensor.py index d5aab8b35bb121..caac12c1b204bc 100644 --- a/homeassistant/components/danfoss_air/binary_sensor.py +++ b/homeassistant/components/danfoss_air/binary_sensor.py @@ -1,4 +1,6 @@ """Support for the for Danfoss Air HRV binary sensors.""" +from pydanfossair.commands import ReadCommand + from homeassistant.components.binary_sensor import BinarySensorDevice from . import DOMAIN as DANFOSS_AIR_DOMAIN @@ -6,8 +8,6 @@ def setup_platform(hass, config, add_entities, discovery_info=None): """Set up the available Danfoss Air sensors etc.""" - from pydanfossair.commands import ReadCommand - data = hass.data[DANFOSS_AIR_DOMAIN] sensors = [ diff --git a/homeassistant/components/danfoss_air/sensor.py b/homeassistant/components/danfoss_air/sensor.py index 73305d5c6251b0..f03c74ae78b88d 100644 --- a/homeassistant/components/danfoss_air/sensor.py +++ b/homeassistant/components/danfoss_air/sensor.py @@ -1,6 +1,8 @@ """Support for the for Danfoss Air HRV sensors.""" import logging +from pydanfossair.commands import ReadCommand + from homeassistant.const import ( DEVICE_CLASS_BATTERY, DEVICE_CLASS_HUMIDITY, @@ -17,8 +19,6 @@ def setup_platform(hass, config, add_entities, discovery_info=None): """Set up the available Danfoss Air sensors etc.""" - from pydanfossair.commands import ReadCommand - data = hass.data[DANFOSS_AIR_DOMAIN] sensors = [ diff --git a/homeassistant/components/danfoss_air/switch.py b/homeassistant/components/danfoss_air/switch.py index 8a1e0f9c746e83..96e363951c8264 100644 --- a/homeassistant/components/danfoss_air/switch.py +++ b/homeassistant/components/danfoss_air/switch.py @@ -1,6 +1,8 @@ """Support for the for Danfoss Air HRV sswitches.""" import logging +from pydanfossair.commands import ReadCommand, UpdateCommand + from homeassistant.components.switch import SwitchDevice from . import DOMAIN as DANFOSS_AIR_DOMAIN @@ -10,8 +12,6 @@ def setup_platform(hass, config, add_entities, discovery_info=None): """Set up the Danfoss Air HRV switch platform.""" - from pydanfossair.commands import ReadCommand, UpdateCommand - data = hass.data[DANFOSS_AIR_DOMAIN] switches = [