WordPress.org

Make WordPress Core


Ignore:
Timestamp:
12/08/2010 09:10:38 PM (9 years ago)
Author:
markjaquith
Message:

Do not do slug logging/redirects for hierarchical post types. see #15140

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/query.php

    r16792 r16818  
    32323232            $post_type = 'post';
    32333233
     3234        // Do not attempt redirect for hierarchical post types
     3235        $ptype_obj = get_post_type_object( $post_type );
     3236        if ( !$ptype_obj || $ptype_obj->hierarchical )
     3237            return;
     3238
    32343239        $query = $wpdb->prepare("SELECT post_id FROM $wpdb->postmeta, $wpdb->posts WHERE ID = post_id AND post_type = %s AND meta_key = '_wp_old_slug' AND meta_value = %s", $post_type, $wp_query->query_vars['name']);
    32353240
Note: See TracChangeset for help on using the changeset viewer.