diff --git a/wp-admin/includes/comment.php b/wp-admin/includes/comment.php index 89022949b1..90d79dd211 100644 --- a/wp-admin/includes/comment.php +++ b/wp-admin/includes/comment.php @@ -141,8 +141,8 @@ function get_comment_to_edit( $id ) { * * @global wpdb $wpdb WordPress database abstraction object. * - * @param int|array $post_id Either a single Post ID or an array of Post IDs - * @return int|array Either a single Posts pending comments as an int or an array of ints keyed on the Post IDs + * @param int|int[] $post_id Either a single Post ID or an array of Post IDs + * @return int|int[] Either a single Posts pending comments as an int or an array of ints keyed on the Post IDs */ function get_pending_comments_num( $post_id ) { global $wpdb; diff --git a/wp-admin/includes/post.php b/wp-admin/includes/post.php index 8ec615f1c7..96b71d0703 100644 --- a/wp-admin/includes/post.php +++ b/wp-admin/includes/post.php @@ -1346,9 +1346,9 @@ function postbox_classes( $box_id, $screen_id ) { * * @since 2.5.0 * - * @param int $id Post ID or post object. - * @param string $title Optional. Title to override the post's current title when generating the post name. Default null. - * @param string $name Optional. Name to override the post name. Default null. + * @param int|WP_Post $id Post ID or post object. + * @param string $title Optional. Title to override the post's current title when generating the post name. Default null. + * @param string $name Optional. Name to override the post name. Default null. * @return array { * Array containing the sample permalink with placeholder for the post name, and the post name. * @@ -1596,7 +1596,7 @@ function _wp_post_thumbnail_html( $thumbnail_id = null, $post = null ) { * * @since 2.5.0 * - * @param int $post_id ID of the post to check for editing. + * @param int|WP_Post $post_id ID or object of the post to check for editing. * @return int|false ID of the user with lock. False if the post does not exist, post is not locked, * the user with lock does not exist, or the post is locked by current user. */ @@ -1634,7 +1634,7 @@ function wp_check_post_lock( $post_id ) { * * @since 2.5.0 * - * @param int $post_id ID of the post being edited. + * @param int|WP_Post $post_id ID or object of the post being edited. * @return array|false Array of the lock time and user ID. False if the post does not exist, or * there is no current user. */ diff --git a/wp-includes/class-wp-post.php b/wp-includes/class-wp-post.php index e1c3c3bb6f..4f85f1280c 100644 --- a/wp-includes/class-wp-post.php +++ b/wp-includes/class-wp-post.php @@ -352,7 +352,7 @@ final class WP_Post { * @since 3.5.0 * * @param string $filter Filter. - * @return array|bool|object|WP_Post + * @return WP_Post */ public function filter( $filter ) { if ( $this->filter === $filter ) { diff --git a/wp-includes/post-formats.php b/wp-includes/post-formats.php index 7072266834..c1214da315 100644 --- a/wp-includes/post-formats.php +++ b/wp-includes/post-formats.php @@ -11,7 +11,7 @@ * * @since 3.1.0 * - * @param int|object|null $post Optional. Post ID or post object. Defaults to the current post in the loop. + * @param int|WP_Post|null $post Optional. Post ID or post object. Defaults to the current post in the loop. * @return string|false The format if successful. False otherwise. */ function get_post_format( $post = null ) { diff --git a/wp-includes/post.php b/wp-includes/post.php index c1a829de91..874d219684 100644 --- a/wp-includes/post.php +++ b/wp-includes/post.php @@ -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 ) ) { diff --git a/wp-includes/version.php b/wp-includes/version.php index a651726673..62c95474e8 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -13,7 +13,7 @@ * * @global string $wp_version */ -$wp_version = '5.6-beta3-49543'; +$wp_version = '5.6-beta3-49544'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.