aboutsummaryrefslogtreecommitdiff
path: root/pyaggr3g470r/forms.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyaggr3g470r/forms.py')
-rw-r--r--pyaggr3g470r/forms.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/pyaggr3g470r/forms.py b/pyaggr3g470r/forms.py
index e385c4e2..fb4a829c 100644
--- a/pyaggr3g470r/forms.py
+++ b/pyaggr3g470r/forms.py
@@ -87,11 +87,16 @@ class SigninForm(Form):
class AddFeedForm(Form):
title = TextField(lazy_gettext("Title"), [validators.Optional()])
- link = TextField(lazy_gettext("Feed link"), [validators.Optional()])
- site_link = TextField(lazy_gettext("Site link"))
+ link = TextField(lazy_gettext("Feed link"))
+ site_link = TextField(lazy_gettext("Site link"), [validators.Optional()])
enabled = BooleanField(lazy_gettext("Check for updates"), default=True)
submit = SubmitField(lazy_gettext("Save"))
+ def validate(self):
+ if not super(AddFeedForm, self).validate():
+ return False
+ return True
+
class ProfileForm(Form):
nickname = TextField(lazy_gettext("Nickname"),
bgstack15