Refactor API logic

This commit is contained in:
Andrei Zavatski
2019-11-27 21:56:22 +03:00
parent 2135a7fd7b
commit c546df8a80
9 changed files with 19 additions and 41 deletions

View File

@ -3,13 +3,13 @@
using System.Collections.Generic;
using Newtonsoft.Json;
using osu.Game.Online.API.Requests.Responses;
using osu.Game.Users;
namespace osu.Game.Online.API.Requests
{
public class GetCountriesResponse : ResponseWithCursor
{
[JsonProperty("ranking")]
public List<APICountryRankings> Countries;
public List<CountryStatistics> Countries;
}
}

View File

@ -3,13 +3,13 @@
using System.Collections.Generic;
using Newtonsoft.Json;
using osu.Game.Online.API.Requests.Responses;
using osu.Game.Users;
namespace osu.Game.Online.API.Requests
{
public class GetUsersResponse : ResponseWithCursor
{
[JsonProperty("ranking")]
public List<APIUserRankings> Users;
public List<UserStatistics> Users;
}
}

View File

@ -1,14 +0,0 @@
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using Newtonsoft.Json;
using osu.Game.Users;
namespace osu.Game.Online.API.Requests.Responses
{
public class APICountryRankings : CountryStatistics
{
[JsonProperty]
public Country Country;
}
}

View File

@ -1,14 +0,0 @@
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using Newtonsoft.Json;
using osu.Game.Users;
namespace osu.Game.Online.API.Requests.Responses
{
public class APIUserRankings : UserStatistics
{
[JsonProperty]
public User User;
}
}