Changeset 16818
- Timestamp:
- 12/08/2010 09:10:38 PM (14 years ago)
- Location:
- trunk/wp-includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/post.php
r16787 r16818 4025 4025 return; 4026 4026 4027 // we're only concerned with published objects 4028 if ( $post->post_status != 'publish' ) 4027 // we're only concerned with published, non-hierarchical objects 4028 $ptype_obj = get_post_type_object( $post->post_type ); 4029 if ( $post->post_status != 'publish' || !$ptype_obj || $ptype_obj->hierarchical ) 4029 4030 return; 4030 4031 -
trunk/wp-includes/query.php
r16792 r16818 3232 3232 $post_type = 'post'; 3233 3233 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 3234 3239 $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']); 3235 3240
Note: See TracChangeset
for help on using the changeset viewer.