Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

The ‘validateItems’ method now composes a path using the ‘joinPath’ m…

…ethod
  • Loading branch information...
commit 9fb4a57cdbd199c5b21650e2f297656af697026b 1 parent e48b427
@Baggz authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/engines/json/validateItems.js
View
4 src/engines/json/validateItems.js
@@ -32,7 +32,7 @@ Validation.prototype.validateItems = function(instance, schema, path, callback)
if (['object', 'array'].indexOf(schema.items.type) !== -1) {
return each(instance, function(index, propertyValue, callback) {
- var propertyPath = path + '[' + index + ']';
+ var propertyPath = self.joinPath(path, index);
return self.validateSchema(
propertyValue,
@@ -54,7 +54,7 @@ Validation.prototype.validateItems = function(instance, schema, path, callback)
} else {
return each(instance, function(index, propertyValue, callback) {
- var propertyPath = path + '[' + index + ']';
+ var propertyPath = self.joinPath(path, index);
return self.validateProperty(
propertyPath,
Please sign in to comment.
Something went wrong with that request. Please try again.