Skip to content

Commit 5d9d6e6

Browse files
committed
remove wtforms email validator
1 parent 947ee5c commit 5d9d6e6

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

eNMS/services/examples/example.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010

1111
# WTForms Field Validators
1212
from wtforms.validators import (
13-
Email,
1413
InputRequired,
1514
IPAddress,
1615
Length,
@@ -111,10 +110,8 @@ class ExampleForm(ServiceForm):
111110
# The "InputRequired" validator is used: this field is mandatory.
112111
string2 = StringField("String 2 (required)", [InputRequired()])
113112

114-
# The main address field uses two validators:
115-
# - The input length must be comprised between 7 and 25 characters
116-
# - The input syntax must match that of an email address.
117-
mail_address = StringField("Mail address", [Length(min=7, max=25), Email()])
113+
# The main address length must be comprised between 7 and 25 characters
114+
mail_address = StringField("Mail address", [Length(min=7, max=25)])
118115

119116
# This IP address validator will ensure the user input is a valid IPv4 address.
120117
# If it isn't, you can set the error message to be displayed in the GUI.

0 commit comments

Comments
 (0)