X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Ftemplate%2FProfileAccessor.java;h=97be0cd84512dcad02b533701ac5f8a1d2aee2ab;hp=f6056fadb0f197b7b48a8da984d3354bed4e0443;hb=d37c99d835abafa7c36af3f575dbadaa4b5f76c8;hpb=0e3f55050a9a077723d0a355764bd7cf6ffa1860 diff --git a/src/main/java/net/pterodactylus/sone/template/ProfileAccessor.java b/src/main/java/net/pterodactylus/sone/template/ProfileAccessor.java index f6056fa..97be0cd 100644 --- a/src/main/java/net/pterodactylus/sone/template/ProfileAccessor.java +++ b/src/main/java/net/pterodactylus/sone/template/ProfileAccessor.java @@ -60,8 +60,9 @@ public class ProfileAccessor extends ReflectionAccessor { /* not logged in? don’t show custom avatars, then. */ return null; } - if (profile.getSone().equals(currentSone)) { - /* always show your own avatar. */ + Sone remoteSone = profile.getSone(); + if (core.isLocalSone(remoteSone)) { + /* always show your own avatars. */ return profile.getAvatar(); } ShowCustomAvatars showCustomAvatars = currentSone.getOptions(). getEnumOption("ShowCustomAvatars").get(); @@ -72,7 +73,6 @@ public class ProfileAccessor extends ReflectionAccessor { if ((showCustomAvatars == ShowCustomAvatars.ALWAYS) || (avatarId == null)) { return avatarId; } - Sone remoteSone = profile.getSone(); if ((showCustomAvatars == ShowCustomAvatars.FOLLOWED) && currentSone.hasFriend(remoteSone.getId())) { return avatarId; }