diff --git a/src/common/connection_handlers.py b/src/common/connection_handlers.py index c1b249116..8eb6f783c 100644 --- a/src/common/connection_handlers.py +++ b/src/common/connection_handlers.py @@ -1459,7 +1459,7 @@ class ConnectionHandlers(ConnectionVcard, ConnectionBytestream, ConnectionDisco, has_timestamp = False if msg.timestamp: has_timestamp = True - if subject: + if subject != None: self.dispatch('GC_SUBJECT', (frm, subject, msgtxt, has_timestamp)) else: if not msg.getTag('body'): #no diff --git a/src/common/xmpp/protocol.py b/src/common/xmpp/protocol.py index 735642cb0..1ee8ea96c 100644 --- a/src/common/xmpp/protocol.py +++ b/src/common/xmpp/protocol.py @@ -394,7 +394,7 @@ class Message(Protocol): Protocol.__init__(self, 'message', to=to, typ=typ, attrs=attrs, frm=frm, payload=payload, timestamp=timestamp, xmlns=xmlns, node=node) if body: self.setBody(body) if xhtml: self.setXHTML(xhtml) - if subject: self.setSubject(subject) + if subject != None: self.setSubject(subject) def getBody(self): """ Returns text of the message. """ return self.getTagData('body')