changeset 5169 | ed2d64fb7301 |
parent 5014 | b2006c1cfa85 |
child 5371 | 706206e191e8 |
--- a/plugins/mod_motd.lua Fri Oct 12 18:49:22 2012 +0200 +++ b/plugins/mod_motd.lua Sat Oct 13 15:21:59 2012 +0200 @@ -20,7 +20,8 @@ module:hook("presence/bare", function (event) local session, stanza = event.origin, event.stanza; - if not session.presence and not stanza.attr.type then + if session.username and not session.presence + and not stanza.attr.type and not stanza.attr.to then local motd_stanza = st.message({ to = session.full_jid, from = motd_jid }) :tag("body"):text(motd_text);