prevent traceback when trying to print error message in a non existing message window. Fixes #5036
This commit is contained in:
parent
7d725fc1ab
commit
07d552b656
1 changed files with 4 additions and 0 deletions
|
@ -953,6 +953,10 @@ class Interface:
|
|||
#('MSGNOTSENT', account, (jid, ierror_msg, msg, time, session))
|
||||
msg = _('error while sending %(message)s ( %(error)s )') % {
|
||||
'message': array[2], 'error': array[1]}
|
||||
if not array[4]:
|
||||
# No session. This can happen when sending a message from gajim-remote
|
||||
log.warn(msg)
|
||||
return
|
||||
array[4].roster_message(array[0], msg, array[3], account,
|
||||
msg_type='error')
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue