Fixes #5418 adds enabled clause for annotations

This likely needs more unit tests as the annotation/metadata unit tests seem very light. Very easy to break something without knowing.