瀏覽代碼

fix tag updating

Oz N Tiram 9 年之前
父節點
當前提交
600c358e65
共有 1 個文件被更改,包括 2 次插入3 次删除
  1. 2 3
      blogit2.py

+ 2 - 3
blogit2.py

@@ -416,9 +416,8 @@ def new_build():
             if entry.render():
             if entry.render():
                 entries.append(entry)
                 entries.append(entry)
                 for tag in entry.tags:
                 for tag in entry.tags:
-                    if tag.name not in tags:
-                        tags[tag.name] = tag
-                        tag.posts = [post_id]
+                    tag.posts = [post_id]
+                    tags[tag.name] = tag
             print "     %s" % entry.path
             print "     %s" % entry.path
         except Exception as e:
         except Exception as e:
             print "Found some problem in: ", post
             print "Found some problem in: ", post