mirror of
git://git.psyced.org/git/psyced
synced 2024-08-15 03:25:10 +00:00
xmlquote status updates, minor irc fix
This commit is contained in:
parent
b3563e692c
commit
90ad3e7be4
6 changed files with 41 additions and 16 deletions
|
@ -296,12 +296,24 @@ render(string mc, string data, mapping vars, mixed source) {
|
|||
log_file("XMPP_TODO", "%O %s %s\n", ME, mc, output);
|
||||
#endif
|
||||
} else {
|
||||
// hack for a special case where status update contains <, >
|
||||
// if this kind of problem recurrs, we should quote every
|
||||
// single damn variable
|
||||
if (vars["_description_presence"])
|
||||
vars["_XML_description_presence"] =
|
||||
xmlquote(vars["_description_presence"]);
|
||||
if (stringp(data)) data = xmlquote(data);
|
||||
else if (vars["_action"])
|
||||
data = "/me " + xmlquote(vars["_action"]);
|
||||
output = psyctext(template, vars, data, source);
|
||||
if (!stringp(output) || output=="")
|
||||
return P2(("jabber:w() no output\n"));
|
||||
#if 0
|
||||
if (strstr(output, "r00t") >= 0) {
|
||||
P0(("common:render(%O, %O, %O, %O) -> %O\n", mc,
|
||||
data, vars, source, output))
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#if __EFUN_DEFINED__(convert_charset) && SYSTEM_CHARSET != "UTF-8"
|
||||
if (catch(output = convert_charset(output,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue