From 3bcec51070e9702cf6fb7237f3f7e5758f97f968 Mon Sep 17 00:00:00 2001 From: Jan Schneider Date: Tue, 9 Feb 2010 12:52:07 +0100 Subject: [PATCH] Set default exception message. --- .../Exception/lib/Horde/Exception/PermissionDenied.php | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/framework/Exception/lib/Horde/Exception/PermissionDenied.php b/framework/Exception/lib/Horde/Exception/PermissionDenied.php index 93b8fcef7..b27037e95 100644 --- a/framework/Exception/lib/Horde/Exception/PermissionDenied.php +++ b/framework/Exception/lib/Horde/Exception/PermissionDenied.php @@ -12,4 +12,21 @@ */ class Horde_Exception_PermissionDenied extends Horde_Exception { + /** + * Constructor. + * + * @see Horde_Exception::__construct() + * + * @param mixed $message The exception message, a PEAR_Error + * object, or an Exception object. + * @param mixed $code_or_lasterror Either a numeric error code, or + * an array from error_get_last(). + */ + public function __construct($message = null, $code_or_lasterror = null) + { + if (is_null($message)) { + $message = _("Permission Denied"); + } + parent::__construct($message, $code_or_lasterror); + } } \ No newline at end of file -- 2.11.0