WordPress.org

Make WordPress Core

Ticket #5717: 404fix.diff

File 404fix.diff, 469 bytes (added by misterbisson, 10 years ago)
  • wp-includes/classes.php

     
    270270        function query_posts() {
    271271                global $wp_the_query;
    272272                $this->build_query_string();
     273                if( $this->did_permalink && $this->query_vars['error'] == '404' ){
     274                        $wp_the_query->parse_query($query);
     275                        return;
     276                }
    273277                $wp_the_query->query($this->query_vars);
    274278        }
    275279