Allow OpenUV entities to be unavailable (#31018)

* Allow OpenUV entities to be unavailable

* Empty commit to re-trigger build
This commit is contained in:
Aaron Bach authored and GitHub committed 2020-01-20 13:33:58 -07:00
1 parent 1639432463
commit 662c12715e
3 files changed
+17 -1

No files matched your search

@@ -289,9 +289,15 @@ class OpenUvEntity(Entity):
def __init__(self, openuv):
"""Initialize."""
self._attrs = {ATTR_ATTRIBUTION: DEFAULT_ATTRIBUTION}
self._available = True
self._name = None
self.openuv = openuv
@property
def available(self) -> bool:
"""Return True if entity is available."""
return self._available
@property
def device_state_attributes(self):
"""Return the state attributes."""