Ticket #25143: 25143.2.patch
File 25143.2.patch, 1.1 KB (added by , 10 years ago) |
---|
-
src/wp-includes/query.php
853 853 * @var array 854 854 */ 855 855 public $query_vars = array(); 856 857 /** 858 * Default query vars 859 * 860 * @access private 861 * @var array 862 */ 863 private $default_query_vars = array(); 856 864 857 865 /** 858 866 * Taxonomy query, as passed to get_tax_sql() … … 1558 1566 } 1559 1567 1560 1568 $this->query_vars = $this->fill_query_vars($this->query_vars); 1569 $this->default_query_vars = $this->fill_query_vars( array() ); 1570 1561 1571 $qv = &$this->query_vars; 1562 1572 $this->query_vars_changed = true; 1563 1573 … … 1766 1776 $qv['page'] = $qv['paged']; 1767 1777 unset($qv['paged']); 1768 1778 } 1779 } elseif( ! empty( $_query ) ) { 1780 1781 $front = false; 1782 foreach( $_query as $key ) { 1783 if( in_array( $key, $this->default_query_vars ) ) { 1784 continue; 1785 } 1786 $front = true; 1787 } 1788 1789 if( $front ) { 1790 $this->is_page = true; 1791 $this->is_home = false; 1792 $qv['page_id'] = get_option('page_on_front'); 1793 } 1769 1794 } 1795 1770 1796 } 1771 1797 1772 1798 if ( '' != $qv['pagename'] ) {