aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu
diff options
context:
space:
mode:
authorSam Whited <sam@samwhited.com>2014-11-07 17:48:30 -0500
committerSam Whited <sam@samwhited.com>2014-11-09 07:00:40 -0500
commite49c2b14edeb3a7a8954493bb033e3679cb7daad (patch)
treedac343f273e53efc14d30a94175c330204a5772c /src/main/java/eu
parent778fb9de6c1b71bbc24d40c0f69830d6a820fb1e (diff)
Fix bug introduced by rebase
Diffstat (limited to 'src/main/java/eu')
-rw-r--r--src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java b/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java
index 566a4782..465d7bc3 100644
--- a/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java
+++ b/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java
@@ -417,11 +417,10 @@ public class MessageAdapter extends ArrayAdapter<Message> {
if (contact != null) {
viewHolder.contact_picture.setImageBitmap(activity.avatarService().get(contact, activity.getPixel(48)));
} else if (item.getConversation().getMode() == Conversation.MODE_MULTI) {
- String name = item.getPresence();
- if (name == null) {
- name = item.getCounterpart();
- }
- viewHolder.contact_picture.setImageBitmap(activity.avatarService().get(name, activity.getPixel(48)));
+ final Jid name = item.getPresence() != null ? item.getPresence() : item.getCounterpart();
+ viewHolder.contact_picture.setImageBitmap(activity.avatarService().get(
+ name.isBareJid() ? name.toString() : name.getResourcepart(),
+ activity.getPixel(48)));
}
} else if (type == SENT) {
viewHolder.contact_picture.setImageBitmap(activity.avatarService().get(item.getConversation().getAccount(), activity.getPixel(48)));