Expose Wemo component availability to home assistant (#14995)
* Expose Wemo component availability to home assistant
* Do not add availability feature to dimmer - it works differently
* Brain fade, deleted completely the wrong thing.
Revert "Do not add availability feature to dimmer - it works differently"
This reverts commit f64e717981
.
* (2nd attempt) Do not add availability feature to dimmer - it works differently
This commit is contained in:
parent
0e7e58f172
commit
d07e40c483
1 changed files with 5 additions and 0 deletions
|
@ -107,6 +107,11 @@ class WemoLight(Light):
|
||||||
"""Flag supported features."""
|
"""Flag supported features."""
|
||||||
return SUPPORT_WEMO
|
return SUPPORT_WEMO
|
||||||
|
|
||||||
|
@property
|
||||||
|
def available(self):
|
||||||
|
"""Return if light is available."""
|
||||||
|
return self.device.state['available']
|
||||||
|
|
||||||
def turn_on(self, **kwargs):
|
def turn_on(self, **kwargs):
|
||||||
"""Turn the light on."""
|
"""Turn the light on."""
|
||||||
transitiontime = int(kwargs.get(ATTR_TRANSITION, 0))
|
transitiontime = int(kwargs.get(ATTR_TRANSITION, 0))
|
||||||
|
|
Loading…
Add table
Reference in a new issue