negate.js 218 B

12345678910111213
  1. define(function () {
  2. // Returns a negated version of the passed-in predicate.
  3. function negate(predicate) {
  4. return function() {
  5. return !predicate.apply(this, arguments);
  6. };
  7. }
  8. return negate;
  9. });