diff --git a/src/common/connection.py b/src/common/connection.py index 60e266043..c6daf899e 100644 --- a/src/common/connection.py +++ b/src/common/connection.py @@ -1058,7 +1058,7 @@ class Connection(ConnectionHandlers): if keyID == 'UNKNOWN': error = _('Neither the remote presence is signed, nor a key was assigned.') elif keyID[8:] == 'MISMATCH': - error = _('The contact\'s key (%s) does not match the key assigned in Gajim.' % keyID[:8]) + error = _('The contact\'s key (%s) does not match the key assigned in Gajim.' % keyID[:8]) else: #encrypt msgenc, error = self.gpg.encrypt(msg, [keyID]) @@ -1072,7 +1072,7 @@ class Connection(ConnectionHandlers): else: # Encryption failed, do not send message tim = localtime() - self.dispatch('MSGNOTSENT', (jid, error, msgtxt, tim)) + self.dispatch('MSGNOTSENT', (jid, error, msgtxt, tim, session)) return 3 if msgtxt and not xhtml and gajim.config.get( 'rst_formatting_outgoing_messages'): diff --git a/src/common/zeroconf/connection_zeroconf.py b/src/common/zeroconf/connection_zeroconf.py index d306d199b..18f4250b6 100644 --- a/src/common/zeroconf/connection_zeroconf.py +++ b/src/common/zeroconf/connection_zeroconf.py @@ -393,7 +393,7 @@ class ConnectionZeroconf(ConnectionHandlersZeroconf): else: # Encryption failed, do not send message tim = time.localtime() - self.dispatch('MSGNOTSENT', (jid, error, msgtxt, tim)) + self.dispatch('MSGNOTSENT', (jid, error, msgtxt, tim, session)) return 3 if type == 'chat': diff --git a/src/gajim.py b/src/gajim.py index 1e20defad..433027893 100755 --- a/src/gajim.py +++ b/src/gajim.py @@ -1014,9 +1014,9 @@ class Interface: helpers.play_sound('message_sent') def handle_event_msgnotsent(self, account, array): - #('MSGNOTSENT', account, (jid, ierror_msg, msg, time)) + #('MSGNOTSENT', account, (jid, ierror_msg, msg, time, session)) msg = _('error while sending %s ( %s )') % (array[2], array[1]) - self.roster.on_message(array[0], msg, array[3], account, + array[4].roster_message(array[0], msg, array[3], account, msg_type='error') def handle_event_subscribe(self, account, array):