Skip to content

Commit

Permalink
Use user-specific config for max TikTok downloads
Browse files Browse the repository at this point in the history
  • Loading branch information
stijn-uva committed Jan 9, 2024
1 parent 588290a commit df2462f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions processors/visualisation/download_tiktok.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def get_options(cls, parent_dataset=None, user=None):
# Update the amount max and help from config
max_number_videos = int(config.get('video-downloader.max', 1000, user=user))
options['amount']['max'] = max_number_videos
options['amount']['help'] = f"No. of images (max {max_number_videos:,})"
options['amount']['help'] = f"No. of videos (max {max_number_videos:,})"

return options

Expand Down Expand Up @@ -174,9 +174,9 @@ def get_options(cls, parent_dataset=None, user=None):
options = cls.options

# Update the amount max and help from config
max_number_images = int(config.get('image-downloader.max', 1000))
max_number_images = int(config.get("image-downloader.max", 1000, user=user))
options['amount']['max'] = max_number_images
options['amount']['help'] = "No. of images (max %s)" % max_number_images
options['amount']['help'] = f"No. of images (max {max_number_images:,})"

return options

Expand Down

0 comments on commit df2462f

Please sign in to comment.