Make WordPress Core

Ticket #58076: 58076.5.patch

File 58076.5.patch, 4.5 KB (added by viralsampat, 13 months ago)

I have checked above mentioned issue and founds few files. Here, I have added its patch.

  • src/wp-includes/template.php

    diff --git src/wp-includes/template.php src/wp-includes/template.php
    index 69f8b76b51..6553ae5c82 100644
    function get_singular_template() { 
    652652 *
    653653 * @see get_query_template()
    654654 *
    655  * @global array $posts
    656655 *
    657656 * @return string Full path to attachment template file.
    658657 */
    function locate_template( $template_names, $load = false, $require_once = true, 
    731730 * @since 1.5.0
    732731 * @since 5.5.0 The `$args` parameter was added.
    733732 *
    734  * @global array      $posts
    735  * @global WP_Post    $post          Global post object.
    736  * @global bool       $wp_did_header
    737733 * @global WP_Query   $wp_query      WordPress Query object.
    738  * @global WP_Rewrite $wp_rewrite    WordPress rewrite component.
    739  * @global wpdb       $wpdb          WordPress database abstraction object.
    740  * @global string     $wp_version
    741  * @global WP         $wp            Current WordPress environment instance.
    742  * @global int        $id
    743  * @global WP_Comment $comment       Global comment object.
    744  * @global int        $user_ID
    745734 *
    746735 * @param string $_template_file Path to template file.
    747736 * @param bool   $require_once   Whether to require_once or require. Default true.
    function locate_template( $template_names, $load = false, $require_once = true, 
    749738 *                               Default empty array.
    750739 */
    751740function load_template( $_template_file, $require_once = true, $args = array() ) {
    752         global $posts, $post, $wp_did_header, $wp_query, $wp_rewrite, $wpdb, $wp_version, $wp, $id, $comment, $user_ID;
     741        global $wp_query;
    753742
    754743        if ( is_array( $wp_query->query_vars ) ) {
    755744                /*
  • src/wp-includes/theme.php

    diff --git src/wp-includes/theme.php src/wp-includes/theme.php
    index 6eab6fcc00..e5f3849e48 100644
    function add_editor_style( $stylesheet = 'editor-style.css' ) { 
    21242124 *
    21252125 * @since 3.1.0
    21262126 *
    2127  * @global array $editor_styles
    2128  *
    21292127 * @return bool True on success, false if there were no stylesheets to remove.
    21302128 */
    21312129function remove_editor_styles() {
    function remove_theme_support( $feature ) { 
    29802978 * @access private
    29812979 * @since 3.1.0
    29822980 * @global array               $_wp_theme_features
    2983  * @global Custom_Image_Header $custom_image_header
    2984  * @global Custom_Background   $custom_background
    29852981 *
    29862982 * @param string $feature The feature being removed. See add_theme_support() for the list
    29872983 *                        of possible values.
    function remove_theme_support( $feature ) { 
    29892985 */
    29902986function _remove_theme_support( $feature ) {
    29912987        global $_wp_theme_features;
    2992 
     2988       
    29932989        switch ( $feature ) {
    29942990                case 'custom-header-uploads':
    29952991                        if ( ! isset( $_wp_theme_features['custom-header'] ) ) {
    function _wp_customize_include() { 
    35183514 * @since 4.7.0
    35193515 * @access private
    35203516 *
    3521  * @global wpdb                 $wpdb         WordPress database abstraction object.
     3517 *
    35223518 * @global WP_Customize_Manager $wp_customize Customizer instance.
    35233519 *
    35243520 * @param string  $new_status     New post status.
    function _wp_customize_include() { 
    35263522 * @param WP_Post $changeset_post Changeset post object.
    35273523 */
    35283524function _wp_customize_publish_changeset( $new_status, $old_status, $changeset_post ) {
    3529         global $wp_customize, $wpdb;
     3525        global $wp_customize;
    35303526
    35313527        $is_publishing_changeset = (
    35323528                'customize_changeset' === $changeset_post->post_type
  • src/wp-includes/user.php

    diff --git src/wp-includes/user.php src/wp-includes/user.php
    index 9c17d1583e..e5834daae5 100644
    function wp_destroy_all_sessions() { 
    35073507 *
    35083508 * @param int|null $site_id Optional. The site ID to get users with no role for. Defaults to the current site.
    35093509 * @return string[] Array of user IDs as strings.
     3510 * @global wpdb         $wpdb       WordPress database abstraction object.
    35103511 */
    35113512function wp_get_users_with_no_role( $site_id = null ) {
    35123513        global $wpdb;
    All at ###SITENAME### 
    47904791 *
    47914792 * @param int $request_id Request ID.
    47924793 * @return string Confirmation key.
     4794 * @global $wp_hasher.
    47934795 */
    47944796function wp_generate_user_request_key( $request_id ) {
    47954797        global $wp_hasher;
    function wp_generate_user_request_key( $request_id ) { 
    48224824 * @param string $request_id ID of the request being confirmed.
    48234825 * @param string $key        Provided key to validate.
    48244826 * @return true|WP_Error True on success, WP_Error on failure.
     4827 * @global $wp_hasher.
    48254828 */
    48264829function wp_validate_user_request_key( $request_id, $key ) {
    48274830        global $wp_hasher;