summaryrefslogtreecommitdiffstats
path: root/tcpproxy-model.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tcpproxy-model.lua')
-rw-r--r--tcpproxy-model.lua16
1 files changed, 8 insertions, 8 deletions
diff --git a/tcpproxy-model.lua b/tcpproxy-model.lua
index 6dc7537..8944754 100644
--- a/tcpproxy-model.lua
+++ b/tcpproxy-model.lua
@@ -200,11 +200,11 @@ end
-- ################################################################################
-- PUBLIC FUNCTIONS
-function mymodule.get_startstop(self, clientdata)
+function mymodule.get_startstop(self, clientdata)
return modelfunctions.get_startstop(processname)
end
-function mymodule.startstop_service(self, startstop, action)
+function mymodule.startstop_service(self, startstop, action)
return modelfunctions.startstop_service(startstop, action)
end
@@ -242,10 +242,10 @@ function mymodule.listsmtpentries(self)
table.insert(entries.value, entry)
end
end
-
+
local reverseaddress = {}
for i,int in ipairs(entries.value) do reverseaddress[int.ipaddr or int.interface] = i end
-
+
config = config or parseconfigfile(fs.read_file(configfile) or "")
local smtpconfig = getsmtpconfig(config)
for i,int in ipairs(smtpconfig) do
@@ -260,7 +260,7 @@ function mymodule.listsmtpentries(self)
table.insert(entries.value, int)
end
end
-
+
return entries
end
@@ -297,7 +297,7 @@ end
function mymodule.updatesmtpentry(self, entry)
local success, entry = validatesmtpentry(entry)
-
+
if success then
local options = parsesmtpcmd(getsmtpcmd(entry.value.ipaddr.value))
@@ -335,7 +335,7 @@ function mymodule.updatesmtpentry(self, entry)
if options[""] ~= "" then
exec[#exec + 1] = options[""]
end
-
+
setsmtpcmd(entry.value.ipaddr.value, table.concat(exec, " "))
else
entry.errtxt = "Failed to set SMTP Proxy Entry"
@@ -416,7 +416,7 @@ function mymodule.delsmtpfile(self, delfile)
delfile.errtxt = "Failed to delete SMTP Proxy File"
delfile.value.filename.errtxt = "Invalid filename"
end
-
+
return delfile
end