mod_mam: Clarify condition presendence
authorKim Alvefur <zash@zash.se>
Wed, 09 Dec 2015 14:00:11 +0100
changeset 1961 ca33cca2e028
parent 1960 1a5be0ecc876
child 1962 eb515fbac198
mod_mam: Clarify condition presendence
mod_mam/mod_mam.lua
--- a/mod_mam/mod_mam.lua	Wed Nov 25 14:40:43 2015 +0100
+++ b/mod_mam/mod_mam.lua	Wed Dec 09 14:00:11 2015 +0100
@@ -224,7 +224,7 @@
 	-- Stanza without 'to' are treated as if it was to their own bare jid
 
 	-- We store chat messages or normal messages that have a body
-	if not(orig_type == "chat" or orig_type == "normal" and stanza:get_child("body") ) then
+	if not(orig_type == "chat" or (orig_type == "normal" and stanza:get_child("body")) ) then
 		module:log("debug", "Not archiving stanza: %s (type)", stanza:top_tag());
 		return;
 	end