WordPress.org

Make WordPress Core

Ticket #20039: 20039.patch

File 20039.patch, 965 bytes (added by SergeyBiryukov, 6 years ago)
  • wp-includes/query.php

     
    16241624                }
    16251625
    16261626                if ( '' != $qv['pagename'] ) {
    1627                         $this->queried_object =& get_page_by_path($qv['pagename']);
     1627                        $this->queried_object = get_page_by_path($qv['pagename']);
    16281628                        if ( !empty($this->queried_object) )
    16291629                                $this->queried_object_id = (int) $this->queried_object->ID;
    16301630                        else
     
    29772977                        $this->queried_object = get_post_type_object( $this->get('post_type') );
    29782978                } elseif ( $this->is_posts_page ) {
    29792979                        $page_for_posts = get_option('page_for_posts');
    2980                         $this->queried_object = & get_page( $page_for_posts );
     2980                        $this->queried_object = get_page( $page_for_posts );
    29812981                        $this->queried_object_id = (int) $this->queried_object->ID;
    29822982                } elseif ( $this->is_singular && !is_null($this->post) ) {
    29832983                        $this->queried_object = $this->post;