Extracted getFullName from the execute of AddCommand, hopefully improving readability and reusability.