ScoreSaber / scoresaber-frontend

MIT License
87 stars 16 forks source link

Search promises fix with potential errors #72

Closed nomuffn closed 2 years ago

nomuffn commented 2 years ago

If no players are found within the search, the api returns a 404 Error and the Promise.all() bails out and would therefore not load the leaderboards anymore. Promise.allSettled() should instead do the trick here: https://stackoverflow.com/questions/30362733/handling-errors-in-promise-all.