mirror of
https://github.com/tristanpenman/valijson.git
synced 2024-12-12 10:13:51 +01:00
Minor tidy up of const auto usage
This commit is contained in:
parent
94cef2fa8d
commit
0481a0bb69
@ -283,7 +283,7 @@ public:
|
||||
array.emplace(tree); // Treat as empty array
|
||||
} else {
|
||||
bool isArray = true;
|
||||
for (const auto node : tree) {
|
||||
for (const auto &node : tree) {
|
||||
if (!node.first.empty()) {
|
||||
isArray = false;
|
||||
break;
|
||||
|
@ -232,8 +232,8 @@ public:
|
||||
const typename AdapterType::Array arr = target.asArray();
|
||||
|
||||
bool validated = false;
|
||||
for (auto itr = arr.begin(); itr != arr.end(); ++itr) {
|
||||
ValidationVisitor containsValidator(*itr, context, strictTypes, nullptr);
|
||||
for (const auto &el : arr) {
|
||||
ValidationVisitor containsValidator(el, context, strictTypes, nullptr);
|
||||
if (containsValidator.validateSchema(*subschema)) {
|
||||
validated = true;
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user