Skip to content

Commit

Permalink
Fix api doc comment errors in Error/
Browse files Browse the repository at this point in the history
  • Loading branch information
markstory committed Jun 1, 2014
1 parent fe20038 commit 86a0713
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 14 deletions.
7 changes: 4 additions & 3 deletions lib/Cake/Error/ErrorHandler.php
Expand Up @@ -102,7 +102,7 @@ class ErrorHandler {
* This will either use custom exception renderer class if configured,
* or use the default ExceptionRenderer.
*
* @param Exception $exception
* @param Exception $exception The exception to render.
* @return void
* @see http://php.net/manual/en/function.set-exception-handler.php
*/
Expand Down Expand Up @@ -132,6 +132,7 @@ public static function handleException(Exception $exception) {

/**
* Generates a formatted error message
*
* @param Exception $exception Exception instance
* @return string Formatted message
*/
Expand Down Expand Up @@ -159,8 +160,8 @@ protected static function _getMessage($exception) {
/**
* Handles exception logging
*
* @param Exception $exception
* @param array $config
* @param Exception $exception The exception to render.
* @param array $config An array of configuration for logging.
* @return boolean
*/
protected static function _log(Exception $exception, $config) {
Expand Down
8 changes: 4 additions & 4 deletions lib/Cake/Error/ExceptionRenderer.php
Expand Up @@ -180,7 +180,7 @@ public function render() {
/**
* Generic handler for the internal framework errors CakePHP can generate.
*
* @param CakeException $error
* @param CakeException $error The exception to render.
* @return void
*/
protected function _cakeError(CakeException $error) {
Expand All @@ -202,7 +202,7 @@ protected function _cakeError(CakeException $error) {
/**
* Convenience method to display a 400 series page.
*
* @param Exception $error
* @param Exception $error The exception to render.
* @return void
*/
public function error400($error) {
Expand All @@ -225,7 +225,7 @@ public function error400($error) {
/**
* Convenience method to display a 500 page.
*
* @param Exception $error
* @param Exception $error The exception to render.
* @return void
*/
public function error500($error) {
Expand All @@ -249,7 +249,7 @@ public function error500($error) {
/**
* Convenience method to display a PDOException.
*
* @param PDOException $error
* @param PDOException $error The exception to render.
* @return void
*/
public function pdoError(PDOException $error) {
Expand Down
20 changes: 13 additions & 7 deletions lib/Cake/Error/exceptions.php
Expand Up @@ -34,9 +34,9 @@ class CakeBaseException extends RuntimeException {
/**
* Get/set the response header to be used
*
* @param string|array $header. An array of header strings or a single header string
* - an associative array of "header name" => "header value"
* - an array of string headers is also accepted
* @param string|array $header An array of header strings or a single header string
* - an associative array of "header name" => "header value"
* - an array of string headers is also accepted
* @param string $value The header value.
* @return array
* @see CakeResponse::header()
Expand Down Expand Up @@ -378,6 +378,12 @@ class MissingConnectionException extends CakeException {

protected $_messageTemplate = 'Database connection "%s" is missing, or could not be created.';

/**
* Constructor
*
* @param string|array $message The error message.
* @param int $code The error code.
*/
public function __construct($message, $code = 500) {
if (is_array($message)) {
$message += array('enabled' => true);
Expand Down Expand Up @@ -587,10 +593,10 @@ class FatalErrorException extends CakeException {
/**
* Constructor
*
* @param string $message
* @param integer $code
* @param string $file
* @param integer $line
* @param string $message The error message.
* @param integer $code The error code.
* @param string $file The file the error occurred in.
* @param integer $line The line the error occurred on.
*/
public function __construct($message, $code = 500, $file = null, $line = null) {
parent::__construct($message, $code);
Expand Down

0 comments on commit 86a0713

Please sign in to comment.