From 0d46464f83b49b0379ba146cf42cd6e8ccfa602e Mon Sep 17 00:00:00 2001 From: John Blackbourn Date: Thu, 28 Apr 2022 09:49:16 +0000 Subject: [PATCH] Docs: Various docblock corrections. See #54729 Built from https://develop.svn.wordpress.org/trunk@53300 git-svn-id: http://core.svn.wordpress.org/trunk@52889 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-cron.php | 2 +- wp-includes/general-template.php | 4 ++-- wp-includes/post.php | 12 ++++++------ wp-includes/revision.php | 2 +- wp-includes/version.php | 2 +- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/wp-cron.php b/wp-cron.php index 489550dedc..98bb1a4b28 100644 --- a/wp-cron.php +++ b/wp-cron.php @@ -54,7 +54,7 @@ if ( ! defined( 'ABSPATH' ) ) { * * @global wpdb $wpdb WordPress database abstraction object. * - * @return string|false Value of the `doing_cron` transient, 0|false otherwise. + * @return string|int|false Value of the `doing_cron` transient, 0|false otherwise. */ function _get_cron_lock() { global $wpdb; diff --git a/wp-includes/general-template.php b/wp-includes/general-template.php index f09c54ee96..d2ad7373f2 100644 --- a/wp-includes/general-template.php +++ b/wp-includes/general-template.php @@ -1315,7 +1315,7 @@ function _wp_render_title_tag() { * Default '»'. * @param bool $display Optional. Whether to display or retrieve title. Default true. * @param string $seplocation Optional. Location of the separator ('left' or 'right'). - * @return string|void String when `$display` is true, nothing otherwise. + * @return string|void String when `$display` is false, nothing otherwise. */ function wp_title( $sep = '»', $display = true, $seplocation = '' ) { global $wp_locale; @@ -1636,7 +1636,7 @@ function single_term_title( $prefix = '', $display = true ) { * * @param string $prefix Optional. What to display before the title. * @param bool $display Optional. Whether to display or retrieve title. Default true. - * @return string|void Title when retrieving. + * @return string|false|void False if there's no valid title for the month. Title when retrieving. */ function single_month_title( $prefix = '', $display = true ) { global $wp_locale; diff --git a/wp-includes/post.php b/wp-includes/post.php index fd4abd459a..288704c66d 100644 --- a/wp-includes/post.php +++ b/wp-includes/post.php @@ -3368,9 +3368,9 @@ function wp_delete_post( $postid = 0, $force_delete = false ) { * * @since 4.4.0 * - * @param bool|null $delete Whether to go forward with deletion. - * @param WP_Post $post Post object. - * @param bool $force_delete Whether to bypass the Trash. + * @param WP_Post|false|null $delete Whether to go forward with deletion. @TODO description + * @param WP_Post $post Post object. + * @param bool $force_delete Whether to bypass the Trash. */ $check = apply_filters( 'pre_delete_post', null, $post, $force_delete ); if ( null !== $check ) { @@ -6344,9 +6344,9 @@ function wp_delete_attachment( $post_id, $force_delete = false ) { * * @since 5.5.0 * - * @param bool|null $delete Whether to go forward with deletion. - * @param WP_Post $post Post object. - * @param bool $force_delete Whether to bypass the Trash. + * @param WP_Post|false|null $delete Whether to go forward with deletion. @TODO description + * @param WP_Post $post Post object. + * @param bool $force_delete Whether to bypass the Trash. */ $check = apply_filters( 'pre_delete_attachment', null, $post, $force_delete ); if ( null !== $check ) { diff --git a/wp-includes/revision.php b/wp-includes/revision.php index 06701eb89c..8f1d82ac02 100644 --- a/wp-includes/revision.php +++ b/wp-includes/revision.php @@ -447,7 +447,7 @@ function wp_restore_post_revision( $revision_id, $fields = null ) { * @since 2.6.0 * * @param int|WP_Post $revision_id Revision ID or revision object. - * @return array|false|WP_Post|WP_Error|null Null or WP_Error if error, deleted post if success. + * @return WP_Post|false|null Null or false if error, deleted post object if success. */ function wp_delete_post_revision( $revision_id ) { $revision = wp_get_post_revision( $revision_id ); diff --git a/wp-includes/version.php b/wp-includes/version.php index dd6524c2fe..5f186cd322 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.0-beta3-53299'; +$wp_version = '6.0-beta3-53300'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.