dustjs-linkedin
Advanced tools
Comparing version 2.1.3 to 2.1.4
@@ -206,3 +206,3 @@ var dust = {}; | ||
for (;fromIndex < length; fromIndex++) { | ||
if (this[fromIndex] === item) { | ||
if (arr[fromIndex] === item) { | ||
return fromIndex; | ||
@@ -209,0 +209,0 @@ } |
{ | ||
"name": "dustjs-linkedin", | ||
"version": "2.1.3", | ||
"version": "2.1.4", | ||
"author": "Aleksander Williams", | ||
@@ -5,0 +5,0 @@ "description": "Asynchronous templates for the browser and node.js ( LinkedIn fork )", |
@@ -106,2 +106,19 @@ (function(exports){ | ||
}); | ||
suite.test("indexInArray", function() { | ||
var unit = this, | ||
arr = ["hello", "world"], | ||
indexOf; | ||
indexOf = dust.indexInArray(arr, "world"); | ||
unit.equals(indexOf, 1); | ||
indexOf = dust.indexInArray(arr, "foo"); | ||
unit.equals(indexOf, -1); | ||
Array.prototype.indexOf = undefined; | ||
// test indexOf when the array indexOf function is undefined (IE lte 8) | ||
indexOf = dust.indexInArray(arr, "world"); | ||
unit.equals(indexOf, 1); | ||
indexOf = dust.indexInArray(arr, "foo"); | ||
unit.equals(indexOf, -1); | ||
unit.pass(); | ||
}); | ||
} | ||
@@ -108,0 +125,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3135145
110
82340
15
49