Skip to content

Commit

Permalink
Don't add empty data when getting org GitHub repos
Browse files Browse the repository at this point in the history
  • Loading branch information
vsoch authored Oct 22, 2023
1 parent 6343330 commit cb0cb3a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion rse/main/parsers/github.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,9 @@ def get_org_repos(self, org, paginate=True, delay=None):
if data and paginate:
url = original_url + "&page=%s" % page

repos = repos + data
# If a request goes wrong and we don't get data, skip
if data:
repos = repos + data
page += 1
# Sleep for a random amount of time to give a rest!
sleep(delay or random.choice(range(1, 10)) * 0.1)
Expand Down

0 comments on commit cb0cb3a

Please sign in to comment.