Adding 'action' into View::__get() to make an integration test pass.

This commit is contained in:
mark_story 2010-09-10 23:38:15 -04:00
parent a521291afd
commit 634cea24eb

View file

@ -276,7 +276,7 @@ class View extends Object {
* @access protected
*/
private $__passedVars = array(
'viewVars', 'action', 'autoLayout', 'autoRender', 'ext', 'base', 'webroot',
'viewVars', 'autoLayout', 'autoRender', 'ext', 'base', 'webroot',
'helpers', 'here', 'layout', 'name', 'layoutPath', 'viewPath',
'params', 'request', 'data', 'plugin', 'passedArgs', 'cacheAction'
);
@ -653,6 +653,10 @@ class View extends Object {
if (isset($this->Helpers->{$name})) {
return $this->Helpers->{$name};
}
switch ($name) {
case 'action':
return $this->request->params['action'];
}
return null;
}