diff --git a/src/gajim-remote.py b/src/gajim-remote.py index 06244c7824b40ddd21d8329c6be3c7fcfdd68b03..6673ad9eb3c972c6ee3340c1e9f284c4d65ff099 100755 --- a/src/gajim-remote.py +++ b/src/gajim-remote.py @@ -259,7 +259,7 @@ def __init__(self): def print_result(self, res): ''' Print retrieved result to the output ''' if res is not None: - if self.command in ('open_chat', 'send_message', 'send_single_message', 'start_chat'): + if self.command in ('open_chat', 'send_chat_message', 'send_single_message', 'start_chat'): if self.command in ('send_message', 'send_single_message'): self.argv_len -= 2 diff --git a/src/remote_control.py b/src/remote_control.py index cf754810e6a485083e117a6c73b38f84832d65f7..7f29595687f0f5c962b5a4738b15d3392fc85607 100644 --- a/src/remote_control.py +++ b/src/remote_control.py @@ -195,10 +195,9 @@ def _send_message(self, jid, message, keyID, account, type = 'chat', subject = N keyID = '' connected_account, contact = self.get_account_and_contact(account, jid) - if connected_account: connection = gajim.connections[connected_account] - res = connection.send_message(jid, message, keyID, type, subject) + connection.send_message(jid, message, keyID, type, subject) return True return False