aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu/siacs/conversations/parser
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2016-05-26 12:39:31 +0200
committerDaniel Gultsch <daniel@gultsch.de>2016-05-26 12:39:31 +0200
commit841e718d6aaf335d5750170da181a6443c7c8048 (patch)
tree944b471c8a616c2303aee685b29e187f343bd92f /src/main/java/eu/siacs/conversations/parser
parentc4e82eb3f8efb75bba153337755cf53af7a8eb6d (diff)
make newly created conferences private by default
Diffstat (limited to 'src/main/java/eu/siacs/conversations/parser')
-rw-r--r--src/main/java/eu/siacs/conversations/parser/PresenceParser.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/main/java/eu/siacs/conversations/parser/PresenceParser.java b/src/main/java/eu/siacs/conversations/parser/PresenceParser.java
index 2a912a45a..edcd986ed 100644
--- a/src/main/java/eu/siacs/conversations/parser/PresenceParser.java
+++ b/src/main/java/eu/siacs/conversations/parser/PresenceParser.java
@@ -14,6 +14,7 @@ import eu.siacs.conversations.entities.Conversation;
import eu.siacs.conversations.entities.Message;
import eu.siacs.conversations.entities.MucOptions;
import eu.siacs.conversations.entities.Presence;
+import eu.siacs.conversations.generator.IqGenerator;
import eu.siacs.conversations.generator.PresenceGenerator;
import eu.siacs.conversations.services.XmppConnectionService;
import eu.siacs.conversations.xml.Element;
@@ -77,6 +78,15 @@ public class PresenceParser extends AbstractParser implements
} else {
mucOptions.addUser(user);
}
+ if (codes.contains(MucOptions.STATUS_CODE_ROOM_CREATED)) {
+ Log.d(Config.LOGTAG,mucOptions.getAccount().getJid().toBareJid()
+ +": room '"
+ +mucOptions.getConversation().getJid().toBareJid()
+ +"' created. pushing default configuration");
+ mXmppConnectionService.pushConferenceConfiguration(mucOptions.getConversation(),
+ IqGenerator.defaultRoomConfiguration(),
+ null);
+ }
if (mXmppConnectionService.getPgpEngine() != null) {
Element signed = packet.findChild("x", "jabber:x:signed");
if (signed != null) {