Fixes undefined error on breadcrumb.
This commit is contained in:
parent
f9594a2836
commit
8ff6b58934
File diff suppressed because one or more lines are too long
|
@ -87,11 +87,13 @@ function tainacan_interface_the_breadcrumb() {
|
|||
echo '<a href="'. esc_url(get_post_type_archive_link('tainacan-collection')) .'">';
|
||||
_e( 'Collections', 'tainacan-interface' );
|
||||
echo '</a> ' . $delimiter . ' ';
|
||||
|
||||
if (is_post_type_archive()) {
|
||||
$str = $post_type->labels->singular_name;
|
||||
} else {
|
||||
$str = __('All items', 'tainacan-interface');
|
||||
$str = '';
|
||||
if ( ($post_type) ) {
|
||||
if (is_post_type_archive()) {
|
||||
$str = $post_type->labels->singular_name;
|
||||
} else {
|
||||
$str = __('All items', 'tainacan-interface');
|
||||
}
|
||||
}
|
||||
echo $before . $str . $after;
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue