From 6e0cfc72675d2bf4a5de0a86567520257e092671 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Fri, 11 May 2012 14:57:29 +0100 Subject: mod_c2s: Another lurking string.format squashed. --- plugins/mod_c2s.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/mod_c2s.lua b/plugins/mod_c2s.lua index 69f2298f..55c53e2d 100644 --- a/plugins/mod_c2s.lua +++ b/plugins/mod_c2s.lua @@ -17,7 +17,6 @@ local sm_new_session, sm_destroy_session = sessionmanager.new_session, sessionma local uuid_generate = require "util.uuid".generate; local xpcall, tostring, type = xpcall, tostring, type; -local format = string.format; local traceback = debug.traceback; local xmlns_xmpp_streams = "urn:ietf:params:xml:ns:xmpp-streams"; @@ -54,8 +53,9 @@ function stream_callbacks.streamopened(session, attr) return; end - send(""); - send(format("", session.streamid, session.host)); + send(""..st.stanza("stream:stream", { + xmlns = 'jabber:client', ["xmlns:stream"] = 'http://etherx.jabber.org/streams'; + id = session.streamid, from = session.host, version = '1.0', ["xml:lang"] = 'en' }):top_tag()); (session.log or log)("debug", "Sent reply to client"); session.notopen = nil; -- cgit v1.2.3