Skip to content

Commit

Permalink
Merge pull request #113 from mariusz-ostoja-swierczynski/fix_112
Browse files Browse the repository at this point in the history
🐛 Fix missing atttributes in some sensors
  • Loading branch information
anarion80 authored Sep 17, 2024
2 parents 152f79e + 2c75abc commit a85be2e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions custom_components/tech/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -1331,7 +1331,7 @@ def device_info(self):
return None


class TileFuelSupplySensor(TileSensor):
class TileFuelSupplySensor(TileSensor, SensorEntity):
"""Representation of a Tile Fuel Supply Sensor."""

_attr_native_unit_of_measurement = PERCENTAGE
Expand All @@ -1357,7 +1357,7 @@ def get_state(self, device):
return device[CONF_PARAMS]["percentage"]


class TileFanSensor(TileSensor):
class TileFanSensor(TileSensor, SensorEntity):
"""Representation of a Tile Fan Sensor."""

_attr_native_unit_of_measurement = PERCENTAGE
Expand All @@ -1383,7 +1383,7 @@ def get_state(self, device):
return device[CONF_PARAMS]["gear"]


class TileTextSensor(TileSensor):
class TileTextSensor(TileSensor, SensorEntity):
"""Representation of a Tile Text Sensor."""

def __init__(self, device, coordinator, config_entry):
Expand Down Expand Up @@ -1412,7 +1412,7 @@ def get_state(self, device):
return assets.get_text(device[CONF_PARAMS]["statusId"])


class TileWidgetSensor(TileSensor):
class TileWidgetSensor(TileSensor, SensorEntity):
"""Representation of a Tile Widget Sensor."""

_attr_native_unit_of_measurement = UnitOfTemperature.CELSIUS
Expand Down

0 comments on commit a85be2e

Please sign in to comment.