Refactored Change of Name Function