Make WordPress Core

Changeset 12685


Ignore:
Timestamp:
01/10/2010 10:57:01 AM (15 years ago)
Author:
westi
Message:

Tidy up logic for defining WP_DEBUG so we only define it if it isn't already. Fixes #11837 props nacin.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-settings.php

    r12671 r12685  
    203203
    204204// Add define('WP_DEBUG', true); to wp-config.php to enable display of notices during development.
    205 if ( defined('WP_DEBUG') && WP_DEBUG ) {
     205if ( !defined('WP_DEBUG') )
     206    define( 'WP_DEBUG', false );
     207
     208if ( WP_DEBUG ) {
    206209    if ( defined('E_DEPRECATED') )
    207210        error_reporting(E_ALL & ~E_DEPRECATED & ~E_STRICT);
     
    217220    }
    218221} else {
    219     define('WP_DEBUG', false);
    220222    if ( defined('E_RECOVERABLE_ERROR') )
    221223        error_reporting(E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR);
Note: See TracChangeset for help on using the changeset viewer.