Update Universal Powerline Bus event name (#35644)

This commit is contained in:
Glenn Waters 2020-05-16 04:43:40 -04:00 committed by GitHub
parent 299a4fa1c0
commit ab631a51bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -14,7 +14,7 @@ from .const import (
ATTR_COMMAND, ATTR_COMMAND,
ATTR_RATE, ATTR_RATE,
DOMAIN, DOMAIN,
EVENT_UPB_LINK_CHANGED, EVENT_UPB_SCENE_CHANGED,
) )
UPB_PLATFORMS = ["light", "scene"] UPB_PLATFORMS = ["light", "scene"]
@ -49,7 +49,7 @@ async def async_setup_entry(hass, config_entry):
return return
hass.bus.async_fire( hass.bus.async_fire(
EVENT_UPB_LINK_CHANGED, EVENT_UPB_SCENE_CHANGED,
{ {
ATTR_COMMAND: change["command"], ATTR_COMMAND: change["command"],
ATTR_ADDRESS: element.addr.index, ATTR_ADDRESS: element.addr.index,

View File

@ -13,7 +13,7 @@ ATTR_BRIGHTNESS_PCT = "brightness_pct"
ATTR_COMMAND = "command" ATTR_COMMAND = "command"
ATTR_RATE = "rate" ATTR_RATE = "rate"
CONF_NETWORK = "network" CONF_NETWORK = "network"
EVENT_UPB_LINK_CHANGED = "upb.link_changed" EVENT_UPB_SCENE_CHANGED = "upb.scene_changed"
VALID_BRIGHTNESS = vol.All(vol.Coerce(int), vol.Clamp(min=0, max=255)) VALID_BRIGHTNESS = vol.All(vol.Coerce(int), vol.Clamp(min=0, max=255))
VALID_BRIGHTNESS_PCT = vol.All(vol.Coerce(float), vol.Range(min=0, max=100)) VALID_BRIGHTNESS_PCT = vol.All(vol.Coerce(float), vol.Range(min=0, max=100))