Software /
code /
prosody-modules
Comparison
mod_admin_message/mod_admin_message.lua @ 2636:9ed6d44b9fed
mod_admin_message: Fix invalid character escape (fixes #626)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Wed, 22 Mar 2017 14:35:23 +0100 |
parent | 1594:620cc035ae1e |
child | 2887:65082d91950e |
comparison
equal
deleted
inserted
replaced
2635:4548c3d685b4 | 2636:9ed6d44b9fed |
---|---|
83 | 83 |
84 -- Process the message using admin_telnet's onincoming function | 84 -- Process the message using admin_telnet's onincoming function |
85 admin_telnet.console:process_line(session, body.."\n"); | 85 admin_telnet.console:process_line(session, body.."\n"); |
86 | 86 |
87 -- Strip trailing blank line | 87 -- Strip trailing blank line |
88 session.fulltext = tostring(session.fulltext):gsub("\n\|%s*$", "") | 88 session.fulltext = tostring(session.fulltext):gsub("\n|%s*$", "") |
89 | 89 |
90 -- Send the reply stanza | 90 -- Send the reply stanza |
91 local reply_stanza = st.message({ from = host, to = userjid, | 91 local reply_stanza = st.message({ from = host, to = userjid, |
92 type = "chat" }); | 92 type = "chat" }); |
93 reply_stanza = reply_stanza:body(session.fulltext); | 93 reply_stanza = reply_stanza:body(session.fulltext); |