Commit 51e73a2e authored by Daniel Brötzmann's avatar Daniel Brötzmann

MucCapsCache: Add more queries

This adds the following queries for room infos:
is_open, is_password_protected, and is_persistent
parent 780fcfa5
......@@ -505,9 +505,18 @@ def is_subject_change_allowed(self, jid, affiliation):
pass
return allowed
def is_open(self, jid):
return 'muc_membersonly' not in self.cache[jid].features
def is_password_protected(self, jid):
return 'muc_unsecured' not in self.cache[jid].features
def is_anonymous(self, jid):
return 'muc_nonanonymous' not in self.cache[jid].features
def is_persistent(self, jid):
return 'muc_temporary' not in self.cache[jid].features
def get_room_infos(self, jid):
room_info = {}
if jid in self.cache:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment