Comparison

mod_mam/mod_mam.lua @ 671:74efb2db00a6

mod_mam: From the spec: servers SHOULD NOT archive messages that do not have a <body/> child tag.
author Thijs Alkemade <thijsalkemade@gmail.com>
date Thu, 24 May 2012 22:29:17 +0200
parent 666:b42b75f3bda0
child 672:8ae5317ba032
comparison
equal deleted inserted replaced
670:9d8efb804a00 671:74efb2db00a6
204 orig_to = orig_to or orig_from; -- Weird corner cases 204 orig_to = orig_to or orig_from; -- Weird corner cases
205 205
206 -- Don't store messages of these types 206 -- Don't store messages of these types
207 if orig_type == "error" 207 if orig_type == "error"
208 or orig_type == "headline" 208 or orig_type == "headline"
209 or orig_type == "groupchat" then 209 or orig_type == "groupchat"
210 or not stanza:get_child("body") then
210 return; 211 return;
211 -- TODO Maybe headlines should be configurable? 212 -- TODO Maybe headlines should be configurable?
212 -- TODO Write a mod_mam_muc for groupchat messages. 213 -- TODO Write a mod_mam_muc for groupchat messages.
213 end 214 end
214 215