I fixed it.
In case it helps someone else. I added the following in my functions.php file:
add_filter('pre_get_posts', 'query_post_type');
function query_post_type($query) {
if(is_category() || is_tag()) {
$post_type = get_query_var('post_type');
if($post_type)
$post_type = $post_type;
else
$post_type = array('nav_menu_item','post','articles');
$query->set('post_type',$post_type);
return $query;
}
}
I had all of the code apart from: ‘nav_menu_item’ added to the array.