diffUsing.js 290 B

12345678910
  1. 'use strict';
  2. module.exports = function diffUsing(values, callback) {
  3. var collection = this.items.filter(function (item) {
  4. return !(values && values.some(function (otherItem) {
  5. return callback(item, otherItem) === 0;
  6. }));
  7. });
  8. return new this.constructor(collection);
  9. };