Skip to content

Commit

Permalink
Fix climate entity name (#18)
Browse files Browse the repository at this point in the history
  • Loading branch information
oyvindwe authored Jul 7, 2024
1 parent 3194601 commit f3589ad
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 8 deletions.
2 changes: 0 additions & 2 deletions custom_components/connectlife/binary_sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,6 @@ async def async_setup_entry(
class ConnectLifeBinaryStatusSensor(ConnectLifeEntity, BinarySensorEntity):
"""Sensor class for ConnectLife arbitrary status."""

_attr_has_entity_name = True

def __init__(
self,
coordinator: ConnectLifeCoordinator,
Expand Down
2 changes: 1 addition & 1 deletion custom_components/connectlife/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def is_climate(dictionary: dict[str, Property]):
class ConnectLifeClimate(ConnectLifeEntity, ClimateEntity):
"""Climate class for ConnectLife."""

_attr_has_entity_name = True
_attr_name = None
_attr_precision = PRECISION_WHOLE
_attr_target_temperature_step = 1
_attr_temperature_unit = UnitOfTemperature.CELSIUS
Expand Down
2 changes: 2 additions & 0 deletions custom_components/connectlife/entity.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
class ConnectLifeEntity(CoordinatorEntity[ConnectLifeCoordinator]):
"""Generic ConnectLife entity (base class)."""

_attr_has_entity_name = True

def __init__(self, coordinator: ConnectLifeCoordinator, appliance: ConnectLifeAppliance):
"""Initialize the entity."""
super().__init__(coordinator)
Expand Down
1 change: 0 additions & 1 deletion custom_components/connectlife/select.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ async def async_setup_entry(
class ConnectLifeSelect(ConnectLifeEntity, SelectEntity):
"""Select class for ConnectLife."""

_attr_has_entity_name = True
_attr_current_option = None

def __init__(
Expand Down
2 changes: 0 additions & 2 deletions custom_components/connectlife/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,6 @@ async def async_setup_entry(
class ConnectLifeStatusSensor(ConnectLifeEntity, SensorEntity):
"""Sensor class for ConnectLife arbitrary status."""

_attr_has_entity_name = True

def __init__(
self,
coordinator: ConnectLifeCoordinator,
Expand Down
2 changes: 0 additions & 2 deletions custom_components/connectlife/switch.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@ async def async_setup_entry(
class ConnectLifeSwitch(ConnectLifeEntity, SwitchEntity):
"""Switch class for ConnectLife."""

_attr_has_entity_name = True

def __init__(
self,
coordinator: ConnectLifeCoordinator,
Expand Down

0 comments on commit f3589ad

Please sign in to comment.