1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-27 21:12:56 +08:00

Use global friends list instead of always fetching

This commit is contained in:
Salman Ahmed 2020-12-17 13:33:17 +03:00
parent 449b9a21ae
commit 94175d0532

View File

@ -9,8 +9,6 @@ using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Shapes;
using osu.Game.Graphics.UserInterface;
using osu.Game.Online.API;
using osu.Game.Online.API.Requests;
using osu.Game.Users;
using osuTK;
@ -143,11 +141,11 @@ namespace osu.Game.Overlays.Dashboard.Friends
userListToolbar.SortCriteria.BindValueChanged(_ => recreatePanels());
}
protected override APIRequest<List<User>> CreateRequest() => new GetFriendsRequest();
protected override void OnSuccess(List<User> response)
protected override void PerformFetch()
{
Users = response;
base.PerformFetch();
Users = API.Friends.ToList();
}
private void recreatePanels()