mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-12-22 10:37:59 +01:00
[muc] Correctly processes self-presences
The change in52a49769f9
("[muc] Check for self-presence first in presence listener") caused all self-presences (MUC user status 110) to be ignored in the further processing chain eventually invoking checkRoleModifications() and checkAffiliationModifications(). However, some servers (e.g., ejabberd) include 110 not only in the initial presence but in all following, and we ant to process these. Fixes SMACK-918 Fixes:52a49769f9
This commit is contained in:
parent
8736e3e434
commit
d1273532ce
1 changed files with 4 additions and 2 deletions
|
@ -211,13 +211,15 @@ public class MultiUserChat {
|
|||
|
||||
switch (presence.getType()) {
|
||||
case available:
|
||||
Presence oldPresence = occupantsMap.put(from, presence);
|
||||
if (mucUser.getStatus().contains(MUCUser.Status.PRESENCE_TO_SELF_110)) {
|
||||
processedReflectedSelfPresence = true;
|
||||
synchronized (this) {
|
||||
notify();
|
||||
}
|
||||
} else if (oldPresence != null) {
|
||||
}
|
||||
|
||||
Presence oldPresence = occupantsMap.put(from, presence);
|
||||
if (oldPresence != null) {
|
||||
// Get the previous occupant's affiliation & role
|
||||
MUCUser mucExtension = MUCUser.from(oldPresence);
|
||||
MUCAffiliation oldAffiliation = mucExtension.getItem().getAffiliation();
|
||||
|
|
Loading…
Reference in a new issue