mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 14:27:22 +01:00
Merge branch 'w30_MDL-40795_m26_ajaxerrordisplay' of https://github.com/skodak/moodle
This commit is contained in:
commit
59af378baf
@ -183,7 +183,13 @@ ini_set('precision', 14); // needed for upgrades and gradebook
|
||||
// please note it must be defined before including the config.php script
|
||||
// and in some cases you also need to set custom default exception handler
|
||||
if (!defined('NO_DEBUG_DISPLAY')) {
|
||||
if (defined('AJAX_SCRIPT') and AJAX_SCRIPT) {
|
||||
// Moodle AJAX scripts are expected to return json data, any PHP notices or errors break it badly,
|
||||
// developers simply must learn to watch error log.
|
||||
define('NO_DEBUG_DISPLAY', true);
|
||||
} else {
|
||||
define('NO_DEBUG_DISPLAY', false);
|
||||
}
|
||||
}
|
||||
|
||||
// Some scripts such as upgrade may want to prevent output buffering
|
||||
|
Loading…
x
Reference in New Issue
Block a user