Bootstrap/Load: Fix bug causing AJAX functions to return a 500 when passing a null
response to wp_die()
.
This bug was introduced in [44497]. Props ocean90. See #45933. git-svn-id: https://develop.svn.wordpress.org/trunk@44673 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
44ce02e28a
commit
43bbbbf8b8
@ -3293,7 +3293,8 @@ function _ajax_wp_die_handler( $message, $title = '', $args = array() ) {
|
||||
|
||||
list( $message, $title, $r ) = _wp_die_process_input( $message, $title, $args );
|
||||
|
||||
if ( ! headers_sent() && null !== $r['response'] ) {
|
||||
// This is intentional. For backward-compatibility, support passing null here.
|
||||
if ( ! headers_sent() && null !== $args['response'] ) {
|
||||
status_header( $r['response'] );
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user