From 2b0df3e4e2c9b064088a02eac6d5ce190e9d0561 Mon Sep 17 00:00:00 2001 From: ratmole Date: Wed, 31 Oct 2018 10:17:36 +0200 Subject: [PATCH] API - Disable E_NOTICE from php error reporting in cake debug Using zmNinja, the API reports E_NOTICE errors Notice (8): compact(): Undefined variable: subject [CORE/Cake/Utility/ObjectCollection.php, line 128] Notice (8): compact() [function.compact]: Undefined variable: subject [CORE/Cake/Utility/ObjectCollection.php, line 128] Notice (8): compact() [function.compact]: Undefined variable: subject [CORE/Cake/Utility/ObjectCollection.php, line 128] Notice (8): compact() [function.compact]: Undefined variable: subject [CORE/Cake/Utility/ObjectCollection.php, line 128] and zmNinja will not work... there is a better way, but i think disabling E_NOTICE error is way easier see: https://github.com/ZoneMinder/zoneminder/pull/2269 --- web/api/app/Config/core.php.default | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/api/app/Config/core.php.default b/web/api/app/Config/core.php.default index 39a51690c..64f439420 100644 --- a/web/api/app/Config/core.php.default +++ b/web/api/app/Config/core.php.default @@ -50,7 +50,7 @@ */ Configure::write('Error', array( 'handler' => 'ErrorHandler::handleError', - 'level' => E_ALL & ~E_DEPRECATED, + 'level' => E_ALL & ~E_DEPRECATED & ~E_NOTICE, 'trace' => true ));