Improved code in 'findByName'