]> git.phdru.name Git - phdru.name/cgi-bin/blog-ru/search-tags.git/commitdiff
Return y/m/d
authorOleg Broytman <phd@phdru.name>
Tue, 20 May 2014 14:23:40 +0000 (18:23 +0400)
committerOleg Broytman <phd@phdru.name>
Tue, 20 May 2014 14:23:40 +0000 (18:23 +0400)
tags.py

diff --git a/tags.py b/tags.py
index e1d5dd11eaa625d321a49cff9bbe0249feaffefc..dec88988ffca1bdc18b68e7e0724bbfd07a7b09a 100644 (file)
--- a/tags.py
+++ b/tags.py
@@ -59,7 +59,8 @@ def find_tags(tree):
         for post in posts:
             if _test_post(post, tree):
                 _posts.append((
-                    '/'.join((year, month, day, post[0].replace('.tmpl', '.html'))),
+                    year, month, day,
+                    '/'.join((year, month, day, post[0][:-len("tmpl")] + "html")),
                     post[1]))
     _posts.sort(reverse=True)
     return _posts