mirror of
https://github.com/home-assistant/core.git
synced 2025-07-18 18:57:06 +00:00
Update dlink.py (#4317)
corrected "total consumption" units from W to kWh
This commit is contained in:
parent
4f86c9ecda
commit
8cbb8f6527
@ -87,7 +87,7 @@ class SmartPlugSwitch(SwitchDevice):
|
|||||||
current_consumption = STATE_UNKNOWN
|
current_consumption = STATE_UNKNOWN
|
||||||
|
|
||||||
try:
|
try:
|
||||||
total_consumption = "%.1f W" % \
|
total_consumption = "%.1f kWh" % \
|
||||||
float(self.smartplug.total_consumption)
|
float(self.smartplug.total_consumption)
|
||||||
except ValueError:
|
except ValueError:
|
||||||
total_consumption = STATE_UNKNOWN
|
total_consumption = STATE_UNKNOWN
|
||||||
|
Loading…
x
Reference in New Issue
Block a user