aboutsummaryrefslogtreecommitdiffstats
path: root/src/eu
diff options
context:
space:
mode:
authoriNPUTmice <daniel@gultsch.de>2014-07-21 22:57:41 +0200
committeriNPUTmice <daniel@gultsch.de>2014-07-21 22:57:41 +0200
commit66e3ccc2dcd22e2bd7b145b7cbbccccb9366ffcd (patch)
treef90b4b5bf8741f9d0c0b331c71dfa37fc9f57842 /src/eu
parente3ebccc76213beba3bfe692d42533ae99726278c (diff)
save login nick for mucs during join
Diffstat (limited to 'src/eu')
-rw-r--r--src/eu/siacs/conversations/services/XmppConnectionService.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/eu/siacs/conversations/services/XmppConnectionService.java b/src/eu/siacs/conversations/services/XmppConnectionService.java
index edd01ef3..0fecbb35 100644
--- a/src/eu/siacs/conversations/services/XmppConnectionService.java
+++ b/src/eu/siacs/conversations/services/XmppConnectionService.java
@@ -969,6 +969,7 @@ public class XmppConnectionService extends Service {
String nick = conversation.getMucOptions().getProposedNick();
conversation.getMucOptions().setJoinNick(nick);
PresencePacket packet = new PresencePacket();
+ String joinJid = conversation.getMucOptions().getJoinJid();
packet.setAttribute("to",conversation.getMucOptions().getJoinJid());
Element x = new Element("x");
x.setAttribute("xmlns", "http://jabber.org/protocol/muc");
@@ -988,6 +989,10 @@ public class XmppConnectionService extends Service {
}
packet.addChild(x);
sendPresencePacket(account, packet);
+ if (!joinJid.equals(conversation.getContactJid())) {
+ conversation.setContactJid(joinJid);
+ databaseBackend.updateConversation(conversation);
+ }
} else {
account.pendingConferenceJoins.add(conversation);
}