From 8ef70a78d0f43f9232a7e5b75077129f4beedf78 Mon Sep 17 00:00:00 2001 From: Sebastian Muszynski Date: Sat, 18 Dec 2021 18:12:07 +0100 Subject: [PATCH] Rename deprecated device_state_attributes to extra_state_attributes --- custom_components/xiaomi_miio_airpurifier/climate.py | 4 ++-- custom_components/xiaomi_miio_airpurifier/fan.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/custom_components/xiaomi_miio_airpurifier/climate.py b/custom_components/xiaomi_miio_airpurifier/climate.py index 2d516dd..7a5a45b 100644 --- a/custom_components/xiaomi_miio_airpurifier/climate.py +++ b/custom_components/xiaomi_miio_airpurifier/climate.py @@ -246,8 +246,8 @@ def available(self): return self._available @property - def device_state_attributes(self): - """Return the state attributes of the device.""" + def extra_state_attributes(self): + """Return the extra state attributes of the device.""" return self._state_attrs @property diff --git a/custom_components/xiaomi_miio_airpurifier/fan.py b/custom_components/xiaomi_miio_airpurifier/fan.py index 985a158..d476c04 100644 --- a/custom_components/xiaomi_miio_airpurifier/fan.py +++ b/custom_components/xiaomi_miio_airpurifier/fan.py @@ -1259,8 +1259,8 @@ def available(self): return self._available @property - def device_state_attributes(self): - """Return the state attributes of the device.""" + def extra_state_attributes(self): + """Return the extra state attributes of the device.""" return self._state_attrs @property