mirror of
https://github.com/natekspencer/hacs-oasis_mini.git
synced 2025-12-06 18:44:14 -05:00
Address PR comments
This commit is contained in:
@@ -95,10 +95,5 @@ class OasisDeviceSensorEntity(OasisDeviceEntity, SensorEntity):
|
|||||||
|
|
||||||
@property
|
@property
|
||||||
def native_value(self) -> str | int | float | datetime | None:
|
def native_value(self) -> str | int | float | datetime | None:
|
||||||
"""
|
"""Provide the current sensor value from the underlying device."""
|
||||||
Provide the current sensor value from the underlying device.
|
|
||||||
|
|
||||||
Returns:
|
|
||||||
`str` with the sensor's current value, or `None` if the attribute is not present or has no value. The value is taken from the device attribute named by the entity description's `key`.
|
|
||||||
"""
|
|
||||||
return getattr(self.device, self.entity_description.key)
|
return getattr(self.device, self.entity_description.key)
|
||||||
|
|||||||
Reference in New Issue
Block a user