修复错误

This commit is contained in:
ha0y 2021-02-20 22:15:53 +08:00
parent b7a91a364c
commit 27624df937
1 changed files with 1 additions and 1 deletions

View File

@ -80,7 +80,7 @@ class BjbusSensor(CoordinatorEntity):
"""Return the state of the device."""
# return self._state
if d := self._coordinator.data:
return d[0][self._type[4]]
return d[-1][self._type[4]]
else:
return None