mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
form: fix pattern can be None
This commit is contained in:
parent
dad366da61
commit
878944c7c1
1 changed files with 1 additions and 0 deletions
|
@ -2095,6 +2095,7 @@ def prompt_or_validate_form(
|
||||||
if (
|
if (
|
||||||
isinstance(option, (BaseStringOption, TagsOption))
|
isinstance(option, (BaseStringOption, TagsOption))
|
||||||
and "regex" in err["type"]
|
and "regex" in err["type"]
|
||||||
|
and option.pattern is not None
|
||||||
):
|
):
|
||||||
err_text = option.pattern.error
|
err_text = option.pattern.error
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Add table
Reference in a new issue