mirror of
https://github.com/home-assistant/core.git
synced 2026-09-01 02:34:44 -05:00
Fix upnp raw sensor state formatting when None (#30444)
This commit is contained in:
committed by
Paulus Schoutsen
parent
5d850c5b19
commit
c7e300e5b1
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user