Ticket #51439: 51439.patch
File 51439.patch, 5.3 KB (added by , 4 years ago) |
---|
-
src/wp-admin/credits.php
4 4 * 5 5 * @package WordPress 6 6 * @subpackage Administration 7 * @var string $title 7 8 */ 8 9 9 10 /** WordPress Administration Bootstrap */ -
src/wp-admin/edit-comments.php
4 4 * 5 5 * @package WordPress 6 6 * @subpackage Administration 7 * 8 * @global wpdb $wpdb WordPress database abstraction object. 9 * @global int $post_id 7 10 */ 8 11 9 12 /** WordPress Administration Bootstrap */ 10 13 require_once __DIR__ . '/admin.php'; 14 global $wpdb , $post_id; 15 11 16 if ( ! current_user_can( 'edit_posts' ) ) { 12 17 wp_die( 13 18 '<h1>' . __( 'You need a higher level of permission.' ) . '</h1>' . … … 135 140 wp_enqueue_script( 'admin-comments' ); 136 141 enqueue_comment_hotkeys_js(); 137 142 143 $post_id = isset( $_REQUEST['p'] ) ? absint( $_REQUEST['p'] ) : 0; 144 138 145 if ( $post_id ) { 139 146 $comments_count = wp_count_comments( $post_id ); 140 147 $draft_or_post_title = wp_html_excerpt( _draft_or_post_title( $post_id ), 50, '…' ); -
src/wp-admin/edit.php
4 4 * 5 5 * @package WordPress 6 6 * @subpackage Administration 7 * @global string $typenow 7 8 */ 8 9 9 10 /** WordPress Administration Bootstrap */ 10 11 require_once __DIR__ . '/admin.php'; 11 12 13 global $typenow; 14 12 15 if ( ! $typenow ) { 13 16 wp_die( __( 'Invalid post type.' ) ); 14 17 } … … 26 29 /** 27 30 * @global string $post_type 28 31 * @global WP_Post_Type $post_type_object 32 * @global wpdb $wpdb WordPress database abstraction object. 29 33 */ 30 global $ post_type, $post_type_object;34 global $wpdb, $post_type, $post_type_object; 31 35 32 36 $post_type = $typenow; 33 37 $post_type_object = get_post_type_object( $post_type ); -
src/wp-admin/includes/ajax-actions.php
426 426 * 427 427 * @param int $comment_id 428 428 * @param int $delta 429 * @var array $query_vars See {@link WP::parse_request()}. 429 430 */ 430 431 function _wp_ajax_delete_comment_response( $comment_id, $delta = -1 ) { 431 432 $total = isset( $_POST['_total'] ) ? (int) $_POST['_total'] : 0; … … 3614 3615 * @global WP_Embed $wp_embed Embed API instance. 3615 3616 * @global WP_Scripts $wp_scripts 3616 3617 * @global int $content_width 3618 * @var array $matches 3617 3619 */ 3618 3620 function wp_ajax_parse_embed() { 3619 3621 global $post, $wp_embed, $content_width; -
src/wp-admin/includes/class-core-upgrader.php
45 45 * 46 46 * @global WP_Filesystem_Base $wp_filesystem WordPress filesystem subclass. 47 47 * @global callable $_wp_filesystem_direct_method 48 * @global string $wp_version The WordPress version string. 48 49 * 49 50 * @param object $current Response object for whether WordPress is current. 50 51 * @param array $args { … … 60 61 * @return string|false|WP_Error New WordPress version on success, false or WP_Error on failure. 61 62 */ 62 63 public function upgrade( $current, $args = array() ) { 63 global $wp_filesystem;64 global $wp_filesystem, $wp_version; 64 65 65 66 require ABSPATH . WPINC . '/version.php'; // $wp_version; 66 67 … … 267 268 * 268 269 * @since 3.7.0 269 270 * 270 * @param string $offered_ver The offered version, of the format x.y.z. 271 * @return bool True if we should update to the offered version, otherwise false. 271 * @global string $wp_version The WordPress version string. 272 * @param string $offered_ver The offered version, of the format x.y.z. 273 * @return bool True if we should update to the offered version, otherwise false. 272 274 */ 273 275 public static function should_update_to_version( $offered_ver ) { 276 global $wp_version; 277 274 278 require ABSPATH . WPINC . '/version.php'; // $wp_version; // x.y.z 275 279 276 280 $current_branch = implode( '.', array_slice( preg_split( '/[.-]/', $wp_version ), 0, 2 ) ); // x.y -
src/wp-admin/install.php
222 222 } 223 223 224 224 /** 225 * @global wpdb $wpdb WordPress database abstraction object. 225 226 * @global string $wp_version The WordPress version string. 226 227 * @global string $required_php_version The required PHP version string. 227 228 * @global string $required_mysql_version The required MySQL version string. 228 229 */ 229 global $wp_version, $ required_php_version, $required_mysql_version;230 global $wp_version, $wpdb, $required_php_version, $required_mysql_version; 230 231 231 232 $php_version = phpversion(); 232 233 $mysql_version = $wpdb->db_version();