diff --git a/class2.php b/class2.php index 577ee66a7..9b5f985d1 100755 --- a/class2.php +++ b/class2.php @@ -143,6 +143,7 @@ if(!defined('e_ROOT')) // D: Setup PHP error handling // (Now we can see PHP errors) -- but note that DEBUG is not yet enabled! // +global $error_handler; $error_handler = new error_handler(); // @@ -2412,8 +2413,8 @@ function force_userupdate($currentUser) class error_handler { - var $errors; - var $debug = false; + public $errors = []; + public $debug = false; protected $xdebug = false; protected $docroot = ''; protected $label = array(); diff --git a/e107_handlers/core_functions.php b/e107_handlers/core_functions.php index 71321d1fa..e27d6aef7 100644 --- a/e107_handlers/core_functions.php +++ b/e107_handlers/core_functions.php @@ -457,7 +457,7 @@ class e_array { // e107::getDebug()->log("Json data found"); - if(json_last_error() != JSON_ERROR_NONE && (e_DEBUG === true)) + if(json_last_error() != JSON_ERROR_NONE && e_DEBUG === true && !e107::isCli()) { echo "
";