← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] ~cjwatson/launchpad:latest-uploads-extra-query into launchpad:master

 

Colin Watson has proposed merging ~cjwatson/launchpad:latest-uploads-extra-query into launchpad:master.

Commit message:
Remove extra query from DistroSeries:+portlet-latestuploads

Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)

For more details, see:
https://code.launchpad.net/~cjwatson/launchpad/+git/launchpad/+merge/403825

`DistroSeries.getLatestUploads` is still relatively slow even after recent optimizations, so it's worth avoiding calling it twice unnecessarily.
-- 
Your team Launchpad code reviewers is requested to review the proposed merge of ~cjwatson/launchpad:latest-uploads-extra-query into launchpad:master.
diff --git a/lib/lp/soyuz/templates/distroseries-portlet-latestuploads.pt b/lib/lp/soyuz/templates/distroseries-portlet-latestuploads.pt
index 6028ca7..bd39aaf 100644
--- a/lib/lp/soyuz/templates/distroseries-portlet-latestuploads.pt
+++ b/lib/lp/soyuz/templates/distroseries-portlet-latestuploads.pt
@@ -13,7 +13,7 @@
 
   <ul id="latest-uploads" class="binary package"
     tal:condition="latest_uploads">
-    <li tal:repeat="source context/getLatestUploads">
+    <li tal:repeat="source latest_uploads">
       <a
        tal:attributes="href source/fmt:url"
        tal:content="source/displayname" />