Proper error raising when a form does not exist.

pull/7/head
Ferry Boender 10 years ago
parent fd39f8b85c
commit 3f4795d9ca
  1. 2
      src/scriptform.py

@ -212,6 +212,8 @@ class FormConfig:
for form_def in self.forms:
if form_def.name == form_name:
return form_def
else:
raise ValueError("No such form: {0}".format(form_name))
def callback(self, form_name, form_values, output_fh=None):
form = self.get_form(form_name)

Loading…
Cancel
Save