Skip to content

Commit

Permalink
Merge d0c1804 into a496b26
Browse files Browse the repository at this point in the history
  • Loading branch information
LilSpazJoekp committed Feb 22, 2021
2 parents a496b26 + d0c1804 commit 9efd5df
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions asyncpraw/reddit.py
Expand Up @@ -617,11 +617,11 @@ def info(

api_parameter_name = "id" if is_using_fullnames else "sr_name"

async def generator(fullnames):
async def generator(names):
if is_using_fullnames:
iterable = iter(ids_or_names)
iterable = iter(names)
else:
iterable = iter([str(item) for item in ids_or_names])
iterable = iter([str(item) for item in names])
while True:
chunk = list(islice(iterable, 100))
if not chunk:
Expand All @@ -630,7 +630,7 @@ async def generator(fullnames):
for result in await self.get(API_PATH["info"], params=params):
yield result

return generator(fullnames)
return generator(ids_or_names)

async def generator(url):
params = {"url": url}
Expand Down

0 comments on commit 9efd5df

Please sign in to comment.