From b5aeadf26526e01861f2ed7961f81f986252f719 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Sun, 14 Feb 2016 17:54:14 +0000 Subject: [PATCH] remove Exception from function signature of egw_exception_handler and _egw_log_exception, as php 7 throws Error not inherited from Exception, but Throwable does not exist in php < 7.0 --- phpgwapi/inc/common_functions.inc.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/phpgwapi/inc/common_functions.inc.php b/phpgwapi/inc/common_functions.inc.php index 74cd02c595..55d6e19e8e 100755 --- a/phpgwapi/inc/common_functions.inc.php +++ b/phpgwapi/inc/common_functions.inc.php @@ -1777,10 +1777,10 @@ function json_php_unserialize($str, $allow_not_serialized=false) /** * Clasify exception for a headline and log it to error_log, if not running as cli * - * @param Exception $e + * @param Exception|Error $e * @param string &$headline */ -function _egw_log_exception(Exception $e,&$headline=null) +function _egw_log_exception($e,&$headline=null) { $trace = explode("\n", $e->getTraceAsString()); if ($e instanceof egw_exception_no_permission) @@ -1824,9 +1824,9 @@ function _egw_log_exception(Exception $e,&$headline=null) * * Does NOT return * - * @param Exception $e + * @param Exception|Error $e */ -function egw_exception_handler(Exception $e) +function egw_exception_handler($e) { // handle redirects without logging if (is_a($e, 'egw_exception_redirect'))