WordPress.org

Make WordPress Core

Changeset 48372


Ignore:
Timestamp:
07/07/2020 12:55:26 PM (5 months ago)
Author:
SergeyBiryukov
Message:

Bootstrap/Load: Set WP_DEBUG to true by default on development environments.

Props johnbillion, kraftbj, Clorith, joostdevalk, dlh.
Fixes #33161.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/default-constants.php

    r48067 r48372  
    7575    // Add define( 'WP_DEBUG', true ); to wp-config.php to enable display of notices during development.
    7676    if ( ! defined( 'WP_DEBUG' ) ) {
    77         define( 'WP_DEBUG', false );
     77        if ( 'development' === wp_get_environment_type() ) {
     78            define( 'WP_DEBUG', true );
     79        } else {
     80            define( 'WP_DEBUG', false );
     81        }
    7882    }
    7983
Note: See TracChangeset for help on using the changeset viewer.