cleanup
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Fri, 19 Mar 2010 09:08:09 +0100
changeset 4955 8ddd5e938804
parent 4954 96f67c5be0e6
child 4956 e8a5cd5032f4
cleanup
server/querier.py
--- a/server/querier.py	Fri Mar 19 09:08:00 2010 +0100
+++ b/server/querier.py	Fri Mar 19 09:08:09 2010 +0100
@@ -69,6 +69,7 @@
                 rdef = rschema.rdef(solution[rel.children[0].name],
                                     solution[rel.children[1].children[0].name])
             if not user.matching_groups(rdef.get_groups('read')):
+                # XXX rqlexpr not allowed
                 raise Unauthorized('read', rel.r_type)
     localchecks = {}
     # iterate on defined_vars and not on solutions to ignore column aliases
@@ -284,8 +285,7 @@
                     myrqlst = select.copy(solutions=lchecksolutions)
                     myunion.append(myrqlst)
                     # in-place rewrite + annotation / simplification
-                    lcheckdef = [((varmap, 'X'), rqlexprs)
-                                 for varmap, rqlexprs in lcheckdef]
+                    lcheckdef = [((var, 'X'), rqlexprs) for var, rqlexprs in lcheckdef]
                     rewrite(myrqlst, lcheckdef, lchecksolutions, self.args)
                     add_noinvariant(noinvariant, restricted, myrqlst, nbtrees)
                 if () in localchecks: