Docs: Docblock corrections relating to WP_Post objects.
See #51373, #50768 Built from https://develop.svn.wordpress.org/trunk@49544 git-svn-id: http://core.svn.wordpress.org/trunk@49282 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -2323,7 +2323,7 @@ function is_sticky( $post_id = 0 ) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Sanitize every post field.
|
||||
* Sanitizes every post field.
|
||||
*
|
||||
* If the context is 'raw', then the post object or array will get minimal
|
||||
* sanitization of the integer fields.
|
||||
@@ -2332,12 +2332,12 @@ function is_sticky( $post_id = 0 ) {
|
||||
*
|
||||
* @see sanitize_post_field()
|
||||
*
|
||||
* @param object|WP_Post|array $post The Post Object or Array
|
||||
* @param object|WP_Post|array $post The post object or array
|
||||
* @param string $context Optional. How to sanitize post fields.
|
||||
* Accepts 'raw', 'edit', 'db', or 'display'.
|
||||
* Default 'display'.
|
||||
* @return object|WP_Post|array The now sanitized Post Object or Array (will be the
|
||||
* same type as $post).
|
||||
* @return object|WP_Post|array The now sanitized post object or array (will be the
|
||||
* same type as `$post`).
|
||||
*/
|
||||
function sanitize_post( $post, $context = 'display' ) {
|
||||
if ( is_object( $post ) ) {
|
||||
|
||||
Reference in New Issue
Block a user