Added a custom validator to avatarType to correctly handle missing
avatar.