From c2125f9a8162a18720897949ab7de8c9cd3a134c Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Wed, 23 Jun 2021 10:12:58 +0200 Subject: [PATCH] Always fallback to the guest avatar instead of none Signed-off-by: Joas Schilling --- .../java/com/nextcloud/talk/models/json/chat/ChatMessage.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/src/main/java/com/nextcloud/talk/models/json/chat/ChatMessage.java b/app/src/main/java/com/nextcloud/talk/models/json/chat/ChatMessage.java index e9a130e07..766ed788a 100644 --- a/app/src/main/java/com/nextcloud/talk/models/json/chat/ChatMessage.java +++ b/app/src/main/java/com/nextcloud/talk/models/json/chat/ChatMessage.java @@ -285,7 +285,7 @@ public class ChatMessage implements MessageContentType, MessageContentType.Image public String getAvatar() { if (getActorType().equals("users")) { return ApiUtils.getUrlForAvatarWithName(getActiveUser().getBaseUrl(), actorId, R.dimen.avatar_size); - } else if (getActorType().equals("guests")) { + } else { String apiId = NextcloudTalkApplication.Companion.getSharedApplication().getString(R.string.nc_guest); @@ -293,8 +293,6 @@ public class ChatMessage implements MessageContentType, MessageContentType.Image apiId = getActorDisplayName(); } return ApiUtils.getUrlForAvatarWithNameForGuests(getActiveUser().getBaseUrl(), apiId, R.dimen.avatar_size); - } else { - return null; } } };