summaryrefslogtreecommitdiffstats
path: root/app/acf-util/password-controller.lua
diff options
context:
space:
mode:
authorTed Trask <ttrask01@yahoo.com>2012-02-23 15:27:32 +0000
committerTed Trask <ttrask01@yahoo.com>2012-02-23 15:27:32 +0000
commit94e98d227ef5e21485bafd859b23d5d709ba79a8 (patch)
treef783f44685aaa33c0c127b992f74aad965deefad /app/acf-util/password-controller.lua
parentefdd93c695574329b3d98455a0a88320a1c79d5b (diff)
downloadacf-core-94e98d227ef5e21485bafd859b23d5d709ba79a8.tar.bz2
acf-core-94e98d227ef5e21485bafd859b23d5d709ba79a8.tar.xz
Removed controllerfunction.lua and moved handle_form and handle_clientdata into mvc.lua
mvc.lua has generic versions of the functions, overridden in acf_www and acf_cli with customizations
Diffstat (limited to 'app/acf-util/password-controller.lua')
-rw-r--r--app/acf-util/password-controller.lua7
1 files changed, 3 insertions, 4 deletions
diff --git a/app/acf-util/password-controller.lua b/app/acf-util/password-controller.lua
index 37e5ced..336f6f4 100644
--- a/app/acf-util/password-controller.lua
+++ b/app/acf-util/password-controller.lua
@@ -1,5 +1,4 @@
module(..., package.seeall)
-require("controllerfunctions")
require("roles")
default_action = "editme"
@@ -11,7 +10,7 @@ end
function editme(self)
-- just to make sure can't modify any other user from this action
self.clientdata.userid = self.sessiondata.userinfo.userid
- return controllerfunctions.handle_form(self, function()
+ return self.handle_form(self, function()
local value = self.model.read_user(self, self.sessiondata.userinfo.userid)
-- We don't allow a user to modify his own roles
-- Since they can't modify roles, we should restrict the available options for home
@@ -44,7 +43,7 @@ function editme(self)
end
function edituser(self)
- return controllerfunctions.handle_form(self, function()
+ return self.handle_form(self, function()
return self.model.read_user(self, self.clientdata.userid)
end, function(value)
-- If password and password_confirm are blank, don't set them
@@ -65,7 +64,7 @@ function edituser(self)
end
function newuser(self)
- return controllerfunctions.handle_form(self, function()
+ return self.handle_form(self, function()
return self.model.read_user(self)
end, function(value)
return self.model.create_user(self, value)