Fix :stories
50a5330fec
breaks `:stories` if userids is None (non-iterable).
This commit is contained in:
parent
7f81985911
commit
bfa5d8ed41
@ -428,8 +428,10 @@ class Instaloader:
|
|||||||
|
|
||||||
if not userids:
|
if not userids:
|
||||||
self.context.log("Retrieving all visible stories...")
|
self.context.log("Retrieving all visible stories...")
|
||||||
|
else:
|
||||||
|
userids = [p if isinstance(p, int) else p.userid for p in userids]
|
||||||
|
|
||||||
for user_story in self.get_stories([p if isinstance(p, int) else p.userid for p in userids]):
|
for user_story in self.get_stories(userids):
|
||||||
name = user_story.owner_username
|
name = user_story.owner_username
|
||||||
self.context.log("Retrieving stories from profile {}.".format(name))
|
self.context.log("Retrieving stories from profile {}.".format(name))
|
||||||
totalcount = user_story.itemcount
|
totalcount = user_story.itemcount
|
||||||
|
Loading…
Reference in New Issue
Block a user