diff --git a/wp-admin/edit-comments.php b/wp-admin/edit-comments.php index ba8924f1e0..28be5c9df9 100644 --- a/wp-admin/edit-comments.php +++ b/wp-admin/edit-comments.php @@ -25,6 +25,11 @@ if ( $doaction ) { check_admin_referer( 'bulk-comments' ); if ( 'delete_all' === $doaction && ! empty( $_REQUEST['pagegen_timestamp'] ) ) { + /** + * @global wpdb $wpdb WordPress database abstraction object. + */ + global $wpdb; + $comment_status = wp_unslash( $_REQUEST['comment_status'] ); $delete_time = wp_unslash( $_REQUEST['pagegen_timestamp'] ); $comment_ids = $wpdb->get_col( $wpdb->prepare( "SELECT comment_ID FROM $wpdb->comments WHERE comment_approved = %s AND %s > comment_date_gmt", $comment_status, $delete_time ) ); @@ -135,6 +140,11 @@ $wp_list_table->prepare_items(); wp_enqueue_script( 'admin-comments' ); enqueue_comment_hotkeys_js(); +/** + * @global int $post_id + */ +global $post_id; + if ( $post_id ) { $comments_count = wp_count_comments( $post_id ); $draft_or_post_title = wp_html_excerpt( _draft_or_post_title( $post_id ), 50, '…' ); diff --git a/wp-admin/edit-form-comment.php b/wp-admin/edit-form-comment.php index 654046c3d9..39bd35e769 100644 --- a/wp-admin/edit-form-comment.php +++ b/wp-admin/edit-form-comment.php @@ -10,6 +10,11 @@ if ( ! defined( 'ABSPATH' ) ) { die( '-1' ); } + +/** + * @global WP_Comment $comment Global comment object. + */ +global $comment; ?>
comment_ID ); ?> @@ -139,7 +144,14 @@ printf( __( 'Submitted on: %s' ), '' . $submitted . '' );
- +
diff --git a/wp-admin/edit.php b/wp-admin/edit.php index bd537bd49e..f56beabae8 100644 --- a/wp-admin/edit.php +++ b/wp-admin/edit.php @@ -9,6 +9,11 @@ /** WordPress Administration Bootstrap */ require_once __DIR__ . '/admin.php'; +/** + * @global string $typenow The post type of the current screen. + */ +global $typenow; + if ( ! $typenow ) { wp_die( __( 'Invalid post type.' ) ); } @@ -87,6 +92,11 @@ if ( $doaction ) { $post_status = preg_replace( '/[^a-z0-9_-]+/i', '', $_REQUEST['post_status'] ); // Validate the post status exists. if ( get_post_status_object( $post_status ) ) { + /** + * @global wpdb $wpdb WordPress database abstraction object. + */ + global $wpdb; + $post_ids = $wpdb->get_col( $wpdb->prepare( "SELECT ID FROM $wpdb->posts WHERE post_type=%s AND post_status = %s", $post_type, $post_status ) ); } $doaction = 'delete'; diff --git a/wp-admin/install.php b/wp-admin/install.php index b7217a05d3..1b9e907907 100644 --- a/wp-admin/install.php +++ b/wp-admin/install.php @@ -225,8 +225,9 @@ if ( is_blog_installed() ) { * @global string $wp_version The WordPress version string. * @global string $required_php_version The required PHP version string. * @global string $required_mysql_version The required MySQL version string. + * @global wpdb $wpdb WordPress database abstraction object. */ -global $wp_version, $required_php_version, $required_mysql_version; +global $wp_version, $required_php_version, $required_mysql_version, $wpdb; $php_version = PHP_VERSION; $mysql_version = $wpdb->db_version(); diff --git a/wp-admin/upgrade.php b/wp-admin/upgrade.php index 66ee42729d..e816c69d0b 100644 --- a/wp-admin/upgrade.php +++ b/wp-admin/upgrade.php @@ -39,8 +39,9 @@ if ( 'upgrade_db' === $step ) { * @global string $wp_version The WordPress version string. * @global string $required_php_version The required PHP version string. * @global string $required_mysql_version The required MySQL version string. + * @global wpdb $wpdb WordPress database abstraction object. */ -global $wp_version, $required_php_version, $required_mysql_version; +global $wp_version, $required_php_version, $required_mysql_version, $wpdb; $step = (int) $step; diff --git a/wp-includes/version.php b/wp-includes/version.php index 64cf35cd96..843a2ee09e 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.1-alpha-53449'; +$wp_version = '6.1-alpha-53450'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.