Reolink use parenthesis for multi-line lambda (#104321)
Use parenthesis
This commit is contained in:
parent
59469828f1
commit
6c6e85f996
2 changed files with 7 additions and 4 deletions
|
@ -49,8 +49,9 @@ BUTTON_ENTITIES = (
|
|||
translation_key="ptz_stop",
|
||||
icon="mdi:pan",
|
||||
enabled_default=lambda api, ch: api.supported(ch, "pan_tilt"),
|
||||
supported=lambda api, ch: api.supported(ch, "pan_tilt")
|
||||
or api.supported(ch, "zoom_basic"),
|
||||
supported=lambda api, ch: (
|
||||
api.supported(ch, "pan_tilt") or api.supported(ch, "zoom_basic")
|
||||
),
|
||||
method=lambda api, ch: api.set_ptz_command(ch, command=PtzEnum.stop.value),
|
||||
),
|
||||
ReolinkButtonEntityDescription(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue