about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--src/xmpp/message.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/xmpp/message.c b/src/xmpp/message.c
index 17ef979b..ab4d48c6 100644
--- a/src/xmpp/message.c
+++ b/src/xmpp/message.c
@@ -164,9 +164,12 @@ _message_handler(xmpp_conn_t* const conn, xmpp_stanza_t* const stanza, void* con
 
     } else if (type && g_strcmp0(type, STANZA_TYPE_HEADLINE) == 0) {
         xmpp_stanza_t* event = xmpp_stanza_get_child_by_ns(stanza, STANZA_NS_PUBSUB_EVENT);
+        // TODO: do we want to handle all pubsub here or should additionaly check for STANZA_NS_MOOD?
         if (event) {
             _handle_pubsub(stanza, event);
             return 1;
+        } else {
+            _handle_headline(stanza);
         }
     } else if (type == NULL || g_strcmp0(type, STANZA_TYPE_CHAT) == 0 || g_strcmp0(type, STANZA_TYPE_NORMAL) == 0) {
         // type: chat, normal (==NULL)
@@ -252,8 +255,6 @@ _message_handler(xmpp_conn_t* const conn, xmpp_stanza_t* const stanza, void* con
         if (msg_stanza) {
             _handle_chat(msg_stanza, FALSE, is_carbon, NULL, NULL);
         }
-    } else if (type && g_strcmp0(type, STANZA_TYPE_HEADLINE) == 0) {
-        _handle_headline(stanza);
     } else {
         // none of the allowed types
         char* text;