lib: Add method `ActionController::prepareInit()'

As it should not be required for controllers to call the parent's init() method, base controllers should use
prepareInit() in order to prepare the controller initialization.
This commit is contained in:
Eric Lippmann 2014-09-16 09:28:10 +02:00
parent 8bf66425d1
commit f8edb4f220
1 changed files with 13 additions and 0 deletions

View File

@ -91,9 +91,22 @@ class ActionController extends Zend_Controller_Action
}
$this->view->tabs = new Tabs();
$this->prepareInit();
$this->init();
}
/**
* Prepare controller initialization
*
* As it should not be required for controllers to call the parent's init() method, base controllers should use
* prepareInit() in order to prepare the controller initialization.
*
* @see \Zend_Controller_Action()::init() For the controller initialization method.
*/
protected function prepareInit()
{
}
public function Config($file = null)
{
if ($file === null) {