mirror of
https://github.com/esphome/esphome.git
synced 2025-10-15 00:03:51 +01:00
Update esphome/components/api/__init__.py
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -254,7 +254,7 @@ KEY_VALUE_SCHEMA = cv.Schema({cv.string: cv.templatable(cv.string_strict)})
|
|||||||
def _validate_response_config(config):
|
def _validate_response_config(config):
|
||||||
if CONF_RESPONSE_TEMPLATE in config and not config.get(CONF_ON_RESPONSE):
|
if CONF_RESPONSE_TEMPLATE in config and not config.get(CONF_ON_RESPONSE):
|
||||||
raise cv.Invalid(
|
raise cv.Invalid(
|
||||||
"`{CONF_RESPONSE_TEMPLATE}` requires `{CONF_ON_RESPONSE}` to be set."
|
f"`{CONF_RESPONSE_TEMPLATE}` requires `{CONF_ON_RESPONSE}` to be set."
|
||||||
)
|
)
|
||||||
return config
|
return config
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user