mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
case correction, fixes ExceptionRenderer test
This commit is contained in:
parent
d63b4df10c
commit
e95d6a3b10
2 changed files with 5 additions and 5 deletions
|
@ -26,7 +26,7 @@ class CakeErrorController extends AppController {
|
|||
parent::__construct($request);
|
||||
$this->constructClasses();
|
||||
$this->Components->trigger('initialize', array(&$this));
|
||||
$this->_set(array('cacheAction' => false, 'viewPath' => 'errors'));
|
||||
$this->_set(array('cacheAction' => false, 'viewPath' => 'Errors'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -39,12 +39,12 @@ App::uses('Router', 'Routing');
|
|||
*
|
||||
* #### Using AppController::appError();
|
||||
*
|
||||
* This controller method is called instead of the default exception handling. It receives the
|
||||
* This controller method is called instead of the default exception handling. It receives the
|
||||
* thrown exception as its only argument. You should implement your error handling in that method.
|
||||
*
|
||||
* #### Using a subclass of ExceptionRenderer
|
||||
*
|
||||
* Using a subclass of ExceptionRenderer gives you full control over how Exceptions are rendered, you
|
||||
* Using a subclass of ExceptionRenderer gives you full control over how Exceptions are rendered, you
|
||||
* can configure your class in your core.php, with `Configure::write('Exception.renderer', 'MyClass');`
|
||||
* You should place any custom exception renderers in `app/libs`.
|
||||
*
|
||||
|
@ -135,7 +135,7 @@ class ExceptionRenderer {
|
|||
|
||||
/**
|
||||
* Get the controller instance to handle the exception.
|
||||
* Override this method in subclasses to customize the controller used.
|
||||
* Override this method in subclasses to customize the controller used.
|
||||
* This method returns the built in `CakeErrorController` normally, or if an error is repeated
|
||||
* a bare controller will be used.
|
||||
*
|
||||
|
@ -148,7 +148,7 @@ class ExceptionRenderer {
|
|||
$controller = new CakeErrorController(Router::getRequest(false));
|
||||
} catch (Exception $e) {
|
||||
$controller = new Controller(Router::getRequest(false));
|
||||
$controller->viewPath = 'errors';
|
||||
$controller->viewPath = 'Errors';
|
||||
}
|
||||
return $controller;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue