Skip to content

Commit

Permalink
Remove unused imports
Browse files Browse the repository at this point in the history
  • Loading branch information
iMicknl committed Jul 21, 2020
1 parent 4884a5f commit bf410ec
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 11 deletions.
2 changes: 1 addition & 1 deletion custom_components/tahoma/binary_sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
BinarySensorEntity,
)

from .const import DOMAIN, TAHOMA_TYPES
from .const import DOMAIN
from .tahoma_device import TahomaDevice

SCAN_INTERVAL = timedelta(seconds=120)
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tahoma/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from .climate_aeh import AtlanticElectricalHeater
from .climate_st import SomfyThermostat
from .const import DOMAIN, TAHOMA_TYPES
from .const import DOMAIN

AEH = "AtlanticElectricalHeater"
ST = "SomfyThermostat"
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tahoma/const.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

DOMAIN = "tahoma"

# Used to map the Somfy uiClass to the Home Assistant platform
# Used to map the Somfy widget and uiClass to the Home Assistant platform
TAHOMA_TYPES = {
"Light": "light",
"ExteriorScreen": "cover",
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tahoma/cover.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
CoverEntity,
)

from .const import DOMAIN, TAHOMA_TYPES
from .const import DOMAIN
from .switch import COMMAND_CYCLE
from .tahoma_device import TahomaDevice

Expand Down
2 changes: 1 addition & 1 deletion custom_components/tahoma/light.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
from homeassistant.const import STATE_ON
import homeassistant.util.color as color_util

from .const import COMMAND_OFF, COMMAND_ON, CORE_ON_OFF_STATE, DOMAIN, TAHOMA_TYPES
from .const import COMMAND_OFF, COMMAND_ON, CORE_ON_OFF_STATE, DOMAIN
from .tahoma_device import TahomaDevice

_LOGGER = logging.getLogger(__name__)
Expand Down
5 changes: 1 addition & 4 deletions custom_components/tahoma/lock.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
from homeassistant.components.lock import LockEntity
from homeassistant.const import STATE_LOCKED

from .const import DOMAIN, TAHOMA_TYPES
from .tahoma_device import TahomaDevice

_LOGGER = logging.getLogger(__name__)
Expand All @@ -25,9 +24,7 @@ async def async_setup_entry(hass, entry, async_add_entities):
controller = data.get("controller")

entities = [
TahomaLock(device, controller)
for device in data.get("devices")
if TAHOMA_TYPES[device.ui_class] == "lock"
TahomaLock(device, controller) for device in data.get("entities").get("lock")
]

async_add_entities(entities)
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tahoma/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
)
from homeassistant.helpers.entity import Entity

from .const import DOMAIN, TAHOMA_TYPES
from .const import DOMAIN
from .tahoma_device import TahomaDevice

_LOGGER = logging.getLogger(__name__)
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tahoma/switch.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from homeassistant.components.switch import DEVICE_CLASS_SWITCH, SwitchEntity
from homeassistant.const import STATE_ON

from .const import COMMAND_OFF, COMMAND_ON, CORE_ON_OFF_STATE, DOMAIN, TAHOMA_TYPES
from .const import COMMAND_OFF, COMMAND_ON, CORE_ON_OFF_STATE, DOMAIN
from .tahoma_device import TahomaDevice

_LOGGER = logging.getLogger(__name__)
Expand Down

0 comments on commit bf410ec

Please sign in to comment.