summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--freeswitch-model.lua10
1 files changed, 5 insertions, 5 deletions
diff --git a/freeswitch-model.lua b/freeswitch-model.lua
index e42fd1f..610d4df 100644
--- a/freeswitch-model.lua
+++ b/freeswitch-model.lua
@@ -29,11 +29,11 @@ get_status = function()
return modelfunctions.getstatus(processname, packagename, "Freeswitch Status")
end
-function get_startstop(clientdata)
+function get_startstop(self, clientdata)
return modelfunctions.get_startstop(processname)
end
-function startstop_service(startstop, action)
+function startstop_service(self, startstop, action)
return modelfunctions.startstop_service(startstop, action)
end
@@ -48,8 +48,8 @@ get_file = function(filename)
return modelfunctions.getfiledetails(filename, is_valid_filename)
end
-update_file = function(filedetails)
- local ret = modelfunctions.setfiledetails(filedetails, is_valid_filename)
+update_file = function(self, filedetails)
+ local ret = modelfunctions.setfiledetails(self, filedetails, is_valid_filename)
if not ret.errtxt then
posix.chmod(filedetails.value.filename.value, "rw-------")
posix.chown(filedetails.value.filename.value, posix.getpasswd("freeswitch", "uid") or 0, posix.getpasswd("freeswitch", "gid") or 0)
@@ -75,7 +75,7 @@ function getnewfile()
return cfe({ type="group", value={filename=filename}, label="Freeswitch File" })
end
-function createfile(filedetails)
+function createfile(self, filedetails)
local success = true
local path = string.match(filedetails.value.filename.value, "^%s*(.*%S)%s*$") or ""
if not string.find(path, "/") then