Minor code cleanup in profile module.