Open frenzibyte opened 3 years ago
Please include the route and the response content you are seeing.
https://osu.ppy.sh/api/v2/beatmapsets/1
:
{
"artist": "Kenji Ninuma",
"artist_unicode": "Kenji Ninuma",
...
"ratings": [
0,
122,
9,
25,
31,
45,
69,
109,
141,
119,
898
],
https://osu.ppy.sh/api/v2/beatmapsets/72
:
{
"artist": "Daft Punk",
"artist_unicode": "Daft Punk",
...
"ratings": [
0,
46,
9,
9,
9,
18,
39,
48,
44,
47,
205
],
This was likely an attempt to make php return a plain array instead of an associative array - except an associative array would have actually been more suitable considering the rating is actually a key-value. Fixing this, however, would be considered a breaking change to not assume ratings
is an array of 0 to 10 values.
Not sure if/when it's worth fixing this. Maybe when we get some kind of API versioning in place..?
this really isn't worth fixing without a breaking change - if there's going to be a breaking change it might as well be fixed to return in a { rating: count }
format.
Not sure if that's something intentional or not, looks to have been worked around osu!lazer-side by just skipping it. Might be something worth fixing here instead?