Mercurial > libervia-backend
diff sat/plugins/plugin_xep_0060.py @ 2643:189e38fb11ff
core: style improvments (90 chars limit)
author | Goffi <goffi@goffi.org> |
---|---|
date | Sun, 29 Jul 2018 18:44:27 +0200 |
parents | 56f94936df1e |
children | 1bf7e89fded0 |
line wrap: on
line diff
--- a/sat/plugins/plugin_xep_0060.py Sun Jul 08 18:38:32 2018 +0200 +++ b/sat/plugins/plugin_xep_0060.py Sun Jul 29 18:44:27 2018 +0200 @@ -520,16 +520,8 @@ raise exceptions.DataError(u"Can't find Item in MAM message element") return item_elt - def _getItems( - self, - service="", - node="", - max_items=10, - item_ids=None, - sub_id=None, - extra_dict=None, - profile_key=C.PROF_KEY_NONE, - ): + def _getItems(self, service="", node="", max_items=10, item_ids=None, sub_id=None, + extra_dict=None, profile_key=C.PROF_KEY_NONE): """Get items from pubsub node @param max_items(int): maximum number of item to get, C.NO_LIMIT for no limit @@ -551,17 +543,8 @@ d.addCallback(self.serItemsData) return d - def getItems( - self, - client, - service, - node, - max_items=None, - item_ids=None, - sub_id=None, - rsm_request=None, - extra=None, - ): + def getItems(self, client, service, node, max_items=None, item_ids=None, sub_id=None, + rsm_request=None, extra=None): """Retrieve pubsub items from a node. @param service (JID, None): pubsub service. @@ -678,28 +661,15 @@ # d_dict[publisher] = self.getItems(service, node, max_items, None, sub_id, rsm, client.profile) # defer.returnValue(d_dict) - def getOptions( - self, - service, - nodeIdentifier, - subscriber, - subscriptionIdentifier=None, - profile_key=C.PROF_KEY_NONE, - ): + def getOptions(self, service, nodeIdentifier, subscriber, subscriptionIdentifier=None, + profile_key=C.PROF_KEY_NONE): client = self.host.getClient(profile_key) return client.pubsub_client.getOptions( service, nodeIdentifier, subscriber, subscriptionIdentifier ) - def setOptions( - self, - service, - nodeIdentifier, - subscriber, - options, - subscriptionIdentifier=None, - profile_key=C.PROF_KEY_NONE, - ): + def setOptions(self, service, nodeIdentifier, subscriber, options, + subscriptionIdentifier=None, profile_key=C.PROF_KEY_NONE): client = self.host.getClient(profile_key) return client.pubsub_client.setOptions( service, nodeIdentifier, subscriber, options, subscriptionIdentifier