Fix Extend ONVIF unique ID with profile index (#33103)

This commit is contained in:
Franck Nijhof 2020-03-21 19:36:35 +01:00 committed by GitHub
parent a7b08c48f3
commit 5893f6b14b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -505,4 +505,6 @@ class ONVIFHassCamera(Camera):
@property @property
def unique_id(self) -> Optional[str]: def unique_id(self) -> Optional[str]:
"""Return a unique ID.""" """Return a unique ID."""
if self._profile_index:
return f"{self._mac}_{self._profile_index}"
return self._mac return self._mac