diff --git a/wp-admin/includes/class-wp-posts-list-table.php b/wp-admin/includes/class-wp-posts-list-table.php index a4f10f1a7d..c9c9c13ac8 100644 --- a/wp-admin/includes/class-wp-posts-list-table.php +++ b/wp-admin/includes/class-wp-posts-list-table.php @@ -550,11 +550,13 @@ class WP_Posts_List_Table extends WP_List_Table { if ( 'trash' == $post->post_status || !EMPTY_TRASH_DAYS ) $actions['delete'] = "" . __( 'Delete Permanently' ) . ""; } - if ( in_array( $post->post_status, array( 'pending', 'draft' ) ) ) { - if ( $can_edit_post ) - $actions['view'] = '' . __( 'Preview' ) . ''; - } elseif ( 'trash' != $post->post_status ) { - $actions['view'] = '' . __( 'View' ) . ''; + if ( $post_type_object->publicly_queryable ) { + if ( in_array( $post->post_status, array( 'pending', 'draft' ) ) ) { + if ( $can_edit_post ) + $actions['view'] = '' . __( 'Preview' ) . ''; + } elseif ( 'trash' != $post->post_status ) { + $actions['view'] = '' . __( 'View' ) . ''; + } } $actions = apply_filters( is_post_type_hierarchical( $post->post_type ) ? 'page_row_actions' : 'post_row_actions', $actions, $post );