diff --git a/osu.Game/Users/Drawables/DrawableAvatar.cs b/osu.Game/Users/Drawables/DrawableAvatar.cs
index 483106d3f4..155f63dc18 100644
--- a/osu.Game/Users/Drawables/DrawableAvatar.cs
+++ b/osu.Game/Users/Drawables/DrawableAvatar.cs
@@ -14,13 +14,13 @@ namespace osu.Game.Users.Drawables
[LongRunningLoad]
public class DrawableAvatar : Sprite
{
- private readonly APIUser user;
+ private readonly IUser user;
///
/// A simple, non-interactable avatar sprite for the specified user.
///
/// The user. A null value will get a placeholder avatar.
- public DrawableAvatar(APIUser user = null)
+ public DrawableAvatar(IUser user = null)
{
this.user = user;
@@ -33,10 +33,10 @@ namespace osu.Game.Users.Drawables
[BackgroundDependencyLoader]
private void load(LargeTextureStore textures)
{
- if (user != null && user.Id > 1)
+ if (user != null && user.OnlineID > 1)
// TODO: The fallback here should not need to exist. Users should be looked up and populated via UserLookupCache or otherwise
// in remaining cases where this is required (chat tabs, local leaderboard), at which point this should be removed.
- Texture = textures.Get(user.AvatarUrl ?? $@"https://a.ppy.sh/{user.Id}");
+ Texture = textures.Get((user as APIUser)?.AvatarUrl ?? $@"https://a.ppy.sh/{user.OnlineID}");
Texture ??= textures.Get(@"Online/avatar-guest");
}