Skip to content

Commit

Permalink
fetch splace tolerance
Browse files Browse the repository at this point in the history
  • Loading branch information
ryichsecondary committed Jan 27, 2024
1 parent 9bb5570 commit ab5e9ce
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions fetch.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ def download( root, entry, watch_dir ):
while True:
for file in os.listdir(watch_dir):
if file.endswith('.pdf') and file not in save_file_list:
if ' ' in file:
new_file = file.replace(' ', '_')
shutil.move(os.path.join(watch_dir,file),os.path.join(watch_dir,new_file))
file = new_file
tmp_path = os.path.join(watch_dir,file)
break
if tmp_path:
Expand Down

0 comments on commit ab5e9ce

Please sign in to comment.