changeset 264:27bc5d7732a3

core: fixed default message type
author Goffi <goffi@goffi.org>
date Sun, 23 Jan 2011 14:14:47 +0100
parents bfd01aed0a3a
children b5f1f3dc9ac6
files src/plugins/plugin_misc_maildir.py src/sat.tac
diffstat 2 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/src/plugins/plugin_misc_maildir.py	Sun Jan 23 12:56:09 2011 +0100
+++ b/src/plugins/plugin_misc_maildir.py	Sun Jan 23 14:14:47 2011 +0100
@@ -84,8 +84,8 @@
         @return: False if it's a normal message, True else"""
         for e in message.elements():
             if e.name == "body":
-                type = message['type'] if message.hasAttribute('type') else 'chat' #FIXME: check specs
-                if message['type'] != 'normal':
+                mess_type = message['type'] if message.hasAttribute('type') else 'normal'
+                if mess_type != 'normal':
                     return True
                 self.accessMessageBox("INBOX", profile_key=profile).addMessage(message)
                 return False
--- a/src/sat.tac	Sun Jan 23 12:56:09 2011 +0100
+++ b/src/sat.tac	Sun Jan 23 14:14:47 2011 +0100
@@ -140,8 +140,8 @@
         return
       for e in message.elements():
         if e.name == "body":
-          type = message['type'] if message.hasAttribute('type') else 'chat' #FIXME: check specs
-          self.host.bridge.newMessage(message["from"], e.children[0], type, profile=self.parent.profile)
+          mess_type = message['type'] if message.hasAttribute('type') else 'normal'
+          self.host.bridge.newMessage(message["from"], e.children[0], mess_type, profile=self.parent.profile)
           self.host.memory.addToHistory(self.parent.jid, jid.JID(message["from"]), self.parent.jid, "chat", e.children[0])
           break