From e9ad610a6f813a325a6ddf8f44778f1054e9caf2 Mon Sep 17 00:00:00 2001 From: leigh-mil Date: Thu, 18 Oct 2018 15:22:57 -0400 Subject: [PATCH] Update Alphabet validator to accept hyphens --- atst/forms/validators.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/atst/forms/validators.py b/atst/forms/validators.py index 142d55d1..c1113f06 100644 --- a/atst/forms/validators.py +++ b/atst/forms/validators.py @@ -52,7 +52,7 @@ def PhoneNumber(message="Please enter a valid 5 or 10 digit phone number."): def Alphabet(message="Please enter only letters."): def _alphabet(form, field): - match = re.match(r"[A-Za-z]+", field.data) + match = re.match(r"[A-Za-z\-]+", field.data) if not match or match.group() != field.data: raise ValidationError(message)