Skip to content

Commit

Permalink
use visible
Browse files Browse the repository at this point in the history
  • Loading branch information
datawhores committed Jul 5, 2024
1 parent 4c8574c commit 602cc3e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion ofscraper/download/download.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
import ofscraper.download.downloadbatch as batchdownloader
import ofscraper.download.downloadnormal as normaldownloader
import ofscraper.utils.args.accessors.read as read_args
import ofscraper.utils.config.data as config_data
import ofscraper.utils.constants as constants
import ofscraper.utils.hash as hash
import ofscraper.utils.settings as settings
Expand Down
4 changes: 2 additions & 2 deletions ofscraper/utils/live/updater.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ def remove_download_job_task(task):
try:
download_job_progress.remove_task(task)
downloads_pending.discard(task)
if len(download_job_progress.tasks) < min_add_visible:
if len(list(filter(lambda x:x.visible,download_job_progress.tasks))) < min_add_visible:
new_task=None
while new_task not in download_job_progress.tasks and downloads_pending:
new_task = downloads_pending.pop()
Expand All @@ -205,7 +205,7 @@ def remove_download_multi_job_task(task):
return
try:
multi_download_job_progress.remove_task(task)
if len(download_job_progress.tasks) < min_add_visible:
if len(list(filter(lambda x:x.visible,download_job_progress.tasks))) < min_add_visible:

new_task=None
while new_task not in download_job_progress.tasks and downloads_pending:
Expand Down

0 comments on commit 602cc3e

Please sign in to comment.