Skip to content

Commit f52bbb5

Browse files
committed
Improve
1 parent 653e1e7 commit f52bbb5

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

plugwise/helper.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -811,17 +811,11 @@ def _object_value(
811811
match measurement:
812812
case "humidity":
813813
return int(float(value))
814-
case "outdoor_temperature":
814+
case "outdoor_temperature" | "solar_irradiance":
815815
return format_measure(
816816
value, getattr(attrs, ATTR_UNIT_OF_MEASUREMENT)
817817
)
818-
case "solar_irradiance":
819-
return format_measure(
820-
value, getattr(attrs, ATTR_UNIT_OF_MEASUREMENT)
821-
)
822-
case "weather_description":
823-
return value
824-
case "wind_vector":
818+
case _:
825819
return value
826820

827821
return None

0 commit comments

Comments
 (0)