[server] remove useless indirection ExecutionPlan.sqlannotate
authorNicolas Chauvat <nicolas.chauvat@logilab.fr>
Tue, 12 Mar 2019 23:04:57 +0100
changeset 12495 23081860ea60
parent 12494 3c2f104638dd
child 12496 ad995a9905f9
[server] remove useless indirection ExecutionPlan.sqlannotate Simpler is better. Use directly ExecutionPlan.querier.sqlgen_annotate.
cubicweb/server/querier.py
--- a/cubicweb/server/querier.py	Tue Mar 12 23:20:50 2019 +0100
+++ b/cubicweb/server/querier.py	Tue Mar 12 23:04:57 2019 +0100
@@ -167,7 +167,6 @@
         # various resource accesors
         self.querier = querier
         self.schema = querier.schema
-        self.sqlannotate = querier.sqlgen_annotate
         self.rqlhelper = cnx.vreg.rqlhelper
 
     def annotate_rqlst(self):
@@ -219,7 +218,7 @@
             noinvariant = ()
         if cached is None:
             self.rqlhelper.simplify(union)
-            self.sqlannotate(union)
+            self.querier.sqlgen_annotate(union)
             set_qdata(self.schema.rschema, union, noinvariant)
         if union.has_text_query:
             self.cache_key = None