From 95ceb2a4a42093c9fd728e9e3d546943bc7b0b9d Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Sat, 20 Apr 2013 11:03:00 -0500 Subject: Remove spaceless from depends and required by template fragments This was a bit of premature optimization, and ends up slowing the page generation a good amount since we have to run this ~400 times on some packages with long depends or required by lists. Webserver compression should handle this just fine and not result in too much page bloat. Signed-off-by: Dan McGee --- templates/packages/details_depend.html | 5 ++--- templates/packages/details_requiredby.html | 4 ++-- 2 files changed, 4 insertions(+), 5 deletions(-) (limited to 'templates') diff --git a/templates/packages/details_depend.html b/templates/packages/details_depend.html index 4aa739c..b89ffbf 100644 --- a/templates/packages/details_depend.html +++ b/templates/packages/details_depend.html @@ -1,5 +1,4 @@ -{% load package_extras %}{% spaceless %}
  • -{% ifequal depend.pkg None %} +{% load package_extras %}
  • {% ifequal depend.pkg None %} {% if depend.providers %}{{ depend.dep.name }}{{ depend.dep.comparison|default:"" }}{{ depend.dep.version|default:"" }} ({% multi_pkg_details depend.providers %}) {% else %}{{ depend.dep.name }}{{ depend.dep.comparison|default:"" }}{{ depend.dep.version|default:"" }} (virtual) {% endif %}{% else %} @@ -11,4 +10,4 @@ {% endif %}{% if depend.dep.deptype == 'M' %} (make) {% endif %}{% if depend.dep.deptype == 'C' %} (check) {% endif %}{% if depend.dep.description %} - {{ depend.dep.description }} -{% endif %}
  • {% endspaceless %} +{% endif %} diff --git a/templates/packages/details_requiredby.html b/templates/packages/details_requiredby.html index e8c713a..504a322 100644 --- a/templates/packages/details_requiredby.html +++ b/templates/packages/details_requiredby.html @@ -1,8 +1,8 @@ -{% load package_extras %}{% spaceless %}
  • {% pkg_details_link req.pkg %} +{% load package_extras %}
  • {% pkg_details_link req.pkg %} {% if req.name != pkg.pkgname %} (requires {{ req.name }}) {% endif %}{% if req.pkg.repo.testing %} (testing) {% endif %}{% if req.pkg.repo.staging %} (staging) {% endif %}{% if req.deptype == 'O' %} (optional) {% endif %}{% if req.deptype == 'M' %} (make) {% endif %}{% if req.deptype == 'C' %} (check) -{% endif %}
  • {% endspaceless %} +{% endif %} -- cgit v1.2.3-24-g4f1b