Skip to content

Commit

Permalink
Tentative attempt to filter out the post_types not relating to this l…
Browse files Browse the repository at this point in the history
…anguage from taxonomy archives
  • Loading branch information
simonwheatley committed Sep 19, 2012
1 parent 604c00e commit 0238f69
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion class-taxonomy.php
Expand Up @@ -494,6 +494,10 @@ public function parse_request( $wp ) {
foreach ( $taxonomies as $taxonomy ) {
$taxonomy = get_taxonomy( $taxonomy );
$post_types = array_merge( $post_types, $taxonomy->object_type );
// Filter out the post_types not in this language
foreach ( $post_types as & $post_type )
$post_type = bbl_get_post_type_in_lang( $post_type );
$post_types = array_unique( $post_types );
}
$wp->query_vars[ 'post_type' ] = $post_types;
}
Expand All @@ -511,7 +515,6 @@ public function parse_request( $wp ) {
);

}

}

/**
Expand Down

0 comments on commit 0238f69

Please sign in to comment.