Use native_precision
instead of round
in Accuweather (#86869)
This commit is contained in:
parent
d2e75e4f7a
commit
cc36848a6d
1 changed files with 2 additions and 1 deletions
|
@ -248,7 +248,8 @@ SENSOR_TYPES: tuple[AccuWeatherSensorDescription, ...] = (
|
|||
state_class=SensorStateClass.MEASUREMENT,
|
||||
metric_unit=UnitOfLength.METERS,
|
||||
us_customary_unit=UnitOfLength.FEET,
|
||||
value_fn=lambda data, unit: round(cast(float, data[unit][ATTR_VALUE])),
|
||||
value_fn=lambda data, unit: cast(float, data[unit][ATTR_VALUE]),
|
||||
native_precision=0,
|
||||
),
|
||||
AccuWeatherSensorDescription(
|
||||
key="CloudCover",
|
||||
|
|
Loading…
Add table
Reference in a new issue