KalleOlaviNiemitalo commented on code in PR #1821:
URL: https://github.com/apache/avro/pull/1821#discussion_r943586881


##########
lang/c++/impl/Compiler.cc:
##########
@@ -268,14 +268,14 @@ static const std::unordered_set<std::string>& 
getKnownFields() {
       return kKnownFields;
 }
 
-static void getCustomAttributes(const Object& m, CustomFields 
&customAttributes)
+static void getCustomAttributes(const Object& m, CustomAttributes 
&customAttributes)
 {
   // Don't add known fields on primitive type and fixed type into custom
   // fields.
   const std::unordered_set<std::string>& kKnownFields = getKnownFields();
   for (const auto &entry : m) {
     if (kKnownFields.find(entry.first) == kKnownFields.end()) {
-      customAttributes.addField(entry.first, entry.second);
+      customAttributes.addAttribute(entry.first, entry.second.stringValue());

Review Comment:
   Are custom attributes required to have string values? I thought the plan was 
to store a string in JSON syntax, i.e. including quotation marks if the value 
is a JSON string.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to