summaryrefslogtreecommitdiffstats
path: root/clamsmtp-controller.lua
diff options
context:
space:
mode:
authorTed Trask <ttrask01@yahoo.com>2013-10-18 20:10:54 +0000
committerTed Trask <ttrask01@yahoo.com>2013-10-18 20:10:54 +0000
commit99fb287a390e20366f64a9ca3a8e9948a69ad2b2 (patch)
tree8c7335c17e35cea8e8b476f9d31d24e7efc9a565 /clamsmtp-controller.lua
parent4f741f028bcecdcb11da76ffd3156ca0dac87870 (diff)
downloadacf-clamsmtp-99fb287a390e20366f64a9ca3a8e9948a69ad2b2.tar.bz2
acf-clamsmtp-99fb287a390e20366f64a9ca3a8e9948a69ad2b2.tar.xz
Remove all calls to 'module' in preparation for move to Lua 5.2
Use mymodule parameter for module definition. This was also helpful in revealing places where the code relied on the global environment.
Diffstat (limited to 'clamsmtp-controller.lua')
-rw-r--r--clamsmtp-controller.lua14
1 files changed, 8 insertions, 6 deletions
diff --git a/clamsmtp-controller.lua b/clamsmtp-controller.lua
index 3230fb9..e51af13 100644
--- a/clamsmtp-controller.lua
+++ b/clamsmtp-controller.lua
@@ -1,19 +1,21 @@
-module(..., package.seeall)
+local mymodule = {}
-default_action = "status"
+mymodule.default_action = "status"
-function status(self)
+function mymodule.status(self)
return self.model.getstatus()
end
-function startstop(self)
+function mymodule.startstop(self)
return self.handle_form(self, self.model.get_startstop, self.model.startstop_service, self.clientdata)
end
-function details(self)
+function mymodule.details(self)
return self.model.getstatusdetails()
end
-function expert(self)
+function mymodule.expert(self)
return self.handle_form(self, self.model.get_filedetails, self.model.update_filedetails, self.clientdata, "Save", "Edit ClamSMTP Config", "Configuration Set")
end
+
+return mymodule