Helpers in custom CakeErrorController are lost

Since many exceptions do not have its own 'template' file, customized
APP/Controller/CakeErrorController with its own list of helpers could be
ignored.

This happens becase ExceptionRenderer is forced to to use _outputMessageSafe
when a template is missing.  This causes Controller::$helpers to be reset with
default values.
This commit is contained in:
Rachman Chavik 2012-06-01 11:42:55 +07:00
parent 483d7124dd
commit 07d9a75fcb
6 changed files with 94 additions and 0 deletions

View file

@ -0,0 +1,14 @@
<?php
App::uses('CakeErrorController', 'Controller');
class TestAppsErrorController extends CakeErrorController {
public $helpers = array(
'Html',
'Session',
'Form',
'Banana',
);
}