Commit d9d61fa3 authored by Petr Skoda's avatar Petr Skoda
Browse files

MDL-32251 use standard PHP debug levels instead of original 38911

parent 54352ac9
......@@ -420,10 +420,10 @@ $CFG->admin = 'admin';
//=========================================================================
//
// Force a debugging mode regardless the settings in the site administration
// @error_reporting(1023); // NOT FOR PRODUCTION SERVERS!
// @ini_set('display_errors', '1'); // NOT FOR PRODUCTION SERVERS!
// $CFG->debug = 38911; // DEBUG_DEVELOPER // NOT FOR PRODUCTION SERVERS!
// $CFG->debugdisplay = true; // NOT FOR PRODUCTION SERVERS!
// @error_reporting(E_ALL | E_STRICT); // NOT FOR PRODUCTION SERVERS!
// @ini_set('display_errors', '1'); // NOT FOR PRODUCTION SERVERS!
// $CFG->debug = (E_ALL | E_STRICT); // === DEBUG_DEVELOPER - NOT FOR PRODUCTION SERVERS!
// $CFG->debugdisplay = 1; // NOT FOR PRODUCTION SERVERS!
//
// You can specify a comma separated list of user ids that that always see
// debug messages, this overrides the debug flag in $CFG->debug and $CFG->debugdisplay
......
......@@ -402,9 +402,9 @@ function install_cli_database(array $options, $interactive) {
require_once($CFG->libdir.'/upgradelib.php');
// show as much debug as possible
@error_reporting(1023);
@error_reporting(E_ALL | E_STRICT);
@ini_set('display_errors', '1');
$CFG->debug = 38911;
$CFG->debug = (E_ALL | E_STRICT);
$CFG->debugdisplay = true;
$CFG->version = '';
......
......@@ -369,7 +369,7 @@ class moodlelib_test extends UnitTestCase {
// make sure warning is displayed if array submitted - TODO: throw exception in Moodle 2.3
$debugging = isset($CFG->debug) ? $CFG->debug : null;
$debugdisplay = isset($CFG->debugdisplay) ? $CFG->debugdisplay : null;
$CFG->debug = 38911;
$CFG->debug = DEBUG_DEVELOPER;
$CFG->debugdisplay = true;
ob_start();
......@@ -441,7 +441,7 @@ class moodlelib_test extends UnitTestCase {
// do not allow non-arrays
$debugging = isset($CFG->debug) ? $CFG->debug : null;
$debugdisplay = isset($CFG->debugdisplay) ? $CFG->debugdisplay : null;
$CFG->debug = 38911;
$CFG->debug = DEBUG_DEVELOPER;
$CFG->debugdisplay = true;
ob_start();
......@@ -511,7 +511,7 @@ class moodlelib_test extends UnitTestCase {
// make sure warning is displayed if array submitted - TODO: throw exception in Moodle 2.3
$debugging = isset($CFG->debug) ? $CFG->debug : null;
$debugdisplay = isset($CFG->debugdisplay) ? $CFG->debugdisplay : null;
$CFG->debug = 38911;
$CFG->debug = DEBUG_DEVELOPER;
$CFG->debugdisplay = true;
ob_start();
......@@ -583,7 +583,7 @@ class moodlelib_test extends UnitTestCase {
// do not allow non-arrays
$debugging = isset($CFG->debug) ? $CFG->debug : null;
$debugdisplay = isset($CFG->debugdisplay) ? $CFG->debugdisplay : null;
$CFG->debug = 38911;
$CFG->debug = DEBUG_DEVELOPER;
$CFG->debugdisplay = true;
// make sure array keys are sanitised
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment