Commit 8fcf325a authored by Ted Trask's avatar Ted Trask
Browse files

Remove trailing whitespace

parent aaada3e6
......@@ -8,7 +8,7 @@ APP_DIST=\
EXTRA_DIST=README Makefile config.mk
DISTFILES=$(APP_DIST) $(EXTRA_DIST)
DISTFILES=$(APP_DIST) $(EXTRA_DIST)
TAR=tar
......
Need to make sure all the validation is correct.
See if can split some of the fields up like the dhcp range.
See if can split some of the fields up like the dhcp range.
Add more configuration options:
dhcp-host
log-dhcp
......
<% local form, viewlibrary, page_info, session = ...
<% local form, viewlibrary, page_info, session = ...
htmlviewfunctions = require("htmlviewfunctions")
%>
......
......@@ -20,12 +20,12 @@ local function update_file (file, search_name, value_in)
if not file or not search_name or search_name == "" then
return file, false
end
-- Since we clear out the value, this prevents us from changing parent's value
local value = value_in
if type(value_in) == "table" then
value = {}
for i,val in ipairs(value_in) do
for i,val in ipairs(value_in) do
value[#value + 1] = val
end
end
......@@ -143,7 +143,7 @@ local function validateconfig(self, config)
function testlist(param, test, errtxt)
if #param.value > 0 then
for i,val in ipairs(param.value) do
for i,val in ipairs(param.value) do
if test(val) then
param.errtxt = errtxt
success = false
......@@ -159,7 +159,7 @@ local function validateconfig(self, config)
success = false
end
end
local interfaces = {}
local interfacescontroller = self:new("alpine-baselayout/interfaces")
local ints = interfacescontroller.model.get_interfaces()
......@@ -180,7 +180,7 @@ local function validateconfig(self, config)
-- validate ip address only if dns filtering is enabled
testtext(config.value.dns_default_address, function(v) return not validator.is_ipv4(v) end, "Invalid IP Address")
end
return success, config
end
......@@ -270,7 +270,7 @@ end
function mymodule.get_startstop(self, clientdata)
return modelfunctions.get_startstop(processname)
end
function mymodule.startstop_service(self, startstop, action)
return modelfunctions.startstop_service(startstop, action)
end
......@@ -319,7 +319,7 @@ function mymodule.setconfig(self, config)
-- dns filtering
local conf_file_value = set_dns_filtering(file, config.value.dns_filtering.value)
file = update_file(file,"conf-file",conf_file_value)
fs.write_file(configfile, file)
fs.write_file(configfile, file)
else
config.errtxt = "Failed to set config"
end
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment