1
0
mirror of https://github.com/instaloader/instaloader.git synced 2024-08-17 12:19:38 +02:00

Use lowercase hashtags and profile names

Since both hashtags and profile names are case insensitive, this might
be a useful normalization and could workaround some user-induced bugs.
This commit is contained in:
Alexander Graf 2017-08-19 18:26:42 +02:00
parent ee9993d7c2
commit 9ee98a2925

View File

@ -993,6 +993,7 @@ class Instaloader:
:param filter_func: function(post), which returns True if given picture should be downloaded
:param fast_update: If true, abort when first already-downloaded picture is encountered
"""
hashtag = hashtag.lower()
count = 1
for post in self.get_hashtag_posts(hashtag):
if max_count is not None and count > max_count:
@ -1087,6 +1088,7 @@ class Instaloader:
download_stories: bool = False, download_stories_only: bool = False,
filter_func: Optional[Callable[[Post], bool]] = None) -> None:
"""Download one profile"""
name = name.lower()
# Get profile main page json
profile_metadata = None