Make WordPress Core

Ticket #23811: 23811.3.diff

File 23811.3.diff, 1006 bytes (added by nacin, 12 years ago)
  • wp-includes/load.php

     
    253253 * When WP_DEBUG_LOG is true, errors will be logged to wp-content/debug.log.
    254254 * WP_DEBUG_LOG defaults to false.
    255255 *
     256 * Errors are never displayed for XML-RPC requests.
     257 *
    256258 * @access private
    257259 * @since 3.0.0
    258260 */
     
    260262        if ( WP_DEBUG ) {
    261263                error_reporting( E_ALL );
    262264
    263                 if ( WP_DEBUG_DISPLAY )
     265                if ( defined( 'XMLRPC_REQUEST' ) )
     266                        ini_set( 'display_errors', 0 );
     267                elseif ( WP_DEBUG_DISPLAY )
    264268                        ini_set( 'display_errors', 1 );
    265269                elseif ( null !== WP_DEBUG_DISPLAY )
    266270                        ini_set( 'display_errors', 0 );
     
    271275                }
    272276        } else {
    273277                error_reporting( E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR );
     278                if ( defined( 'XMLRPC_REQUEST' ) )
     279                        ini_set( 'display_errors', 0 );
    274280        }
    275281}
    276282