web/formwidgets.py
branchstable
changeset 3993 8cf7c767b134
parent 3803 414bb8439002
child 3998 94cc7cad3d2d
child 4212 ab6573088b4a
--- a/web/formwidgets.py	Thu Dec 03 12:50:31 2009 +0100
+++ b/web/formwidgets.py	Thu Dec 03 15:09:28 2009 +0100
@@ -394,6 +394,8 @@
         init_ajax_attributes(attrs, self.wdgtype, self.loadtype)
         # XXX entity form specific
         attrs['cubicweb:dataurl'] = self._get_url(form.edited_entity, field)
+        if not values:
+            values = ('',)
         return name, values, attrs
 
     def _get_url(self, entity, field):