Commit 972cd6cc authored by Philipp Hörist's avatar Philipp Hörist

UserNickname: Add set_access_model()

parent 9cb34733
Pipeline #6881 passed with stages
in 4 minutes and 52 seconds
......@@ -112,3 +112,14 @@ class Nickname(BaseModule):
force_node_options=True)
yield finalize(task, result)
@iq_request_task
def set_access_model(self, public):
task = yield
access_model = 'open' if public else 'presence'
result = yield self._client.get_module('PubSub').set_access_model(
Namespace.NICK, access_model)
yield finalize(task, result)
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