Skip to content

Commit cfe428d

Browse files
committed
Fix lint
1 parent 9650ee9 commit cfe428d

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

custom_components/auto_areas/__init__.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@
1515

1616
from .const import DOMAIN, LOGGER, ISSUE_TYPE_YAML_DETECTED
1717

18-
PLATFORMS: list[Platform] = [Platform.SWITCH, Platform.BINARY_SENSOR, Platform.SENSOR]
18+
PLATFORMS: list[Platform] = [Platform.SWITCH,
19+
Platform.BINARY_SENSOR, Platform.SENSOR]
1920

2021

2122
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
@@ -36,19 +37,23 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
3637

3738
return True
3839

40+
3941
async def async_init(hass: HomeAssistant, entry: ConfigEntry, auto_area: AutoArea):
42+
"""Initialize component."""
4043
await auto_area.initialize()
4144
entry.async_on_unload(entry.add_update_listener(async_reload_entry))
4245
hass.async_create_task(
4346
hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)
4447
)
4548

49+
4650
def initialize(hass: HomeAssistant, entry: ConfigEntry, auto_area: AutoArea):
4751
"""Initialize area after HA has started."""
4852
return asyncio.run_coroutine_threadsafe(
4953
async_init(hass, entry, auto_area), hass.loop
5054
).result()
5155

56+
5257
async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
5358
"""Handle removal of an entry."""
5459
# unsubscribe from changes:

custom_components/auto_areas/auto_lights.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
"""Auto lights."""
2-
from homeassistant.core import State
32
from homeassistant.components.light import DOMAIN as LIGHT_DOMAIN
43
from homeassistant.helpers.event import async_track_state_change_event
54
from homeassistant.const import (

custom_components/auto_areas/binary_sensor.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
BinarySensorDeviceClass,
66
BinarySensorEntity,
77
)
8-
from homeassistant.core import State
98
from homeassistant.helpers.event import async_track_state_change_event
109
from homeassistant.helpers.entity_platform import AddEntitiesCallback
1110
from homeassistant.helpers.entity import DeviceInfo

custom_components/auto_areas/sensor.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
SensorDeviceClass,
44
SensorEntity,
55
)
6-
from homeassistant.core import State
76
from homeassistant.helpers.entity_platform import AddEntitiesCallback
87
from homeassistant.helpers.event import async_track_state_change_event
98
from homeassistant.helpers.entity import DeviceInfo

0 commit comments

Comments
 (0)