server/hook.py
branchstable
changeset 5509 205e708dd5db
parent 5426 0d4853a6e5ee
child 5538 752bc67064f2
--- a/server/hook.py	Mon May 10 15:20:54 2010 +0200
+++ b/server/hook.py	Mon May 10 17:49:42 2010 +0200
@@ -304,9 +304,9 @@
             assert self.rtype in self.object_relations
             meid, seid = self.eidto, self.eidfrom
         self._cw.execute(
-            'SET E %s P WHERE X %s P, X eid %%(x)s, E eid %%(e)s, NOT E %s P'\
+            'SET E %s P WHERE X %s P, X eid %%(x)s, E eid %%(e)s, NOT E %s P'
             % (self.main_rtype, self.main_rtype, self.main_rtype),
-            {'x': meid, 'e': seid}, ('x', 'e'))
+            {'x': meid, 'e': seid})
 
 
 class PropagateSubjectRelationAddHook(Hook):
@@ -326,12 +326,12 @@
             if rel in eschema.subjrels:
                 execute('SET R %s P WHERE X eid %%(x)s, P eid %%(p)s, '
                         'X %s R, NOT R %s P' % (self.rtype, rel, self.rtype),
-                        {'x': self.eidfrom, 'p': self.eidto}, 'x')
+                        {'x': self.eidfrom, 'p': self.eidto})
         for rel in self.object_relations:
             if rel in eschema.objrels:
                 execute('SET R %s P WHERE X eid %%(x)s, P eid %%(p)s, '
                         'R %s X, NOT R %s P' % (self.rtype, rel, self.rtype),
-                        {'x': self.eidfrom, 'p': self.eidto}, 'x')
+                        {'x': self.eidfrom, 'p': self.eidto})
 
 
 class PropagateSubjectRelationDelHook(Hook):
@@ -351,12 +351,12 @@
             if rel in eschema.subjrels:
                 execute('DELETE R %s P WHERE X eid %%(x)s, P eid %%(p)s, '
                         'X %s R' % (self.rtype, rel),
-                        {'x': self.eidfrom, 'p': self.eidto}, 'x')
+                        {'x': self.eidfrom, 'p': self.eidto})
         for rel in self.object_relations:
             if rel in eschema.objrels:
                 execute('DELETE R %s P WHERE X eid %%(x)s, P eid %%(p)s, '
                         'R %s X' % (self.rtype, rel),
-                        {'x': self.eidfrom, 'p': self.eidto}, 'x')
+                        {'x': self.eidfrom, 'p': self.eidto})
 
 
 # abstract classes for operation ###############################################