Skip to content

Commit

Permalink
remove duplicate method
Browse files Browse the repository at this point in the history
  • Loading branch information
dmulcahey committed Apr 6, 2024
1 parent 0a0294e commit f64eabc
Showing 1 changed file with 0 additions and 17 deletions.
17 changes: 0 additions & 17 deletions zha/application/platforms/light/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,23 +253,6 @@ def handle_cluster_handler_set_level(self, event: LevelChangeEvent) -> None:
self._brightness = value
self.maybe_emit_state_changed_event()

def set_level(self, value: int) -> None:
"""Set the brightness of this light between 0..254.
brightness level 255 is a special value instructing the device to come
on at `on_level` Zigbee attribute value, regardless of the last set
level
"""
if self.is_transitioning:
self.debug(
"received level %s while transitioning - skipping update",
value,
)
return
value = max(0, min(254, value))
self._brightness = value
self.maybe_emit_state_changed_event()

async def async_turn_on(self, **kwargs: Any) -> None:
"""Turn the entity on."""
transition = kwargs.get(ATTR_TRANSITION)
Expand Down

0 comments on commit f64eabc

Please sign in to comment.