mirror of
https://github.com/Azure/k8s-deploy.git
synced 2026-06-26 06:39:27 +08:00
Add node modules and compiled JavaScript from main (#172)
Co-authored-by: Oliver King <oking3@uncc.edu>
This commit is contained in:
committed by
GitHub
parent
ee3c5aed75
commit
08d466b6ab
+19
@@ -0,0 +1,19 @@
|
||||
import getLength from './_getLength.js';
|
||||
import contains from './contains.js';
|
||||
|
||||
// Produce an array that contains every item shared between all the
|
||||
// passed-in arrays.
|
||||
export default function intersection(array) {
|
||||
var result = [];
|
||||
var argsLength = arguments.length;
|
||||
for (var i = 0, length = getLength(array); i < length; i++) {
|
||||
var item = array[i];
|
||||
if (contains(result, item)) continue;
|
||||
var j;
|
||||
for (j = 1; j < argsLength; j++) {
|
||||
if (!contains(arguments[j], item)) break;
|
||||
}
|
||||
if (j === argsLength) result.push(item);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
Reference in New Issue
Block a user