]> git.phdru.name Git - bookmarks_db.git/commitdiff
last_visit could be None.
authorOleg Broytman <phd@phdru.name>
Mon, 11 Jul 2011 18:05:58 +0000 (18:05 +0000)
committerOleg Broytman <phd@phdru.name>
Mon, 11 Jul 2011 18:05:58 +0000 (18:05 +0000)
git-svn-id: file:///home/phd/archive/SVN/bookmarks_db/trunk@334 fdd5c36f-1aea-0310-aeeb-c58d7e2b6c23

Writers/bkmk_whtml.py

index 97a17e42cd4f500bce32c4dded37867bd5be3e4a..8b3cd13ebfd53229608b6610b6e5936978348e12 100644 (file)
@@ -48,7 +48,9 @@ class writer_html(Writer):
       self.outfile.write(ind_s*level + "</DL><p>\n")
 
    def bookmark(self, b, level):
-      self.outfile.write(ind_s*(level+1) + '<DT><A HREF="%s" ADD_DATE="%s" LAST_VISIT="%s" LAST_MODIFIED="%s"' % (b.href, b.add_date, b.last_visit, b.last_modified))
+      self.outfile.write(ind_s*(level+1) + '<DT><A HREF="%s" ADD_DATE="%s"' % (b.href, b.add_date))
+      if b.last_visit: self.outfile.write('LAST_VISIT="%s"' % b.last_visit)
+      self.outfile.write('LAST_MODIFIED="%s"' % b.last_modified)
       if BKMK_FORMAT == "MOZILLA":
          if b.keyword: self.outfile.write(' SHORTCUTURL="%s"' % b.keyword)
          if b.icon_href: self.outfile.write(' ICON_URI="%s"' % b.icon_href)