diff options
| author | schneefux <schneefux+commit@schneefux.xyz> | 2017-12-13 17:28:14 +0100 |
|---|---|---|
| committer | schneefux <schneefux+commit@schneefux.xyz> | 2017-12-13 17:28:14 +0100 |
| commit | a27449646b8660399b42d1a5448d788de2b3123e (patch) | |
| tree | 3e1eaa9245a9712449648f76730e96ec6e3180a8 | |
| parent | 872a4a18c46bc90a3327edcbdbf0b94e9eb3a0ba (diff) | |
| download | processor-a27449646b8660399b42d1a5448d788de2b3123e.tar.gz processor-a27449646b8660399b42d1a5448d788de2b3123e.zip | |
API: rename games -> gamesPlayedrelease/2.21.0
| -rw-r--r-- | worker.js | 13 |
1 files changed, 7 insertions, 6 deletions
@@ -82,12 +82,13 @@ function flatten(o) { o.rank_points_blitz = o.rank_points.blitz || 0; delete o.rank_points; } - if ("games" in o) { - o.played_ranked = o.games.ranked || 0; - o.played_casual = o.games.casual || 0; - o.played_blitz = o.games.blitz || 0; - o.played_aral = o.games.aral || 0; - delete o.games; + if ("games_played" in o) { + o.played_ranked = o.games_played.ranked || 0; + o.played_casual = o.games_played.casual || 0; + o.played_blitz = o.games_played.blitz || 0; + o.played_blitz_rounds = o.games_played.blitz_rounds || 0; + o.played_aral = o.games_played.aral || 0; + delete o.games_played; } delete o.type; return o; |
