Skip to content

Commit

Permalink
Don't call controller.form_fields() unnecessarily.
Browse files Browse the repository at this point in the history
  • Loading branch information
davidblewett committed Jan 30, 2012
1 parent 5261da3 commit 74c49ed
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pyramid_formish/zcml.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ def form_from_controller(controller, form_id, actions=(), method='POST'):
form_schema = schemaish.Structure()

form_fields = controller.form_fields()
for fieldname, field in controller.form_fields():
for fieldname, field in form_fields:
form_schema.add(fieldname, field)
form = Form(form_schema, name=form_id, add_default_action=False,
method=method)
Expand Down

0 comments on commit 74c49ed

Please sign in to comment.