diff --git a/src/wp-includes/post.php b/src/wp-includes/post.php
index 91edacf76f..9be02cd010 100644
a
|
b
|
function is_post_type_viewable( $post_type ) { |
2113 | 2113 | * @param bool $is_viewable Whether the post type is "viewable". |
2114 | 2114 | * @param WP_Post_Type $post_type Post type object. |
2115 | 2115 | */ |
2116 | | $is_viewable = apply_filters( 'is_post_type_viewable', $is_viewable, $post_type ); |
2117 | | |
2118 | | // Make sure the filtered value is a boolean type before returning it. |
2119 | | if ( ! is_bool( $is_viewable ) ) { |
2120 | | return false; |
2121 | | } |
2122 | | |
2123 | | return $is_viewable; |
| 2116 | return true === apply_filters( 'is_post_type_viewable', $is_viewable, $post_type ); |
2124 | 2117 | } |
2125 | 2118 | |
2126 | 2119 | /** |