node_modules/ajv/lib/dotjs/uniqueItems.js in trusty-cms-5.0.6 vs node_modules/ajv/lib/dotjs/uniqueItems.js in trusty-cms-5.0.7

- old
+ new

@@ -27,10 +27,10 @@ if (!$itemType || $itemType == 'object' || $itemType == 'array' || ($typeIsArray && ($itemType.indexOf('object') >= 0 || $itemType.indexOf('array') >= 0))) { out += ' outer: for (;i--;) { for (j = i; j--;) { if (equal(' + ($data) + '[i], ' + ($data) + '[j])) { ' + ($valid) + ' = false; break outer; } } } '; } else { out += ' var itemIndices = {}, item; for (;i--;) { var item = ' + ($data) + '[i]; '; var $method = 'checkDataType' + ($typeIsArray ? 's' : ''); - out += ' if (' + (it.util[$method]($itemType, 'item', true)) + ') continue; '; + out += ' if (' + (it.util[$method]($itemType, 'item', it.opts.strictNumbers, true)) + ') continue; '; if ($typeIsArray) { out += ' if (typeof item == \'string\') item = \'"\' + item; '; } out += ' if (typeof itemIndices[item] == \'number\') { ' + ($valid) + ' = false; j = itemIndices[item]; break; } itemIndices[item] = i; } '; }