diff options
author | Egor Kochetov <gluk47@gmail.com> | 2022-02-10 16:50:36 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:50:36 +0300 |
commit | a1fb24cd1409be21002b3f8d291c3f6cfc113e68 (patch) | |
tree | 5d5cb817648f650d76cf1076100726fd9b8448e8 /library/cpp/protobuf/json/json2proto.cpp | |
parent | 40896b241c91572ea1369526ee1e6ae0ba340f34 (diff) | |
download | ydb-a1fb24cd1409be21002b3f8d291c3f6cfc113e68.tar.gz |
Restoring authorship annotation for Egor Kochetov <gluk47@gmail.com>. Commit 2 of 2.
Diffstat (limited to 'library/cpp/protobuf/json/json2proto.cpp')
-rw-r--r-- | library/cpp/protobuf/json/json2proto.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/library/cpp/protobuf/json/json2proto.cpp b/library/cpp/protobuf/json/json2proto.cpp index 94cab335c9..640c10f5a5 100644 --- a/library/cpp/protobuf/json/json2proto.cpp +++ b/library/cpp/protobuf/json/json2proto.cpp @@ -356,17 +356,17 @@ Json2RepeatedField(const NJson::TJsonValue& json, if (config.ReplaceRepeatedFields) { reflection->ClearField(&proto, &field); } - if (fieldJson.GetType() == NJson::JSON_ARRAY) { - const NJson::TJsonValue::TArray& jsonArray = fieldJson.GetArray(); - for (const NJson::TJsonValue& jsonValue : jsonArray) { - Json2RepeatedFieldValue(jsonValue, proto, field, config, reflection); - } + if (fieldJson.GetType() == NJson::JSON_ARRAY) { + const NJson::TJsonValue::TArray& jsonArray = fieldJson.GetArray(); + for (const NJson::TJsonValue& jsonValue : jsonArray) { + Json2RepeatedFieldValue(jsonValue, proto, field, config, reflection); + } } else if (config.ValueVectorizer) { for (const NJson::TJsonValue& jsonValue : config.ValueVectorizer(fieldJson)) { Json2RepeatedFieldValue(jsonValue, proto, field, config, reflection); } - } else if (config.VectorizeScalars) { - Json2RepeatedFieldValue(fieldJson, proto, field, config, reflection); + } else if (config.VectorizeScalars) { + Json2RepeatedFieldValue(fieldJson, proto, field, config, reflection); } } } |