Changeset

8160:5566f82ffea4

mod_welcome: Return the pointer to the root of the stanza, fixes a bug similar to #922.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Tue, 30 May 2017 20:52:22 +0100
parents 8155:f0d847316723
children 8161:31938a0c398f 8163:a55eb6c3b45c
files plugins/mod_welcome.lua
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_welcome.lua	Sat May 27 15:53:30 2017 +0100
+++ b/plugins/mod_welcome.lua	Tue May 30 20:52:22 2017 +0100
@@ -14,8 +14,8 @@
 module:hook("user-registered",
 	function (user)
 		local welcome_stanza =
-			st.message({ to = user.username.."@"..user.host, from = host })
-				:tag("body"):text(welcome_text:gsub("$(%w+)", user));
+			st.message({ to = user.username.."@"..user.host, from = host },
+				welcome_text:gsub("$(%w+)", user));
 		module:send(welcome_stanza);
 		module:log("debug", "Welcomed user %s@%s", user.username, user.host);
 	end);