]> git.phdru.name Git - bookmarks_db.git/blobdiff - db2bkmk.py
Fix(Robot): Stop splitting and un-splitting URLs
[bookmarks_db.git] / db2bkmk.py
index c649ae91fe806ab15538012cb9ff8a985f9de255..7d1d9aa19f1c46fdebd47e45f859ab7a7c7e2ba7 100755 (executable)
@@ -92,12 +92,12 @@ def run():
                 href = b.href
                 transl_d = self.transl_d
 
-                if transl_d.has_key(href):
+                if href in transl_d:
                     b.href = transl_d[href]
 
         root_folder.walk_depth(Transl(transl_d))
 
-    outfile = open(output_filename, 'w')
+    outfile = open(output_filename, 'wt', encoding='utf-8')
     root_folder.walk_depth(writer(outfile, prune))
     outfile.close()