chg: removed code from Array.contains() method and assigned it to Array.includes()
This commit is contained in:
parent
90e91ee9f7
commit
aa2a236d91
1 changed files with 1 additions and 3 deletions
|
@ -28,9 +28,7 @@
|
||||||
* @param {Object} val the value to check
|
* @param {Object} val the value to check
|
||||||
* @return {boolean} true if the value is contained
|
* @return {boolean} true if the value is contained
|
||||||
*/
|
*/
|
||||||
Array.prototype.contains = function(val) {
|
Array.prototype.contains = Array.prototype.includes
|
||||||
return this.indexOf(val) > -1;
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Retrieve the union set of a bunch of arrays
|
* Retrieve the union set of a bunch of arrays
|
||||||
|
|
Loading…
Add table
Reference in a new issue