web/formfields.py
branchstable
changeset 5661 84ef08bbda3c
parent 5497 96fd339f7917
child 5679 0f2ded880d01
child 5756 ab03e4adb4f1
--- a/web/formfields.py	Thu Jun 03 15:13:41 2010 +0200
+++ b/web/formfields.py	Thu Jun 03 16:37:01 2010 +0200
@@ -433,9 +433,11 @@
             # attribute or relation
             return True
         # if it's a non final relation, we need the eids
-        if isinstance(previous_value, tuple):
+        # XXX underlying regression: getattr(ent, 'foo') used to return
+        #     a tuple, now we get a list
+        if isinstance(previous_value, (list, tuple)):
             # widget should return a set of untyped eids
-            previous_value = set(unicode(e.eid) for e in previous_value)
+            previous_value = set(e.eid for e in previous_value)
         try:
             new_value = self.process_form_value(form)
         except ProcessFormError: