Remove deprecated device_state_attributes (#55734)

This commit is contained in:
Marc Mueller 2021-09-04 22:16:01 +02:00 committed by GitHub
parent 58da58c008
commit f5a543b220
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 8 additions and 15 deletions

View file

@ -57,6 +57,8 @@ async def async_setup_entry(hass, config_entry, async_add_entities):
class FliprSensor(FliprEntity, SensorEntity):
"""Sensor representing FliprSensor data."""
_attr_extra_state_attributes = {ATTR_ATTRIBUTION: ATTRIBUTION}
@property
def name(self):
"""Return the name of the particular component."""
@ -84,8 +86,3 @@ class FliprSensor(FliprEntity, SensorEntity):
def native_unit_of_measurement(self):
"""Return unit of measurement."""
return SENSORS[self.info_type]["unit"]
@property
def device_state_attributes(self):
"""Return device attributes."""
return {ATTR_ATTRIBUTION: ATTRIBUTION}