all-settled.js 582 B

12345678910111213141516
  1. 'use strict';
  2. require('../../modules/es.array.iterator');
  3. require('../../modules/es.object.to-string');
  4. require('../../modules/es.promise');
  5. require('../../modules/es.promise.all-settled');
  6. require('../../modules/es.string.iterator');
  7. var call = require('../../internals/function-call');
  8. var isCallable = require('../../internals/is-callable');
  9. var path = require('../../internals/path');
  10. var Promise = path.Promise;
  11. var $allSettled = Promise.allSettled;
  12. module.exports = function allSettled(iterable) {
  13. return call($allSettled, isCallable(this) ? this : Promise, iterable);
  14. };