Fixed return value for Controller::setAction

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@6508 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
the_undefined 2008-03-04 23:44:50 +00:00
parent 12466ebe43
commit 885b41808f

View file

@ -594,13 +594,14 @@ class Controller extends Object {
* @param string $action The new action to be redirected to
* @param mixed Any other parameters passed to this method will be passed as
* parameters to the new action.
* @return mixed Returns the return value of the called action
* @access public
*/
function setAction($action) {
$this->action = $action;
$args = func_get_args();
unset($args[0]);
call_user_func_array(array(&$this, $action), $args);
return call_user_func_array(array(&$this, $action), $args);
}
/**
* Controller callback to tie into Auth component.