Skip to content

Commit

Permalink
Fix codegen for flat members
Browse files Browse the repository at this point in the history
  • Loading branch information
sbiscigl committed May 8, 2023
1 parent 24c1b70 commit 903e169
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -104,15 +104,15 @@
${spaces}XmlNode ${lowerCaseVarName}Node = parentNode.CreateChildElement("${serializationName}");
${spaces}${memberVarName}.AddToNode(${lowerCaseVarName}Node);
#elseif($member.shape.list)
#if($member.flattened)
${spaces}XmlNode ${lowerCaseVarName}ParentNode = parentNode.CreateChildElement("${memberName}");
#elseif(!($member.locationName && $member.shape.flattened))
#if(!($member.locationName && $member.shape.flattened) && !(${member.shape.listMember.locationName} && ${member.isFlattened()}))
${spaces}XmlNode ${lowerCaseVarName}ParentNode = parentNode.CreateChildElement("${serializationName}");
#end
${spaces}for(const auto& item : $memberVarName)
${spaces}{
#if($member.locationName && $member.shape.flattened)
${spaces}XmlNode ${lowerCaseVarName}Node = parentNode.CreateChildElement("${member.locationName}");
#elseif(${member.shape.listMember.locationName} && ${member.isFlattened()})
${spaces}XmlNode ${lowerCaseVarName}Node = parentNode.CreateChildElement("${member.shape.listMember.locationName}");
#elseif(${member.shape.listMember.locationName})
${spaces}XmlNode ${lowerCaseVarName}Node = ${lowerCaseVarName}ParentNode.CreateChildElement("${member.shape.listMember.locationName}");
#else
Expand Down

0 comments on commit 903e169

Please sign in to comment.