Diff

util/sasl/external.lua @ 6777:5de6b93d0190

util.*: Remove use of module() function, make all module functions local and return them in a table at the end
author Kim Alvefur <zash@zash.se>
date Sat, 21 Feb 2015 10:36:37 +0100
parent 5687:e879b53e9df8
child 8555:4f0f5b49bb03
line wrap: on
line diff
--- a/util/sasl/external.lua	Mon Aug 10 22:16:05 2015 +0200
+++ b/util/sasl/external.lua	Sat Feb 21 10:36:37 2015 +0100
@@ -1,6 +1,6 @@
 local saslprep = require "util.encodings".stringprep.saslprep;
 
-module "sasl.external"
+local _ENV = nil;
 
 local function external(self, message)
 	message = saslprep(message);
@@ -18,8 +18,10 @@
 	return "success";
 end
 
-function init(registerMechanism)
+local function init(registerMechanism)
 	registerMechanism("EXTERNAL", {"external"}, external);
 end
 
-return _M;
+return {
+	init = init;
+}