Software zum Installieren eines Smart-Mirror Frameworks , zum Nutzen von hochschulrelevanten Informationen, auf einem Raspberry-Pi.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

reject.js 1.7KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. 'use strict';
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. var _reject2 = require('./internal/reject');
  6. var _reject3 = _interopRequireDefault(_reject2);
  7. var _eachOf = require('./eachOf');
  8. var _eachOf2 = _interopRequireDefault(_eachOf);
  9. var _awaitify = require('./internal/awaitify');
  10. var _awaitify2 = _interopRequireDefault(_awaitify);
  11. function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  12. /**
  13. * The opposite of [`filter`]{@link module:Collections.filter}. Removes values that pass an `async` truth test.
  14. *
  15. * @name reject
  16. * @static
  17. * @memberOf module:Collections
  18. * @method
  19. * @see [async.filter]{@link module:Collections.filter}
  20. * @category Collection
  21. * @param {Array|Iterable|AsyncIterable|Object} coll - A collection to iterate over.
  22. * @param {Function} iteratee - An async truth test to apply to each item in
  23. * `coll`.
  24. * The should complete with a boolean value as its `result`.
  25. * Invoked with (item, callback).
  26. * @param {Function} [callback] - A callback which is called after all the
  27. * `iteratee` functions have finished. Invoked with (err, results).
  28. * @returns {Promise} a promise, if no callback is passed
  29. * @example
  30. *
  31. * async.reject(['file1','file2','file3'], function(filePath, callback) {
  32. * fs.access(filePath, function(err) {
  33. * callback(null, !err)
  34. * });
  35. * }, function(err, results) {
  36. * // results now equals an array of missing files
  37. * createFiles(results);
  38. * });
  39. */
  40. function reject(coll, iteratee, callback) {
  41. return (0, _reject3.default)(_eachOf2.default, coll, iteratee, callback);
  42. }
  43. exports.default = (0, _awaitify2.default)(reject, 3);
  44. module.exports = exports['default'];