Changeset

7960:9a938b785bc5

mod_saslauth: Switch to hook_tag from hook_stanza which was renamed in 2087d42f1e77
author Kim Alvefur <zash@zash.se>
date Mon, 06 Mar 2017 15:56:12 +0100
parents 7959:3941d609ff85
children 7961:ff556d010225
files plugins/mod_saslauth.lua
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_saslauth.lua	Mon Mar 06 15:55:37 2017 +0100
+++ b/plugins/mod_saslauth.lua	Mon Mar 06 15:56:12 2017 +0100
@@ -82,7 +82,7 @@
 	return true;
 end
 
-module:hook_stanza(xmlns_sasl, "success", function (session, stanza)
+module:hook_tag(xmlns_sasl, "success", function (session, stanza)
 	if session.type ~= "s2sout_unauthed" or session.external_auth ~= "attempting" then return; end
 	module:log("debug", "SASL EXTERNAL with %s succeeded", session.to_host);
 	session.external_auth = "succeeded"
@@ -93,7 +93,7 @@
 	return true;
 end)
 
-module:hook_stanza(xmlns_sasl, "failure", function (session, stanza)
+module:hook_tag(xmlns_sasl, "failure", function (session, stanza)
 	if session.type ~= "s2sout_unauthed" or session.external_auth ~= "attempting" then return; end
 
 	local text = stanza:get_child_text("text");
@@ -114,7 +114,7 @@
 	return true;
 end, 500)
 
-module:hook_stanza("http://etherx.jabber.org/streams", "features", function (session, stanza)
+module:hook_tag("http://etherx.jabber.org/streams", "features", function (session, stanza)
 	if session.type ~= "s2sout_unauthed" or not session.secure then return; end
 
 	local mechanisms = stanza:get_child("mechanisms", xmlns_sasl)