selectors.py
branchstable
changeset 3350 fa77640a9155
parent 3346 b1fd9d4ef579
child 3369 7b88d12b4ee2
child 3522 cde0ff4f7a8c
--- a/selectors.py	Mon Sep 21 18:03:10 2009 +0200
+++ b/selectors.py	Mon Sep 21 18:09:38 2009 +0200
@@ -527,12 +527,10 @@
     @lltrace
     def __call__(self, cls, req, rset=None, row=None, col=0, **kwargs):
         try:
-            trname = req.execute('Any XN WHERE X is Transition, X eid %(x)s, X name XN',
-                                 {'x': typed_eid(req.form['treid'])})[0][0]
-        except (KeyError, IndexError):
-            return 0
-        # XXX check this is a transition that apply to the object?
-        if not trname in self.expected:
+            # XXX check this is a transition that apply to the object?
+            if not kwargs['transition'].name in self.expected:
+                return 0
+        except KeyError:
             return 0
         return 1