summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTed Trask <ttrask01@yahoo.com>2008-04-28 15:24:27 +0000
committerTed Trask <ttrask01@yahoo.com>2008-04-28 15:24:27 +0000
commit4d829b96824277cb506d89f30a5d76f2c93d89b2 (patch)
treea099c2574a06486f63641a690fae888ddc94b5cb
parentc8c6d7d30c0a2b6d0ea1cb85f59ac77fe56fc0b4 (diff)
downloadacf-squid-4d829b96824277cb506d89f30a5d76f2c93d89b2.tar.bz2
acf-squid-4d829b96824277cb506d89f30a5d76f2c93d89b2.tar.xz
Changed error redir code to use redirect function instead
git-svn-id: svn://svn.alpinelinux.org/acf/squid/trunk@1051 ab2d0c66-481e-0410-8bed-d214d4d58bed
-rw-r--r--squid-controller.lua12
1 files changed, 3 insertions, 9 deletions
diff --git a/squid-controller.lua b/squid-controller.lua
index 6f69caa..ebc6133 100644
--- a/squid-controller.lua
+++ b/squid-controller.lua
@@ -7,17 +7,13 @@ default_action = "basic"
dep = function( self )
if self.model.dependancy_ok() then
- self.conf.type = "redir"
- self.conf.action = "basic"
- error(self.conf)
+ redirect(self)
end
if self.clientdata.cmd then
if self.clientdata.cmd == "create file" then
self.model.create_cfg_from_template()
- self.conf.type = "redir"
- self.conf.action = "basic"
- error(self.conf)
+ redirect(self)
end
end
@@ -36,9 +32,7 @@ basic = function( self )
}
if not self.model.dependancy_ok() then
- self.conf.type = "redir"
- self.conf.action = "dep"
- error(self.conf)
+ redirect(self, "dep")
end
local service = { message="", status="", error="" }