forked from home-assistant/core
consolidate conditionals
This commit is contained in:
@@ -162,11 +162,10 @@ class RGBWLimitlessLED(LimitlessLED):
|
|||||||
|
|
||||||
effect = kwargs.get(ATTR_EFFECT)
|
effect = kwargs.get(ATTR_EFFECT)
|
||||||
|
|
||||||
if effect:
|
if effect == EFFECT_COLORLOOP:
|
||||||
if effect == EFFECT_COLORLOOP:
|
self.pool.execute(self.controller_id, "disco", self.group)
|
||||||
self.pool.execute(self.controller_id, "disco", self.group)
|
if effect == EFFECT_WHITE:
|
||||||
if effect == EFFECT_WHITE:
|
self.pool.execute(self.controller_id, "white", self.group)
|
||||||
self.pool.execute(self.controller_id, "white", self.group)
|
|
||||||
else:
|
else:
|
||||||
self.pool.execute(self.controller_id, "set_color",
|
self.pool.execute(self.controller_id, "set_color",
|
||||||
self._xy_to_led_color(self._xy_color),
|
self._xy_to_led_color(self._xy_color),
|
||||||
|
Reference in New Issue
Block a user