Skip to content

Commit 8c93dd4

Browse files
authored
fix(switch): Remove warning about using incorrect schema for entity service registration (#312)
Fixes #314
1 parent f826058 commit 8c93dd4

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

custom_components/nodered/switch.py

+6-7
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,12 @@
3131

3232
_LOGGER = logging.getLogger(__name__)
3333

34-
SERVICE_TRIGGER_SCHEMA = vol.Schema(
35-
{
36-
vol.Required(CONF_ENTITY_ID): cv.entity_ids,
37-
vol.Optional(CONF_OUTPUT_PATH, default="0"): cv.string,
38-
vol.Optional(CONF_MESSAGE, default={}): dict,
39-
}
40-
)
34+
SERVICE_TRIGGER_SCHEMA = {
35+
vol.Required(CONF_ENTITY_ID): cv.entity_ids,
36+
vol.Optional(CONF_OUTPUT_PATH, default="0"): cv.string,
37+
vol.Optional(CONF_MESSAGE, default={}): dict,
38+
}
39+
4140
EVENT_TRIGGER_NODE = "automation_triggered"
4241
EVENT_DEVICE_TRIGGER = "device_trigger"
4342

0 commit comments

Comments
 (0)