Diff

plugins/mod_saslauth.lua @ 10111:0f335815244f

plugins: Remove tostring call from logging Taken care of by loggingmanager now Mass-rewrite using lua pattern like `tostring%b()`
author Kim Alvefur <zash@zash.se>
date Tue, 30 Jul 2019 02:29:36 +0200
parent 9993:02a41315d275
child 10333:780905981542
line wrap: on
line diff
--- a/plugins/mod_saslauth.lua	Tue Jul 30 02:24:06 2019 +0200
+++ b/plugins/mod_saslauth.lua	Tue Jul 30 02:29:36 2019 +0200
@@ -14,7 +14,6 @@
 local base64 = require "util.encodings".base64;
 
 local usermanager_get_sasl_handler = require "core.usermanager".get_sasl_handler;
-local tostring = tostring;
 
 local secure_auth_only = module:get_option_boolean("c2s_require_encryption", module:get_option_boolean("require_encryption", false));
 local allow_unencrypted_plain_auth = module:get_option_boolean("allow_unencrypted_plain_auth", false)
@@ -77,7 +76,7 @@
 	local status, ret, err_msg = session.sasl_handler:process(text);
 	status, ret, err_msg = handle_status(session, status, ret, err_msg);
 	local s = build_reply(status, ret, err_msg);
-	log("debug", "sasl reply: %s", tostring(s));
+	log("debug", "sasl reply: %s", s);
 	session.send(s);
 	return true;
 end