Fix muc avatars sometimes not showing split tiles for occupants

This commit is contained in:
fiaxh 2018-11-25 15:55:51 +01:00
parent 22340cb88e
commit d9cbf571b0
2 changed files with 1 additions and 6 deletions

View file

@ -212,11 +212,6 @@ public class MucManager : StreamInteractionModule, Object {
return null;
}
public bool has_avatar(Jid muc_jid, Account account) {
Gee.List<Jid>? full_jids = stream_interactor.get_module(PresenceManager.IDENTITY).get_full_jids(muc_jid, account);
return full_jids != null && full_jids.contains(muc_jid);
}
private Xep.Muc.Flag? get_muc_flag(Account account) {
XmppStream? stream = stream_interactor.get_stream(account);
if (stream != null) {

View file

@ -206,7 +206,7 @@ public class AvatarImage : Misc {
stream_interactor.connection_manager.connection_state_changed.connect(on_connection_changed);
stream_interactor.get_module(RosterManager.IDENTITY).updated_roster_item.connect(on_roster_updated);
}
if (muc_manager.is_groupchat(jid_, account) && !muc_manager.has_avatar(jid_, account)) {
if (muc_manager.is_groupchat(jid_, account) && avatar_manager.get_avatar(account, jid_) == null) {
// Groupchat without avatar
Gee.List<Jid>? occupants = muc_manager.get_other_occupants(jid_, account);
jid = jid_;