Skip to content

Instantly share code, notes, and snippets.

@pztrn
Created May 11, 2015 12:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pztrn/017a2d538181fe88becb to your computer and use it in GitHub Desktop.
Save pztrn/017a2d538181fe88becb to your computer and use it in GitHub Desktop.
Prosody's mod_mam patch to get dab history items highlighted in logs
diff -r aed20f9e78c8 mod_mam/mod_mam.lua
--- a/mod_mam/mod_mam.lua Mon Mar 16 16:19:53 2015 +0100
+++ b/mod_mam/mod_mam.lua Mon Mar 23 13:49:03 2015 +0100
@@ -145,6 +145,7 @@ module:hook("iq-set/self/"..xmlns_mam.."
if not is_stanza(item) then
item = st.deserialize(item);
end
+ if not item then module:log("error", "item %s is %s", id, tostring(item)); end
item.attr.xmlns = "jabber:client";
fwd_st:add_child(item);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment