added custom field logic