web/formfields.py
changeset 10716 9a9d57edb1c1
parent 10696 4ba4be5553cf
child 10787 34ada3b21eef
--- a/web/formfields.py	Fri Sep 18 18:01:31 2015 +0200
+++ b/web/formfields.py	Fri Sep 18 18:02:20 2015 +0200
@@ -383,7 +383,7 @@
         assert self.choices is not None
         if callable(self.choices):
             # pylint: disable=E1102
-            if getattr(self.choices, 'im_self', None) is self:
+            if getattr(self.choices, '__self__', None) is self:
                 vocab = self.choices(form=form, **kwargs)
             else:
                 vocab = self.choices(form=form, field=self, **kwargs)