# HG changeset patch # User Goffi # Date 1396261580 -7200 # Node ID b5b440e6ea160b74015201aa678dd522c96ec58b # Parent 77d8f55fc5f0ee3510239b93f464811f5be205e3 server + browser side, getPresenceStatuses has been renamed diff -r 77d8f55fc5f0 -r b5b440e6ea16 libervia.py --- a/libervia.py Wed Mar 26 14:16:11 2014 +0100 +++ b/libervia.py Mon Mar 31 12:26:20 2014 +0200 @@ -119,7 +119,7 @@ LiberviaJsonProxy.__init__(self, "/json_api", ["getContacts", "addContact", "sendMessage", "sendMblog", "sendMblogComment", "getLastMblogs", "getMassiveLastMblogs", "getMblogComments", "getProfileJid", - "getHistory", "getPresenceStatus", "joinMUC", "mucLeave", "getRoomsJoined", + "getHistory", "getPresenceStatuses", "joinMUC", "mucLeave", "getRoomsJoined", "inviteMUC", "launchTarotGame", "getTarotCardsPaths", "tarotGameReady", "tarotGamePlayCards", "launchRadioCollective", "getMblogs", "getMblogsWithComments", "getWaitingSub", "subscription", "delContact", "updateContact", "getCard", @@ -512,7 +512,7 @@ def _getProfileJidCB(self, jid): self.whoami = JID(jid) #we can now ask our status - self.bridge.call('getPresenceStatus', self._getPresenceStatusCb) + self.bridge.call('getPresenceStatuses', self._getPresenceStatusesCb) #the rooms where we are self.bridge.call('getRoomsJoined', self._getRoomsJoinedCb) #and if there is any subscription request waiting for us @@ -742,7 +742,7 @@ if isinstance(lib_wid, panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid_s: getattr(lib_wid.getGame("RadioCol"), event_name)(*args) - def _getPresenceStatusCb(self, presence_data): + def _getPresenceStatusesCb(self, presence_data): for entity in presence_data: for resource in presence_data[entity]: args = presence_data[entity][resource] diff -r 77d8f55fc5f0 -r b5b440e6ea16 libervia_server/__init__.py --- a/libervia_server/__init__.py Wed Mar 26 14:16:11 2014 +0100 +++ b/libervia_server/__init__.py Mon Mar 31 12:26:20 2014 +0200 @@ -339,10 +339,10 @@ return d - def jsonrpc_getPresenceStatus(self): + def jsonrpc_getPresenceStatuses(self): """Get Presence information for connected contacts""" profile = ISATSession(self.session).profile - return self.sat_host.bridge.getPresenceStatus(profile) + return self.sat_host.bridge.getPresenceStatuses(profile) def jsonrpc_getHistory(self, from_jid, to_jid, size, between): """Return history for the from_jid/to_jid couple"""