- result.root <<
- if elt.version == 1
- # first version, so it must be newly-created.
- created = XML::Node.new "create"
- created << elt.to_xml_node(changeset_cache, user_display_name_cache)
- elsif elt.visible
- # must be a modify
- modified = XML::Node.new "modify"
- modified << elt.to_xml_node(changeset_cache, user_display_name_cache)
- else
- # if the element isn't visible then it must have been deleted
- deleted = XML::Node.new "delete"
- deleted << elt.to_xml_node(changeset_cache, user_display_name_cache)
- end
+ if elt.version == 1
+ # first version, so it must be newly-created.
+ @created << elt
+ elsif elt.visible
+ # must be a modify
+ @modified << elt
+ else
+ # if the element isn't visible then it must have been deleted
+ @deleted << elt
+ end