From 9ee98a29254e55454d37565b5456442d03c35f66 Mon Sep 17 00:00:00 2001 From: Alexander Graf Date: Sat, 19 Aug 2017 18:26:42 +0200 Subject: [PATCH] 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. --- instaloader.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/instaloader.py b/instaloader.py index 1a2e08f..f3cffee 100755 --- a/instaloader.py +++ b/instaloader.py @@ -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