From 5e4d0170d42b8c057f5ac8b952befcd3ecd8ac41 Mon Sep 17 00:00:00 2001 From: Mokaddem Date: Wed, 26 Apr 2017 11:31:08 +0200 Subject: [PATCH] Bug fixes, jinja2 iter0 and typo --- .../templates/important_paste_by_module.html | 12 +++++------- .../showpaste/templates/show_saved_paste.html | 2 +- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/var/www/modules/browsepastes/templates/important_paste_by_module.html b/var/www/modules/browsepastes/templates/important_paste_by_module.html index ff6f3f87..14048bbb 100644 --- a/var/www/modules/browsepastes/templates/important_paste_by_module.html +++ b/var/www/modules/browsepastes/templates/important_paste_by_module.html @@ -9,16 +9,14 @@ - {% set i = 0 %} {% for path in all_path %} - {{ i + 1 }} - {{ path }} - {{ paste_date[i] }} - {{ paste_linenum[i] }} -

+ {{ loop.index0 }} + {{ path }} + {{ paste_date[loop.index0] }} + {{ paste_linenum[loop.index0] }} +

- {% set i = i + 1 %} {% endfor %} diff --git a/var/www/modules/showpaste/templates/show_saved_paste.html b/var/www/modules/showpaste/templates/show_saved_paste.html index 7150b7ba..d58b243f 100644 --- a/var/www/modules/showpaste/templates/show_saved_paste.html +++ b/var/www/modules/showpaste/templates/show_saved_paste.html @@ -71,7 +71,7 @@ {{ hashtype_list[i] }} Similarity: {{ simil_list[i] }}% {{ date_list[i] }} - {{ dup_path }} + {{ dup_path }} {% set i = i + 1 %} {% endfor %}