maps utility function