source: frontend/node_modules/underscore/cjs/contains.js

Last change on this file was 9af201e, checked in by MBK <marija.karapandzova@…>, 11 days ago

Fix frontend appearance

  • Property mode set to 100644
File size: 428 bytes
Line 
1var _isArrayLike = require('./_isArrayLike.js');
2var values = require('./values.js');
3var indexOf = require('./indexOf.js');
4
5// Determine if the array or object contains a given item (using `===`).
6function contains(obj, item, fromIndex, guard) {
7 if (!_isArrayLike(obj)) obj = values(obj);
8 if (typeof fromIndex != 'number' || guard) fromIndex = 0;
9 return indexOf(obj, item, fromIndex) >= 0;
10}
11
12module.exports = contains;
Note: See TracBrowser for help on using the repository browser.