mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 12:57:36 +08:00
Add missing null checks
This commit is contained in:
parent
b41fa41c85
commit
2be44188ef
@ -143,6 +143,9 @@ namespace osu.Game.Overlays
|
||||
switch (request)
|
||||
{
|
||||
case GetUserRankingsRequest userRequest:
|
||||
if (userRequest.Response == null)
|
||||
return null;
|
||||
|
||||
switch (userRequest.Type)
|
||||
{
|
||||
case UserRankingsType.Performance:
|
||||
@ -155,7 +158,12 @@ namespace osu.Game.Overlays
|
||||
return null;
|
||||
|
||||
case GetCountryRankingsRequest countryRequest:
|
||||
{
|
||||
if (countryRequest.Response == null)
|
||||
return null;
|
||||
|
||||
return new CountriesTable(1, countryRequest.Response.Countries);
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
|
Loading…
Reference in New Issue
Block a user