mirror of
https://github.com/home-assistant/core.git
synced 2025-07-24 21:57:51 +00:00
fix error message for cv.matches_regex (#16175)
This commit is contained in:
parent
e91a1529e4
commit
84365cde07
@ -92,7 +92,7 @@ def matches_regex(regex):
|
|||||||
|
|
||||||
if not regex.match(value):
|
if not regex.match(value):
|
||||||
raise vol.Invalid('value {} does not match regular expression {}'
|
raise vol.Invalid('value {} does not match regular expression {}'
|
||||||
.format(regex.pattern, value))
|
.format(value, regex.pattern))
|
||||||
|
|
||||||
return value
|
return value
|
||||||
return validator
|
return validator
|
||||||
|
Loading…
x
Reference in New Issue
Block a user