Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def get_participants(self):
"""Get team participant info from API."""
self.participant_list = []
self.team_participant_json = extralife_IO.get_JSON(self.team_participant_url)
if self.team_participant_json == 0:
print("couldn't get to URL")
elif len(self.team_participant_json) == 0:
print("No team participants!")
else:
self.participant_list = [TeamParticipant(self.team_participant_json[participant]) for participant in range(0, len(self.team_participant_json))]