commit
33e2a41a94
|
@ -34,7 +34,7 @@
|
|||
for (;i--;) {
|
||||
var item = {{=$data}}[i];
|
||||
if (typeof item != '{{=$itemType}}') continue;
|
||||
if (itemIndices[item] !== undefined) {
|
||||
if (typeof itemIndices[item] == 'number') {
|
||||
{{=$valid}} = false;
|
||||
j = itemIndices[item];
|
||||
break;
|
||||
|
|
|
@ -11,6 +11,11 @@
|
|||
"data": ["foo", "bar", "baz"],
|
||||
"valid": true
|
||||
},
|
||||
{
|
||||
"description": "array of unique items with strings that are properties of hash are valid",
|
||||
"data": ["toString", "foo"],
|
||||
"valid": true
|
||||
},
|
||||
{
|
||||
"description": "array of non-unique strings are invalid",
|
||||
"data": ["foo", "bar", "bar"],
|
||||
|
|
Loading…
Reference in New Issue