Filter hook 'enable_wp_debug_mode_checks'

in WP Core File wp-includes/load.php at line 582

Description

Filters whether to allow the debug mode check to occur. This filter runs before it can be used by plugins. It is designed for non-web runtimes. Returning false causes the `WP_DEBUG` and related constants to not be checked and the default PHP values for errors will be used unless you take care to update them yourself. To use this filter you must define a `$wp_filter` global before WordPress loads, usually in `wp-config.php`. Example: $GLOBALS['wp_filter'] = array( 'enable_wp_debug_mode_checks' => array( 10 => array( array( 'accepted_args' => 0, 'function' => function() { return false; }, ), ), ), );

Occurrences

Filename Line Number
wp-includes/load.php 582

Parameters

Type Name Description
bool $enable_debug_mode Whether to enable debug mode checks to occur. Default true.

PHP Doc

/**
	 * Filters whether to allow the debug mode check to occur.
	 *
	 * This filter runs before it can be used by plugins. It is designed for
	 * non-web runtimes. Returning false causes the `WP_DEBUG` and related
	 * constants to not be checked and the default PHP values for errors
	 * will be used unless you take care to update them yourself.
	 *
	 * To use this filter you must define a `$wp_filter` global before
	 * WordPress loads, usually in `wp-config.php`.
	 *
	 * Example:
	 *
	 *     $GLOBALS['wp_filter'] = array(
	 *         'enable_wp_debug_mode_checks' => array(
	 *             10 => array(
	 *                 array(
	 *                     'accepted_args' => 0,
	 *                     'function'      => function() {
	 *                         return false;
	 *                     },
	 *                 ),
	 *             ),
	 *         ),
	 *     );
	 *
	 * @since 4.6.0
	 *
	 * @param bool $enable_debug_mode Whether to enable debug mode checks to occur. Default true.
	 */