diff src/plugins/plugin_exp_command_export.py @ 636:7ea6d5a86e58

plugin XEP-0085: Chat State Notifications - new "options" parameter to send chat states - plugin command export: messages without body are now delivered (since all the chat states other than "active" need them)
author souliane <souliane@mailoo.org>
date Thu, 05 Sep 2013 20:48:47 +0200
parents 84a6e83157c2
children 8004c7d4aba7
line wrap: on
line diff
--- a/src/plugins/plugin_exp_command_export.py	Sun Sep 08 19:12:59 2013 +0200
+++ b/src/plugins/plugin_exp_command_export.py	Thu Sep 05 20:48:47 2013 +0200
@@ -107,8 +107,9 @@
         try:
             body = [e for e in message.elements() if e.name == 'body'][0]
         except IndexError:
-            warning("Received message without body")
-            return False
+            # do not block message without body (chat state notification...)
+            warning("No body element found in message, following normal behaviour")
+            return True
 
         mess_data = unicode(body) + '\n'