diff options
author | Kim Alvefur <zash@zash.se> | 2012-10-14 22:53:41 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2012-10-14 22:53:41 +0200 |
commit | dbac5db2dabdfdb13632b0b64f59d1c2cd2b77c6 (patch) | |
tree | 0fcfafb96064def71df05ea9765e4141bfc89a1c /plugins/mod_motd.lua | |
parent | 38f89dfe3fb1cff7b6f7dc873881dc439990eb33 (diff) | |
parent | 1dad7f3278cab2865dbfe0719b5b3daff853e2c2 (diff) | |
download | prosody-dbac5db2dabdfdb13632b0b64f59d1c2cd2b77c6.tar.gz prosody-dbac5db2dabdfdb13632b0b64f59d1c2cd2b77c6.zip |
Merge 0.9 -> trunk
Diffstat (limited to 'plugins/mod_motd.lua')
-rw-r--r-- | plugins/mod_motd.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/mod_motd.lua b/plugins/mod_motd.lua index ddde9c78..fea2cb85 100644 --- a/plugins/mod_motd.lua +++ b/plugins/mod_motd.lua @@ -20,7 +20,8 @@ motd_text = motd_text:gsub("^%s*(.-)%s*$", "%1"):gsub("\n%s+", "\n"); -- Strip i 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); |