[muc] Only notify() about processed self-presence once
Since notify() is a rather expensive operation, we should only invoke it once. Especially since some servers include 110 in all self presences, not just the initially reflected one on MUC join.
This commit is contained in:
parent
d1273532ce
commit
e39adff40f
|
@ -211,7 +211,8 @@ public class MultiUserChat {
|
||||||
|
|
||||||
switch (presence.getType()) {
|
switch (presence.getType()) {
|
||||||
case available:
|
case available:
|
||||||
if (mucUser.getStatus().contains(MUCUser.Status.PRESENCE_TO_SELF_110)) {
|
if (!processedReflectedSelfPresence
|
||||||
|
&& mucUser.getStatus().contains(MUCUser.Status.PRESENCE_TO_SELF_110)) {
|
||||||
processedReflectedSelfPresence = true;
|
processedReflectedSelfPresence = true;
|
||||||
synchronized (this) {
|
synchronized (this) {
|
||||||
notify();
|
notify();
|
||||||
|
|
Loading…
Reference in New Issue