Commit 64561bcf authored by mathieui's avatar mathieui
Browse files

Fix an issue on join when the room has no MAM support

The value of the "seconds" attribute was borked, resulting in a
traceback.
parent 1595741e
......@@ -159,7 +159,10 @@ class MucTab(ChatTab):
delta = to_utc(datetime.now()) - to_utc(self.last_connection)
seconds = delta.seconds + delta.days * 24 * 3600
else:
seconds = self._text_buffer.find_last_message()
last_message = self._text_buffer.find_last_message()
seconds = None
if last_message is not None:
seconds = (datetime.now() - last_message.time).seconds
muc.join_groupchat(
self.core,
self.jid.bare,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment