web/views/forms.py
branchstable
changeset 5656 abe97430b3f5
parent 5598 0a68e7f5829c
child 6246 62e25fac41cd
--- a/web/views/forms.py	Tue Jun 01 17:44:55 2010 +0200
+++ b/web/views/forms.py	Thu Jun 03 10:20:00 2010 +0200
@@ -196,9 +196,13 @@
 
     _default_form_action_path = 'edit'
     def form_action(self):
-        if self.action is None:
+        try:
+            action = self.get_action() # avoid spurious warning w/ autoform bw compat property
+        except AttributeError:
+            action = self.action
+        if action is None:
             return self._cw.build_url(self._default_form_action_path)
-        return self.action
+        return action
 
     @deprecated('[3.6] use .add_hidden(name, value, **kwargs)')
     def form_add_hidden(self, name, value=None, **kwargs):