Small improvement

This commit is contained in:
Maximilian Giller 2025-01-20 06:41:18 +01:00
parent c78546ffcf
commit c3ec52005e

View file

@ -12,8 +12,9 @@ class BedscaleWeightResult:
# Calculate total if all values available
self.total: float | None = None
if None not in [bl, br, tl, tr]:
self.total = sum([bl, br, tl, tr])
values = [bl, br, tl, tr]
if None not in values:
self.total = sum(values)
class BedscaleEntity(Entity):