Refactored and condensed ENA mapper