Skip to content
Snippets Groups Projects
Commit 03957153 authored by Robin Appelman's avatar Robin Appelman
Browse files

set DEBUG from xdebug session before we first use it

parent bcabdd7d
Branches
No related tags found
No related merge requests found
......@@ -424,12 +424,6 @@ class OC {
self::initPaths();
if (!defined('PHPUNIT_RUN') and !(defined('DEBUG') and DEBUG)) {
register_shutdown_function(array('OC_Log', 'onShutdown'));
set_error_handler(array('OC_Log', 'onError'));
set_exception_handler(array('OC_Log', 'onException'));
}
// set debug mode if an xdebug session is active
if (!defined('DEBUG') || !DEBUG) {
if (isset($_COOKIE['XDEBUG_SESSION'])) {
......@@ -437,6 +431,12 @@ class OC {
}
}
if (!defined('PHPUNIT_RUN') and !(defined('DEBUG') and DEBUG)) {
register_shutdown_function(array('OC_Log', 'onShutdown'));
set_error_handler(array('OC_Log', 'onError'));
set_exception_handler(array('OC_Log', 'onException'));
}
// register the stream wrappers
stream_wrapper_register('fakedir', 'OC\Files\Stream\Dir');
stream_wrapper_register('static', 'OC\Files\Stream\StaticStream');
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment