Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

rsvp

Package Overview
Dependencies
Maintainers
5
Versions
51
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rsvp - npm Package Compare versions

Comparing version 3.3.3 to 3.4.0

dist/rsvp.es.js

7

CHANGELOG.md
# Master
# 3.4.0
* [BUGFIX] Fix memory leak [#446]
* Mirror Node's LTS policy
* add dist/rsvp.es.js (bundle as a single ES module file)
* fix typo in readme
# 3.3.3

@@ -4,0 +11,0 @@

2

dist/rsvp.min.js

@@ -1,1 +0,1 @@

!function(t,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports):"function"==typeof define&&define.amd?define(["exports"],r):r(t.RSVP=t.RSVP||{})}(this,function(t){"use strict";function r(t,r){for(var e=0,n=t.length;e<n;e++)if(t[e]===r)return e;return-1}function e(t){var r=t._promiseCallbacks;return r||(r=t._promiseCallbacks={}),r}function n(t,r){return"onerror"===t?void bt.on("error",r):2!==arguments.length?bt[t]:void(bt[t]=r)}function o(t){return"function"==typeof t||"object"==typeof t&&null!==t}function i(t){return"function"==typeof t}function u(t){return"object"==typeof t&&null!==t}function s(){}function a(){setTimeout(function(){for(var t=0;t<St.length;t++){var r=St[t],e=r.payload;e.guid=e.key+e.id,e.childGuid=e.key+e.childId,e.error&&(e.stack=e.error.stack),bt.trigger(r.name,r.payload)}St.length=0},50)}function c(t,r,e){1===St.push({name:t,payload:{key:r._guidKey,id:r._id,eventName:t,detail:r._result,childId:e&&e._id,label:r._label,timeStamp:At(),error:bt["instrument-with-stack"]?new Error(r._label):null}})&&a()}function f(t,r){var e=this;if(t&&"object"==typeof t&&t.constructor===e)return t;var n=new e(h,r);return m(n,t),n}function l(){return new TypeError("A promises callback cannot return that same promise.")}function h(){}function p(t){try{return t.then}catch(r){return Rt.error=r,Rt}}function v(t,r,e,n){try{t.call(r,e,n)}catch(o){return o}}function d(t,r,e){bt.async(function(t){var n=!1,o=v(e,r,function(e){n||(n=!0,r!==e?m(t,e,void 0):g(t,e))},function(r){n||(n=!0,b(t,r))},"Settle: "+(t._label||" unknown promise"));!n&&o&&(n=!0,b(t,o))},t)}function _(t,r){r._state===Ot?g(t,r._result):r._state===Ct?(r._onError=null,b(t,r._result)):E(r,void 0,function(e){r!==e?m(t,e,void 0):g(t,e)},function(r){return b(t,r)})}function y(t,r,e){r.constructor===t.constructor&&e===O&&t.constructor.resolve===f?_(t,r):e===Rt?b(t,Rt.error):void 0===e?g(t,r):i(e)?d(t,r,e):g(t,r)}function m(t,r){t===r?g(t,r):o(r)?y(t,r,p(r)):g(t,r)}function w(t){t._onError&&t._onError(t._result),j(t)}function g(t,r){t._state===kt&&(t._result=r,t._state=Ot,0===t._subscribers.length?bt.instrument&&c("fulfilled",t):bt.async(j,t))}function b(t,r){t._state===kt&&(t._state=Ct,t._result=r,bt.async(w,t))}function E(t,r,e,n){var o=t._subscribers,i=o.length;t._onError=null,o[i]=r,o[i+Ot]=e,o[i+Ct]=n,0===i&&t._state&&bt.async(j,t)}function j(t){var r=t._subscribers,e=t._state;if(bt.instrument&&c(e===Ot?"fulfilled":"rejected",t),0!==r.length){for(var n=void 0,o=void 0,i=t._result,u=0;u<r.length;u+=3)n=r[u],o=r[u+e],n?S(e,n,o,i):o(i);t._subscribers.length=0}}function A(){this.error=null}function T(t,r){try{return t(r)}catch(e){return Mt.error=e,Mt}}function S(t,r,e,n){var o=i(e),u=void 0,s=void 0,a=void 0,c=void 0;if(o){if(u=T(e,n),u===Mt?(c=!0,s=u.error,u=null):a=!0,r===u)return void b(r,l())}else u=n,a=!0;r._state!==kt||(o&&a?m(r,u):c?b(r,s):t===Ot?g(r,u):t===Ct&&b(r,u))}function k(t,r){var e=!1;try{r(function(r){e||(e=!0,m(t,r))},function(r){e||(e=!0,b(t,r))})}catch(n){b(t,n)}}function O(t,r,e){var n=arguments,o=this,i=o._state;if(i===Ot&&!t||i===Ct&&!r)return bt.instrument&&c("chained",o,o),o;o._onError=null;var u=new o.constructor(h,e),s=o._result;return bt.instrument&&c("chained",o,u),i?!function(){var t=n[i-1];bt.async(function(){return S(i,u,t,s)})}():E(o,u,t,r),u}function C(t,r,e){return t===Ot?{state:"fulfilled",value:e}:{state:"rejected",reason:e}}function R(t,r,e,n){this._instanceConstructor=t,this.promise=new t(h,n),this._abortOnReject=e,this._validateInput(r)?(this._input=r,this.length=r.length,this._remaining=r.length,this._init(),0===this.length?g(this.promise,this._result):(this.length=this.length||0,this._enumerate(),0===this._remaining&&g(this.promise,this._result))):b(this.promise,this._validationError())}function M(t,r){return new R(this,t,(!0),r).promise}function P(t,r){var e=this,n=new e(h,r);if(!jt(t))return b(n,new TypeError("You must pass an array to race.")),n;for(var o=0;n._state===kt&&o<t.length;o++)E(e.resolve(t[o]),void 0,function(t){return m(n,t)},function(t){return b(n,t)});return n}function I(t,r){var e=this,n=new e(h,r);return b(n,t),n}function x(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}function N(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}function Y(t,r){this._id=It++,this._label=r,this._state=void 0,this._result=void 0,this._subscribers=[],bt.instrument&&c("created",this),h!==t&&("function"!=typeof t&&x(),this instanceof Y?k(this,t):N())}function D(){this.value=void 0}function K(t){try{return t.then}catch(r){return xt.value=r,xt}}function U(t,r,e){try{t.apply(r,e)}catch(n){return xt.value=n,xt}}function q(t,r){for(var e={},n=t.length,o=new Array(n),i=0;i<n;i++)o[i]=t[i];for(var u=0;u<r.length;u++){var s=r[u];e[s]=o[u+1]}return e}function V(t){for(var r=t.length,e=new Array(r-1),n=1;n<r;n++)e[n-1]=t[n];return e}function F(t,r){return{then:function(e,n){return t.call(r,e,n)}}}function G(t,r){var e=function(){for(var e=this,n=arguments.length,o=new Array(n+1),i=!1,u=0;u<n;++u){var s=arguments[u];if(!i){if(i=$(s),i===Nt){var a=new Y(h);return b(a,Nt.value),a}i&&i!==!0&&(s=F(i,s))}o[u]=s}var c=new Y(h);return o[n]=function(t,e){t?b(c,t):void 0===r?m(c,e):r===!0?m(c,V(arguments)):jt(r)?m(c,q(arguments,r)):m(c,e)},i?W(c,o,t,e):L(c,o,t,e)};return e.__proto__=t,e}function L(t,r,e,n){var o=U(e,n,r);return o===xt&&b(t,o.value),t}function W(t,r,e,n){return Y.all(r).then(function(r){var o=U(e,n,r);return o===xt&&b(t,o.value),t})}function $(t){return!(!t||"object"!=typeof t)&&(t.constructor===Y||K(t))}function z(t,r){return Y.all(t,r)}function B(t,r,e){this._superConstructor(t,r,!1,e)}function H(t,r){return new B(Y,t,r).promise}function J(t,r){return Y.race(t,r)}function Q(t,r,e){this._superConstructor(t,r,!0,e)}function X(t,r){return new Q(Y,t,r).promise}function Z(t,r,e){this._superConstructor(t,r,!1,e)}function tt(t,r){return new Z(Y,t,r).promise}function rt(t){throw setTimeout(function(){throw t}),t}function et(t){var r={resolve:void 0,reject:void 0};return r.promise=new Y(function(t,e){r.resolve=t,r.reject=e},t),r}function nt(t,r,e){return Y.all(t,e).then(function(t){if(!i(r))throw new TypeError("You must pass a function as map's second argument.");for(var n=t.length,o=new Array(n),u=0;u<n;u++)o[u]=r(t[u]);return Y.all(o,e)})}function ot(t,r){return Y.resolve(t,r)}function it(t,r){return Y.reject(t,r)}function ut(t,r){return Y.all(t,r)}function st(t,r){return Y.resolve(t,r).then(function(t){return ut(t,r)})}function at(t,r,e){var n=jt(t)?ut(t,e):st(t,e);return n.then(function(t){if(!i(r))throw new TypeError("You must pass a function as filter's second argument.");for(var n=t.length,o=new Array(n),u=0;u<n;u++)o[u]=r(t[u]);return ut(o,e).then(function(r){for(var e=new Array(n),o=0,i=0;i<n;i++)r[i]&&(e[o]=t[i],o++);return e.length=o,e})})}function ct(t,r){Gt[Yt]=t,Gt[Yt+1]=r,Yt+=2,2===Yt&&Lt()}function ft(){var t=process.nextTick,r=process.versions.node.match(/^(?:(\d+)\.)?(?:(\d+)\.)?(\*|\d+)$/);return Array.isArray(r)&&"0"===r[1]&&"10"===r[2]&&(t=setImmediate),function(){return t(dt)}}function lt(){return"undefined"!=typeof Dt?function(){Dt(dt)}:vt()}function ht(){var t=0,r=new qt(dt),e=document.createTextNode("");return r.observe(e,{characterData:!0}),function(){return e.data=t=++t%2}}function pt(){var t=new MessageChannel;return t.port1.onmessage=dt,function(){return t.port2.postMessage(0)}}function vt(){return function(){return setTimeout(dt,1)}}function dt(){for(var t=0;t<Yt;t+=2){var r=Gt[t],e=Gt[t+1];r(e),Gt[t]=void 0,Gt[t+1]=void 0}Yt=0}function _t(){try{var t=require,r=t("vertx");return Dt=r.runOnLoop||r.runOnContext,lt()}catch(e){return vt()}}function yt(t,r,e){return r in t?Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[r]=e,t}function mt(){bt.on.apply(bt,arguments)}function wt(){bt.off.apply(bt,arguments)}var gt={mixin:function(t){return t.on=this.on,t.off=this.off,t.trigger=this.trigger,t._promiseCallbacks=void 0,t},on:function(t,n){if("function"!=typeof n)throw new TypeError("Callback must be a function");var o=e(this),i=void 0;i=o[t],i||(i=o[t]=[]),r(i,n)===-1&&i.push(n)},off:function(t,n){var o=e(this),i=void 0,u=void 0;return n?(i=o[t],u=r(i,n),void(u!==-1&&i.splice(u,1))):void(o[t]=[])},trigger:function(t,r,n){var o=e(this),i=void 0,u=void 0;if(i=o[t])for(var s=0;s<i.length;s++)(u=i[s])(r,n)}},bt={instrument:!1};gt.mixin(bt);var Et=void 0;Et=Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)};var jt=Et,At=Date.now||function(){return(new Date).getTime()},Tt=Object.create||function(t){if(arguments.length>1)throw new Error("Second argument not supported");if("object"!=typeof t)throw new TypeError("Argument must be an object");return s.prototype=t,new s},St=[],kt=void 0,Ot=1,Ct=2,Rt=new A,Mt=new A;R.prototype._validateInput=function(t){return jt(t)},R.prototype._validationError=function(){return new Error("Array Methods must be provided an Array")},R.prototype._init=function(){this._result=new Array(this.length)},R.prototype._enumerate=function(){for(var t=this.length,r=this.promise,e=this._input,n=0;r._state===kt&&n<t;n++)this._eachEntry(e[n],n)},R.prototype._settleMaybeThenable=function(t,r){var e=this._instanceConstructor,n=e.resolve;if(n===f){var o=p(t);if(o===O&&t._state!==kt)t._onError=null,this._settledAt(t._state,r,t._result);else if("function"!=typeof o)this._remaining--,this._result[r]=this._makeResult(Ot,r,t);else if(e===Y){var i=new e(h);y(i,t,o),this._willSettleAt(i,r)}else this._willSettleAt(new e(function(r){return r(t)}),r)}else this._willSettleAt(n(t),r)},R.prototype._eachEntry=function(t,r){u(t)?this._settleMaybeThenable(t,r):(this._remaining--,this._result[r]=this._makeResult(Ot,r,t))},R.prototype._settledAt=function(t,r,e){var n=this.promise;n._state===kt&&(this._remaining--,this._abortOnReject&&t===Ct?b(n,e):this._result[r]=this._makeResult(t,r,e)),0===this._remaining&&g(n,this._result)},R.prototype._makeResult=function(t,r,e){return e},R.prototype._willSettleAt=function(t,r){var e=this;E(t,void 0,function(t){return e._settledAt(Ot,r,t)},function(t){return e._settledAt(Ct,r,t)})};var Pt="rsvp_"+At()+"-",It=0;Y.cast=f,Y.all=M,Y.race=P,Y.resolve=f,Y.reject=I,Y.prototype={constructor:Y,_guidKey:Pt,_onError:function(t){var r=this;bt.after(function(){r._onError&&bt.trigger("error",t,r._label)})},then:O,"catch":function(t,r){return this.then(void 0,t,r)},"finally":function(t,r){var e=this,n=e.constructor;return e.then(function(r){return n.resolve(t()).then(function(){return r})},function(r){return n.resolve(t()).then(function(){throw r})},r)}};var xt=new D,Nt=new D;B.prototype=Tt(R.prototype),B.prototype._superConstructor=R,B.prototype._makeResult=C,B.prototype._validationError=function(){return new Error("allSettled must be called with an array")},Q.prototype=Tt(R.prototype),Q.prototype._superConstructor=R,Q.prototype._init=function(){this._result={}},Q.prototype._validateInput=function(t){return t&&"object"==typeof t},Q.prototype._validationError=function(){return new Error("Promise.hash must be called with an object")},Q.prototype._enumerate=function(){var t=this,r=t.promise,e=t._input,n=[];for(var o in e)r._state===kt&&Object.prototype.hasOwnProperty.call(e,o)&&n.push({position:o,entry:e[o]});var i=n.length;t._remaining=i;for(var u=void 0,s=0;r._state===kt&&s<i;s++)u=n[s],t._eachEntry(u.entry,u.position)},Z.prototype=Tt(Q.prototype),Z.prototype._superConstructor=R,Z.prototype._makeResult=C,Z.prototype._validationError=function(){return new Error("hashSettled must be called with an object")};var Yt=0,Dt=void 0,Kt="undefined"!=typeof window?window:void 0,Ut=Kt||{},qt=Ut.MutationObserver||Ut.WebKitMutationObserver,Vt="undefined"==typeof self&&"undefined"!=typeof process&&"[object process]"==={}.toString.call(process),Ft="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel,Gt=new Array(1e3),Lt=void 0;Lt=Vt?ft():qt?ht():Ft?pt():void 0===Kt&&"function"==typeof require?_t():vt();var Wt=void 0;if("object"==typeof self)Wt=self;else{if("object"!=typeof global)throw new Error("no global: `self` or `global` found");Wt=global}var $t;bt.async=ct,bt.after=function(t){return setTimeout(t,0)};var zt=ot,Bt=function(t,r){return bt.async(t,r)};if("undefined"!=typeof window&&"object"==typeof window.__PROMISE_INSTRUMENTATION__){var Ht=window.__PROMISE_INSTRUMENTATION__;n("instrument",!0);for(var Jt in Ht)Ht.hasOwnProperty(Jt)&&mt(Jt,Ht[Jt])}var Qt=($t={cast:zt,Promise:Y,EventTarget:gt,all:z,allSettled:H,race:J,hash:X,hashSettled:tt,rethrow:rt,defer:et,denodeify:G,configure:n,on:mt,off:wt,resolve:ot,reject:it,map:nt},yt($t,"async",Bt),yt($t,"filter",at),$t);t["default"]=Qt,t.cast=zt,t.Promise=Y,t.EventTarget=gt,t.all=z,t.allSettled=H,t.race=J,t.hash=X,t.hashSettled=tt,t.rethrow=rt,t.defer=et,t.denodeify=G,t.configure=n,t.on=mt,t.off=wt,t.resolve=ot,t.reject=it,t.map=nt,t.async=Bt,t.filter=at,Object.defineProperty(t,"__esModule",{value:!0})});
(function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(t.RSVP=t.RSVP||{})})(this,function(t){"use strict";function e(t,e){for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}function r(t){var e=t._promiseCallbacks;e||(e=t._promiseCallbacks={});return e}function n(t,e){if("onerror"!==t){if(2!==arguments.length)return bt[t];bt[t]=e}else bt.on("error",e)}function o(t){return"function"==typeof t||"object"==typeof t&&null!==t}function i(t){return"function"==typeof t}function u(t){return"object"==typeof t&&null!==t}function s(){}function a(){setTimeout(function(){for(var t=0;t<St.length;t++){var e=St[t],r=e.payload;r.guid=r.key+r.id;r.childGuid=r.key+r.childId;r.error&&(r.stack=r.error.stack);bt.trigger(e.name,e.payload)}St.length=0},50)}function c(t,e,r){1===St.push({name:t,payload:{key:e._guidKey,id:e._id,eventName:t,detail:e._result,childId:r&&r._id,label:e._label,timeStamp:At(),error:bt["instrument-with-stack"]?new Error(e._label):null}})&&a()}function f(t,e){var r=this;if(t&&"object"==typeof t&&t.constructor===r)return t;var n=new r(h,e);m(n,t);return n}function l(){return new TypeError("A promises callback cannot return that same promise.")}function h(){}function p(t){try{return t.then}catch(e){Rt.error=e;return Rt}}function v(t,e,r,n){try{t.call(e,r,n)}catch(o){return o}}function d(t,e,r){bt.async(function(t){var n=!1,o=v(r,e,function(r){if(!n){n=!0;e!==r?m(t,r,void 0):g(t,r)}},function(e){if(!n){n=!0;b(t,e)}},"Settle: "+(t._label||" unknown promise"));if(!n&&o){n=!0;b(t,o)}},t)}function _(t,e){if(e._state===Ot)g(t,e._result);else if(e._state===Ct){e._onError=null;b(t,e._result)}else E(e,void 0,function(r){e!==r?m(t,r,void 0):g(t,r)},function(e){return b(t,e)})}function y(t,e,r){if(e.constructor===t.constructor&&r===O&&t.constructor.resolve===f)_(t,e);else if(r===Rt){b(t,Rt.error);Rt.error=null}else void 0===r?g(t,e):i(r)?d(t,e,r):g(t,e)}function m(t,e){t===e?g(t,e):o(e)?y(t,e,p(e)):g(t,e)}function w(t){t._onError&&t._onError(t._result);j(t)}function g(t,e){if(t._state===kt){t._result=e;t._state=Ot;0===t._subscribers.length?bt.instrument&&c("fulfilled",t):bt.async(j,t)}}function b(t,e){if(t._state===kt){t._state=Ct;t._result=e;bt.async(w,t)}}function E(t,e,r,n){var o=t._subscribers,i=o.length;t._onError=null;o[i]=e;o[i+Ot]=r;o[i+Ct]=n;0===i&&t._state&&bt.async(j,t)}function j(t){var e=t._subscribers,r=t._state;bt.instrument&&c(r===Ot?"fulfilled":"rejected",t);if(0!==e.length){for(var n=void 0,o=void 0,i=t._result,u=0;u<e.length;u+=3){n=e[u];o=e[u+r];n?S(r,n,o,i):o(i)}t._subscribers.length=0}}function A(){this.error=null}function T(t,e){try{return t(e)}catch(r){Mt.error=r;return Mt}}function S(t,e,r,n){var o=i(r),u=void 0,s=void 0,a=void 0,c=void 0;if(o){u=T(r,n);if(u===Mt){c=!0;s=u.error;u.error=null}else a=!0;if(e===u){b(e,l());return}}else{u=n;a=!0}e._state!==kt||(o&&a?m(e,u):c?b(e,s):t===Ot?g(e,u):t===Ct&&b(e,u))}function k(t,e){var r=!1;try{e(function(e){if(!r){r=!0;m(t,e)}},function(e){if(!r){r=!0;b(t,e)}})}catch(n){b(t,n)}}function O(t,e,r){var n=arguments,o=this,i=o._state;if(i===Ot&&!t||i===Ct&&!e){bt.instrument&&c("chained",o,o);return o}o._onError=null;var u=new o.constructor(h,r),s=o._result;bt.instrument&&c("chained",o,u);i?function(){var t=n[i-1];bt.async(function(){return S(i,u,t,s)})}():E(o,u,t,e);return u}function C(t,e,r){return t===Ot?{state:"fulfilled",value:r}:{state:"rejected",reason:r}}function R(t,e,r,n){this._instanceConstructor=t;this.promise=new t(h,n);this._abortOnReject=r;if(this._validateInput(e)){this._input=e;this.length=e.length;this._remaining=e.length;this._init();if(0===this.length)g(this.promise,this._result);else{this.length=this.length||0;this._enumerate();0===this._remaining&&g(this.promise,this._result)}}else b(this.promise,this._validationError())}function M(t,e){return new R(this,t,(!0),e).promise}function P(t,e){var r=this,n=new r(h,e);if(!jt(t)){b(n,new TypeError("You must pass an array to race."));return n}for(var o=0;n._state===kt&&o<t.length;o++)E(r.resolve(t[o]),void 0,function(t){return m(n,t)},function(t){return b(n,t)});return n}function I(t,e){var r=this,n=new r(h,e);b(n,t);return n}function x(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}function N(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}function Y(t,e){this._id=It++;this._label=e;this._state=void 0;this._result=void 0;this._subscribers=[];bt.instrument&&c("created",this);if(h!==t){"function"!=typeof t&&x();this instanceof Y?k(this,t):N()}}function D(){this.value=void 0}function K(t){try{return t.then}catch(e){xt.value=e;return xt}}function U(t,e,r){try{t.apply(e,r)}catch(n){xt.value=n;return xt}}function q(t,e){for(var r={},n=t.length,o=new Array(n),i=0;i<n;i++)o[i]=t[i];for(var u=0;u<e.length;u++){var s=e[u];r[s]=o[u+1]}return r}function V(t){for(var e=t.length,r=new Array(e-1),n=1;n<e;n++)r[n-1]=t[n];return r}function F(t,e){return{then:function(r,n){return t.call(e,r,n)}}}function G(t,e){var r=function(){for(var r=this,n=arguments.length,o=new Array(n+1),i=!1,u=0;u<n;++u){var s=arguments[u];if(!i){i=$(s);if(i===Nt){var a=new Y(h);b(a,Nt.value);return a}i&&i!==!0&&(s=F(i,s))}o[u]=s}var c=new Y(h);o[n]=function(t,r){t?b(c,t):void 0===e?m(c,r):e===!0?m(c,V(arguments)):jt(e)?m(c,q(arguments,e)):m(c,r)};return i?W(c,o,t,r):L(c,o,t,r)};r.__proto__=t;return r}function L(t,e,r,n){var o=U(r,n,e);o===xt&&b(t,o.value);return t}function W(t,e,r,n){return Y.all(e).then(function(e){var o=U(r,n,e);o===xt&&b(t,o.value);return t})}function $(t){return!(!t||"object"!=typeof t)&&(t.constructor===Y||K(t))}function z(t,e){return Y.all(t,e)}function B(t,e,r){this._superConstructor(t,e,!1,r)}function H(t,e){return new B(Y,t,e).promise}function J(t,e){return Y.race(t,e)}function Q(t,e,r){this._superConstructor(t,e,!0,r)}function X(t,e){return new Q(Y,t,e).promise}function Z(t,e,r){this._superConstructor(t,e,!1,r)}function tt(t,e){return new Z(Y,t,e).promise}function et(t){setTimeout(function(){throw t});throw t}function rt(t){var e={resolve:void 0,reject:void 0};e.promise=new Y(function(t,r){e.resolve=t;e.reject=r},t);return e}function nt(t,e,r){return Y.all(t,r).then(function(t){if(!i(e))throw new TypeError("You must pass a function as map's second argument.");for(var n=t.length,o=new Array(n),u=0;u<n;u++)o[u]=e(t[u]);return Y.all(o,r)})}function ot(t,e){return Y.resolve(t,e)}function it(t,e){return Y.reject(t,e)}function ut(t,e){return Y.all(t,e)}function st(t,e){return Y.resolve(t,e).then(function(t){return ut(t,e)})}function at(t,e,r){var n=jt(t)?ut(t,r):st(t,r);return n.then(function(t){if(!i(e))throw new TypeError("You must pass a function as filter's second argument.");for(var n=t.length,o=new Array(n),u=0;u<n;u++)o[u]=e(t[u]);return ut(o,r).then(function(e){for(var r=new Array(n),o=0,i=0;i<n;i++)if(e[i]){r[o]=t[i];o++}r.length=o;return r})})}function ct(t,e){Gt[Yt]=t;Gt[Yt+1]=e;Yt+=2;2===Yt&&Lt()}function ft(){var t=process.nextTick,e=process.versions.node.match(/^(?:(\d+)\.)?(?:(\d+)\.)?(\*|\d+)$/);Array.isArray(e)&&"0"===e[1]&&"10"===e[2]&&(t=setImmediate);return function(){return t(dt)}}function lt(){return"undefined"!=typeof Dt?function(){Dt(dt)}:vt()}function ht(){var t=0,e=new qt(dt),r=document.createTextNode("");e.observe(r,{characterData:!0});return function(){return r.data=t=++t%2}}function pt(){var t=new MessageChannel;t.port1.onmessage=dt;return function(){return t.port2.postMessage(0)}}function vt(){return function(){return setTimeout(dt,1)}}function dt(){for(var t=0;t<Yt;t+=2){var e=Gt[t],r=Gt[t+1];e(r);Gt[t]=void 0;Gt[t+1]=void 0}Yt=0}function _t(){try{var t=require,e=t("vertx");Dt=e.runOnLoop||e.runOnContext;return lt()}catch(r){return vt()}}function yt(t,e,r){e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r;return t}function mt(){bt.on.apply(bt,arguments)}function wt(){bt.off.apply(bt,arguments)}var gt={mixin:function(t){t.on=this.on;t.off=this.off;t.trigger=this.trigger;t._promiseCallbacks=void 0;return t},on:function(t,n){if("function"!=typeof n)throw new TypeError("Callback must be a function");var o=r(this),i=void 0;i=o[t];i||(i=o[t]=[]);e(i,n)===-1&&i.push(n)},off:function(t,n){var o=r(this),i=void 0,u=void 0;if(n){i=o[t];u=e(i,n);u!==-1&&i.splice(u,1)}else o[t]=[]},trigger:function(t,e,n){var o=r(this),i=void 0,u=void 0;if(i=o[t])for(var s=0;s<i.length;s++){u=i[s];u(e,n)}}},bt={instrument:!1};gt.mixin(bt);var Et=void 0;Et=Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)};var jt=Et,At=Date.now||function(){return(new Date).getTime()},Tt=Object.create||function(t){if(arguments.length>1)throw new Error("Second argument not supported");if("object"!=typeof t)throw new TypeError("Argument must be an object");s.prototype=t;return new s},St=[],kt=void 0,Ot=1,Ct=2,Rt=new A,Mt=new A;R.prototype._validateInput=function(t){return jt(t)};R.prototype._validationError=function(){return new Error("Array Methods must be provided an Array")};R.prototype._init=function(){this._result=new Array(this.length)};R.prototype._enumerate=function(){for(var t=this.length,e=this.promise,r=this._input,n=0;e._state===kt&&n<t;n++)this._eachEntry(r[n],n)};R.prototype._settleMaybeThenable=function(t,e){var r=this._instanceConstructor,n=r.resolve;if(n===f){var o=p(t);if(o===O&&t._state!==kt){t._onError=null;this._settledAt(t._state,e,t._result)}else if("function"!=typeof o){this._remaining--;this._result[e]=this._makeResult(Ot,e,t)}else if(r===Y){var i=new r(h);y(i,t,o);this._willSettleAt(i,e)}else this._willSettleAt(new r(function(e){return e(t)}),e)}else this._willSettleAt(n(t),e)};R.prototype._eachEntry=function(t,e){if(u(t))this._settleMaybeThenable(t,e);else{this._remaining--;this._result[e]=this._makeResult(Ot,e,t)}};R.prototype._settledAt=function(t,e,r){var n=this.promise;if(n._state===kt){this._remaining--;this._abortOnReject&&t===Ct?b(n,r):this._result[e]=this._makeResult(t,e,r)}0===this._remaining&&g(n,this._result)};R.prototype._makeResult=function(t,e,r){return r};R.prototype._willSettleAt=function(t,e){var r=this;E(t,void 0,function(t){return r._settledAt(Ot,e,t)},function(t){return r._settledAt(Ct,e,t)})};var Pt="rsvp_"+At()+"-",It=0;Y.cast=f;Y.all=M;Y.race=P;Y.resolve=f;Y.reject=I;Y.prototype={constructor:Y,_guidKey:Pt,_onError:function(t){var e=this;bt.after(function(){e._onError&&bt.trigger("error",t,e._label)})},then:O,"catch":function(t,e){return this.then(void 0,t,e)},"finally":function(t,e){var r=this,n=r.constructor;return r.then(function(e){return n.resolve(t()).then(function(){return e})},function(e){return n.resolve(t()).then(function(){throw e})},e)}};var xt=new D,Nt=new D;B.prototype=Tt(R.prototype);B.prototype._superConstructor=R;B.prototype._makeResult=C;B.prototype._validationError=function(){return new Error("allSettled must be called with an array")};Q.prototype=Tt(R.prototype);Q.prototype._superConstructor=R;Q.prototype._init=function(){this._result={}};Q.prototype._validateInput=function(t){return t&&"object"==typeof t};Q.prototype._validationError=function(){return new Error("Promise.hash must be called with an object")};Q.prototype._enumerate=function(){var t=this,e=t.promise,r=t._input,n=[];for(var o in r)e._state===kt&&Object.prototype.hasOwnProperty.call(r,o)&&n.push({position:o,entry:r[o]});var i=n.length;t._remaining=i;for(var u=void 0,s=0;e._state===kt&&s<i;s++){u=n[s];t._eachEntry(u.entry,u.position)}};Z.prototype=Tt(Q.prototype);Z.prototype._superConstructor=R;Z.prototype._makeResult=C;Z.prototype._validationError=function(){return new Error("hashSettled must be called with an object")};var Yt=0,Dt=void 0,Kt="undefined"!=typeof window?window:void 0,Ut=Kt||{},qt=Ut.MutationObserver||Ut.WebKitMutationObserver,Vt="undefined"==typeof self&&"undefined"!=typeof process&&"[object process]"==={}.toString.call(process),Ft="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel,Gt=new Array(1e3),Lt=void 0;Lt=Vt?ft():qt?ht():Ft?pt():void 0===Kt&&"function"==typeof require?_t():vt();var Wt=void 0;if("object"==typeof self)Wt=self;else{if("object"!=typeof global)throw new Error("no global: `self` or `global` found");Wt=global}var $t;bt.async=ct;bt.after=function(t){return setTimeout(t,0)};var zt=ot,Bt=function(t,e){return bt.async(t,e)};if("undefined"!=typeof window&&"object"==typeof window.__PROMISE_INSTRUMENTATION__){var Ht=window.__PROMISE_INSTRUMENTATION__;n("instrument",!0);for(var Jt in Ht)Ht.hasOwnProperty(Jt)&&mt(Jt,Ht[Jt])}var Qt=($t={cast:zt,Promise:Y,EventTarget:gt,all:z,allSettled:H,race:J,hash:X,hashSettled:tt,rethrow:et,defer:rt,denodeify:G,configure:n,on:mt,off:wt,resolve:ot,reject:it,map:nt},yt($t,"async",Bt),yt($t,"filter",at),$t);t["default"]=Qt;t.cast=zt;t.Promise=Y;t.EventTarget=gt;t.all=z;t.allSettled=H;t.race=J;t.hash=X;t.hashSettled=tt;t.rethrow=et;t.defer=rt;t.denodeify=G;t.configure=n;t.on=mt;t.off=wt;t.resolve=ot;t.reject=it;t.map=nt;t.async=Bt;t.filter=at;Object.defineProperty(t,"__esModule",{value:!0})});

@@ -91,2 +91,3 @@ import {

reject(promise, GET_THEN_ERROR.error);
GET_THEN_ERROR.error = null;
} else if (then === undefined) {

@@ -208,3 +209,3 @@ fulfill(promise, maybeThenable);

error = value.error;
value = null;
value.error = null; // release
} else {

@@ -211,0 +212,0 @@ succeeded = true;

@@ -414,3 +414,3 @@ import { config } from './config';

} catch(error) {
return findOtherAuther();
return findOtherAuthor();
} finally {

@@ -426,3 +426,3 @@ // always runs

findAuthor().catch(function(reason){
return findOtherAuther();
return findOtherAuthor();
}).finally(function(){

@@ -429,0 +429,0 @@ // author was either found, or not

{
"name": "rsvp",
"namespace": "RSVP",
"version": "3.3.3",
"version": "3.4.0",
"description": "A lightweight library that provides tools for organizing asynchronous code",
"main": "dist/rsvp.js",
"jsnext:main": "lib/rsvp.js",
"module": "dist/rsvp.es.js",
"jsnext:main": "dist/rsvp.es.js",
"files": [

@@ -24,3 +25,3 @@ "dist",

"broccoli-watchify": "v1.0.0",
"ember-cli": "^2.7.0",
"ember-cli": "2.12.0-beta.1",
"ember-cli-dependency-checker": "^1.3.0",

@@ -61,3 +62,6 @@ "ember-publisher": "0.0.7",

"author": "Tilde, Inc. & Stefan Penner",
"license": "MIT"
"license": "MIT",
"engines": {
"node": "0.12.* || 4.* || 6.* || 7.*"
}
}

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc