Replace getName() method as it was accidentally removed.