The hadronic vacuum polarization and automatic Oa$$ \mathcal{O}(a) $$ improvement for twisted mass fermions