Skip to content

Commit

Permalink
fix double parsing by accident
Browse files Browse the repository at this point in the history
  • Loading branch information
pirate committed Feb 5, 2019
1 parent 1ca27a6 commit ce25794
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions archivebox/archive.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,8 +186,7 @@ def update_archive(archive_path, links, source=None, resume=None, append=True):
source = save_source(stdin_raw_text)

# Step 1: Parse the links and dedupe them with existing archive
links = merge_links(archive_path=out_dir, import_path=source, only_new=False)
new_links = merge_links(archive_path=out_dir, import_path=source, only_new=True)
links = merge_links(archive_path=out_dir, import_path=source, only_new=ONLY_NEW)

# Step 2: Write new index
write_links_index(out_dir=out_dir, links=links)
Expand All @@ -196,7 +195,4 @@ def update_archive(archive_path, links, source=None, resume=None, append=True):
# cleanup_archive(out_dir, links)

# Step 4: Run the archive methods for each link
if ONLY_NEW:
update_archive(out_dir, new_links, source=source, resume=resume, append=True)
else:
update_archive(out_dir, links, source=source, resume=resume, append=True)
update_archive(out_dir, links, source=source, resume=resume, append=True)

0 comments on commit ce25794

Please sign in to comment.