1
0
mirror of https://github.com/elisspace/core.git synced 2026-09-01 08:53:56 +00:00

Fix upnp raw sensor state formatting when None (#30444)

This commit is contained in:
Phil Bruckner
2020-01-08 23:51:30 -06:00
committed by Martin Hjelmare
parent fe0b537291
commit 260596d11b

View File

@@ -126,6 +126,9 @@ class RawUPnPIGDSensor(UpnpSensor):
@property
def state(self) -> str:
"""Return the state of the device."""
if self._state is None:
return None
return format(self._state, "d")
@property