Fix handling of fields with default values