This,
if( has_term( 'jazz', 'genre' ) ) {
// do something
}
will check if a post has the term jazz
from the custom taxonomy genre
. But how to check if a post belongs to a custom taxonomy genre
? No matter whatever term it has, as long as it has something from the genre
taxonomy, it will check.
So something like this,
if ( has_taxonomy('genre') ) {
// whether it's jazz, blues, rock and roll; doesn't matter as long as the post has any of them.
}