diff options
author | B Stack <bgstack15@gmail.com> | 2020-12-14 10:58:48 -0500 |
---|---|---|
committer | B Stack <bgstack15@gmail.com> | 2020-12-14 10:58:48 -0500 |
commit | 03f2091c2dc80a34d4c497dcbc195be588577def (patch) | |
tree | 303c191a01478566773c591deffb3bfa231fd162 | |
parent | initial commit (diff) | |
download | mbbmlib-03f2091c2dc80a34d4c497dcbc195be588577def.tar.gz mbbmlib-03f2091c2dc80a34d4c497dcbc195be588577def.tar.bz2 mbbmlib-03f2091c2dc80a34d4c497dcbc195be588577def.zip |
only open favicons.sqlite if fetch_icons == True
-rw-r--r-- | mbbmlib.py | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -323,8 +323,9 @@ class Bookmark: raw_bookmarks= conn.execute("SELECT id,type,fk,parent,position,title,keyword_id,folder_type,dateAdded,lastModified,guid FROM moz_bookmarks") raw_places = conn.execute("SELECT id,url,title,rev_host,visit_count,hidden,typed,favicon_id,frecency,last_visit_date,guid,foreign_count,url_hash FROM moz_places") - with sqlite3.connect(icons_file) as conn: - raw_icons = conn.execute("SELECT * FROM moz_icons") + if fetch_icons: + with sqlite3.connect(icons_file) as conn: + raw_icons = conn.execute("SELECT * FROM moz_icons") if browser == "firefox": for row in raw_bookmarks: |