Load: move `is_wp_error()` to `load.php` so that `WP_Error` is in a file by itself.
See #37827. Built from https://develop.svn.wordpress.org/trunk@38363 git-svn-id: http://core.svn.wordpress.org/trunk@38304 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
b144d69ba0
commit
4d17b67eed
|
@ -202,17 +202,3 @@ class WP_Error {
|
||||||
unset( $this->error_data[ $code ] );
|
unset( $this->error_data[ $code ] );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Check whether variable is a WordPress Error.
|
|
||||||
*
|
|
||||||
* Returns true if $thing is an object of the WP_Error class.
|
|
||||||
*
|
|
||||||
* @since 2.1.0
|
|
||||||
*
|
|
||||||
* @param mixed $thing Check if unknown variable is a WP_Error object.
|
|
||||||
* @return bool True, if WP_Error. False, if not WP_Error.
|
|
||||||
*/
|
|
||||||
function is_wp_error( $thing ) {
|
|
||||||
return ( $thing instanceof WP_Error );
|
|
||||||
}
|
|
||||||
|
|
|
@ -1045,3 +1045,17 @@ function wp_doing_ajax() {
|
||||||
*/
|
*/
|
||||||
return apply_filters( 'wp_doing_ajax', defined( 'DOING_AJAX' ) && DOING_AJAX );
|
return apply_filters( 'wp_doing_ajax', defined( 'DOING_AJAX' ) && DOING_AJAX );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Check whether variable is a WordPress Error.
|
||||||
|
*
|
||||||
|
* Returns true if $thing is an object of the WP_Error class.
|
||||||
|
*
|
||||||
|
* @since 2.1.0
|
||||||
|
*
|
||||||
|
* @param mixed $thing Check if unknown variable is a WP_Error object.
|
||||||
|
* @return bool True, if WP_Error. False, if not WP_Error.
|
||||||
|
*/
|
||||||
|
function is_wp_error( $thing ) {
|
||||||
|
return ( $thing instanceof WP_Error );
|
||||||
|
}
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '4.7-alpha-38362';
|
$wp_version = '4.7-alpha-38363';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
|
Loading…
Reference in New Issue