diff options
author | mathieui <mathieui@mathieui.net> | 2011-11-09 14:07:10 +0100 |
---|---|---|
committer | mathieui <mathieui@mathieui.net> | 2011-11-09 14:07:10 +0100 |
commit | cc7f010aed20c726b69f99b58f9c7578e5ff1dc1 (patch) | |
tree | 84c5511581d6d8cf63ae72bb4fd12b44add57873 /src/core.py | |
parent | 98b9506983b57d7da1f5543f8cefd68dca0827ae (diff) | |
download | poezio-cc7f010aed20c726b69f99b58f9c7578e5ff1dc1.tar.gz poezio-cc7f010aed20c726b69f99b58f9c7578e5ff1dc1.tar.bz2 poezio-cc7f010aed20c726b69f99b58f9c7578e5ff1dc1.tar.xz poezio-cc7f010aed20c726b69f99b58f9c7578e5ff1dc1.zip |
Do not create a private tab when receiving only a chatstate
Diffstat (limited to 'src/core.py')
-rw-r--r-- | src/core.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/core.py b/src/core.py index e2ba8ce1..f1f48a2b 100644 --- a/src/core.py +++ b/src/core.py @@ -560,13 +560,14 @@ class Core(object): jid = message['from'] nick_from = jid.resource room_from = jid.bare + body = xhtml.get_body_from_message_stanza(message) tab = self.get_tab_by_name(jid.full, tabs.PrivateTab) # get the tab with the private conversation if not tab: # It's the first message we receive: create the tab - tab = self.open_private_window(room_from, nick_from, False) + if body: + tab = self.open_private_window(room_from, nick_from, False) if not tab: return self.events.trigger('private_msg', message) - body = xhtml.get_body_from_message_stanza(message) if not body: return tab.add_message(body, time=None, nickname=nick_from, |