Update homeassistant/components/roomba/sensor.py

Co-authored-by: Jan-Philipp Benecke <github@bnck.me>
This commit is contained in:
Xitee
2023-12-29 15:24:12 +01:00
committed by GitHub
parent 63e13952b0
commit 4b741183fe

View File

@@ -125,8 +125,8 @@ SENSORS: list[RoombaSensorEntityDescription] = [
icon="mdi:texture-box",
native_unit_of_measurement=AREA_SQUARE_METERS,
entity_category=EntityCategory.DIAGNOSTIC,
value_fn=(
lambda self: self.run_stats.get("sqft") * 9.29
value_fn=lambda self: (
self.run_stats.get("sqft") * 9.29
if self.run_stats.get("sqft") is not None
else None
),