Skip to content

Commit

Permalink
fixes #235
Browse files Browse the repository at this point in the history
  • Loading branch information
jensens committed Jul 29, 2020
1 parent 4c39bcd commit 8e21059
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 2 additions & 0 deletions news/235.bugfix
@@ -0,0 +1,2 @@
Fixes #235: ``Module collective.easyform.fields, line 63, in superAdapter IndexError: tuple index out of range``.
[jensens]
6 changes: 4 additions & 2 deletions src/collective/easyform/fields.py
Expand Up @@ -59,9 +59,11 @@ def __getattr__(self, item):
if not found:
return None

provides = providedBy(adapter).declared[0]
provided_by_declared = providedBy(adapter).declared
if not provided_by_declared:
return None

return queryMultiAdapter(new_obj, provides, name=name)
return queryMultiAdapter(new_obj, provided_by_declared[0], name=name)


@implementer(IValidator)
Expand Down

0 comments on commit 8e21059

Please sign in to comment.