I have the following Python code :
currentPlayers = query.getPlayers()
for player in currentPlayers:
return str(player['name'])+" "+str(player['score'])
And I'm getting the following error:
TypeError: list indices must be integers, not str
I've been looking for an error close to mine, but not sure how to do it, never got that error. So yeah, how can I transform it to integers instead of string? I guess the problem comes from str(player['score']).