mirror of
https://github.com/home-assistant/core.git
synced 2025-07-24 21:57:51 +00:00
Fix data_key override by parent class (#16278)
This commit is contained in:
parent
99d48795b9
commit
25ee8e551c
@ -374,11 +374,11 @@ class XiaomiCube(XiaomiBinarySensor):
|
||||
self._last_action = None
|
||||
self._state = False
|
||||
if 'proto' not in device or int(device['proto'][0:1]) == 1:
|
||||
self._data_key = 'status'
|
||||
data_key = 'status'
|
||||
else:
|
||||
self._data_key = 'cube_status'
|
||||
data_key = 'cube_status'
|
||||
XiaomiBinarySensor.__init__(self, device, 'Cube', xiaomi_hub,
|
||||
None, None)
|
||||
data_key, None)
|
||||
|
||||
@property
|
||||
def device_state_attributes(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user