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

redux-saga

Package Overview
Dependencies
Maintainers
2
Versions
74
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

redux-saga - npm Package Compare versions

Comparing version 0.14.1 to 0.14.2

README_ko.md

2

dist/redux-saga.min.js

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

!function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.ReduxSaga=n():e.ReduxSaga=n()}(this,function(){return function(e){function n(r){if(t[r])return t[r].exports;var o=t[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}var t={};return n.m=e,n.c=t,n.p="",n(0)}([function(e,n,t){"use strict";function r(e){if(e&&e.__esModule)return e;var n={};if(null!=e)for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t]);return n.default=e,n}function o(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0}),n.utils=n.effects=n.CANCEL=n.delay=n.throttle=n.takeLatest=n.takeEvery=n.buffers=n.channel=n.eventChannel=n.END=n.runSaga=void 0;var a=t(10);Object.defineProperty(n,"runSaga",{enumerable:!0,get:function(){return a.runSaga}});var u=t(2);Object.defineProperty(n,"END",{enumerable:!0,get:function(){return u.END}}),Object.defineProperty(n,"eventChannel",{enumerable:!0,get:function(){return u.eventChannel}}),Object.defineProperty(n,"channel",{enumerable:!0,get:function(){return u.channel}});var i=t(3);Object.defineProperty(n,"buffers",{enumerable:!0,get:function(){return i.buffers}});var c=t(6);Object.defineProperty(n,"takeEvery",{enumerable:!0,get:function(){return c.takeEvery}}),Object.defineProperty(n,"takeLatest",{enumerable:!0,get:function(){return c.takeLatest}}),Object.defineProperty(n,"throttle",{enumerable:!0,get:function(){return c.throttle}});var f=t(1);Object.defineProperty(n,"delay",{enumerable:!0,get:function(){return f.delay}}),Object.defineProperty(n,"CANCEL",{enumerable:!0,get:function(){return f.CANCEL}});var l=t(9),s=o(l),d=t(8),p=r(d),v=t(11),h=r(v);n.default=s.default,n.effects=p,n.utils=h},function(e,n,t){"use strict";function r(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function o(e,n,t){if(!n(e))throw d("error","uncaught at check",t),new Error(t)}function a(e,n){var t=e.indexOf(n);t>=0&&e.splice(t,1)}function u(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=h({},e),t=new Promise(function(e,t){n.resolve=e,n.reject=t});return n.promise=t,n}function i(e){for(var n=[],t=0;t<e;t++)n.push(u());return n}function c(e){var n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],t=void 0,r=new Promise(function(r){t=setTimeout(function(){return r(n)},e)});return r[k]=function(){return clearTimeout(t)},r}function f(){var e,n=!0,t=void 0,o=void 0;return e={},r(e,b,!0),r(e,"isRunning",function(){return n}),r(e,"result",function(){return t}),r(e,"error",function(){return o}),r(e,"setRunning",function(e){return n=e}),r(e,"setResult",function(e){return t=e}),r(e,"setError",function(e){return o=e}),e}function l(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return function(){return++e}}function s(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:A,t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",r=arguments[3],o={name:t,next:e,"throw":n,"return":C};return r&&(o[m]=!0),"undefined"!=typeof Symbol&&(o[Symbol.iterator]=function(){return o}),o}function d(e,n){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";"undefined"==typeof window?console.log("redux-saga "+e+": "+n+"\n"+(t&&t.stack||t)):console[e](n,t)}function p(e,n){return function(){return _&&d("warn",n),e.apply(void 0,arguments)}}function v(e){return function(n){var t=Object.defineProperty(n,E,{value:!0});return e(t)}}Object.defineProperty(n,"__esModule",{value:!0});var h=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},g="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};n.check=o,n.remove=a,n.deferred=u,n.arrayOfDeffered=i,n.delay=c,n.createMockTask=f,n.autoInc=l,n.makeIterator=s,n.log=d,n.deprecate=p,n.wrapSagaDispatch=v;var y=n.sym=function(e){return"@@redux-saga/"+e},b=n.TASK=y("TASK"),m=n.HELPER=y("HELPER"),k=(n.MATCH=y("MATCH"),n.CANCEL=y("cancelPromise")),E=n.SAGA_ACTION=y("SAGA_ACTION"),O=n.konst=function(e){return function(){return e}},_=(n.kTrue=O(!0),n.kFalse=O(!1),n.noop=function(){},n.ident=function(e){return e},n.isDev=!1),j=n.is={undef:function(e){return null===e||void 0===e},notUndef:function(e){return null!==e&&void 0!==e},func:function(e){return"function"==typeof e},number:function(e){return"number"==typeof e},array:Array.isArray,promise:function(e){return e&&j.func(e.then)},iterator:function(e){return e&&j.func(e.next)&&j.func(e.throw)},task:function(e){return e&&e[b]},observable:function(e){return e&&j.func(e.subscribe)},buffer:function(e){return e&&j.func(e.isEmpty)&&j.func(e.take)&&j.func(e.put)},pattern:function(e){return e&&("string"==typeof e||"symbol"===("undefined"==typeof e?"undefined":g(e))||j.func(e)||j.array(e))},channel:function(e){return e&&j.func(e.take)&&j.func(e.close)},helper:function(e){return e&&e[m]}},A=(n.uid=l(),function(e){throw e}),C=function(e){return{value:e,done:!0}};n.internalErr=function(e){return new Error("\n redux-saga: Error checking hooks detected an inconsistent state. This is likely a bug\n in redux-saga code and not yours. Thanks for reporting this in the project's github repo.\n Error: "+e+"\n")}},function(e,n,t){"use strict";function r(){function e(e){return t.push(e),function(){return(0,c.remove)(t,e)}}function n(e){for(var n=t.slice(),r=0,o=n.length;r<o;r++)n[r](e)}var t=[];return{subscribe:e,emit:n}}function o(){function e(){if(u&&i.length)throw(0,c.internalErr)("Cannot have a closed channel with pending takers");if(i.length&&!a.isEmpty())throw(0,c.internalErr)("Cannot have pending takers with non empty buffer")}function n(n){if(e(),(0,c.check)(n,c.is.notUndef,h),!u){if(!i.length)return a.put(n);for(var t=0;t<i.length;t++){var r=i[t];if(!r[c.MATCH]||r[c.MATCH](n))return i.splice(t,1),r(n)}}}function t(n){e(),(0,c.check)(n,c.is.func,"channel.take's callback must be a function"),u&&a.isEmpty()?n(d):a.isEmpty()?(i.push(n),n.cancel=function(){return(0,c.remove)(i,n)}):n(a.take())}function r(n){return e(),(0,c.check)(n,c.is.func,"channel.flush' callback must be a function"),u&&a.isEmpty()?void n(d):void n(a.flush())}function o(){if(e(),!u&&(u=!0,i.length)){var n=i;i=[];for(var t=0,r=n.length;t<r;t++)n[t](d)}}var a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:f.buffers.fixed(),u=!1,i=[];return(0,c.check)(a,c.is.buffer,v),{take:t,put:n,flush:r,close:o,get __takers__(){return i},get __closed__(){return u}}}function a(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:f.buffers.none(),t=arguments[2];arguments.length>2&&(0,c.check)(t,c.is.func,"Invalid match function passed to eventChannel");var r=o(n),a=e(function(e){return p(e)?void r.close():void(t&&!t(e)||r.put(e))});if(!c.is.func(a))throw new Error("in eventChannel: subscribe should return a function to unsubscribe");return{take:r.take,flush:r.flush,close:function(){r.__closed__||(r.close(),a())}}}function u(e){var n=a(function(n){return e(function(e){return e[c.SAGA_ACTION]?void n(e):void(0,l.asap)(function(){return n(e)})})});return i({},n,{take:function(e,t){arguments.length>1&&((0,c.check)(t,c.is.func,"channel.take's matcher argument must be a function"),e[c.MATCH]=t),n.take(e)}})}Object.defineProperty(n,"__esModule",{value:!0}),n.UNDEFINED_INPUT_ERROR=n.INVALID_BUFFER=n.isEnd=n.END=void 0;var i=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e};n.emitter=r,n.channel=o,n.eventChannel=a,n.stdChannel=u;var c=t(1),f=t(3),l=t(7),s="@@redux-saga/CHANNEL_END",d=n.END={type:s},p=n.isEnd=function(e){return e&&e.type===s},v=n.INVALID_BUFFER="invalid buffer passed to channel factory function",h=n.UNDEFINED_INPUT_ERROR="Saga was provided with an undefined action"},function(e,n,t){"use strict";function r(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10,n=arguments[1],t=new Array(e),r=0,o=0,i=0,l=function(n){t[o]=n,o=(o+1)%e,r++},s=function(){if(0!=r){var n=t[i];return t[i]=null,r--,i=(i+1)%e,n}},d=function(){for(var e=[];r;)e.push(s());return e};return{isEmpty:function(){return 0==r},put:function(s){if(r<e)l(s);else{var p=void 0;switch(n){case u:throw new Error(a);case c:t[o]=s,o=(o+1)%e,i=o;break;case f:p=2*e,t=d(),r=t.length,o=t.length,i=0,t.length=p,e=p,l(s)}}},take:s,flush:d}}Object.defineProperty(n,"__esModule",{value:!0}),n.buffers=n.BUFFER_OVERFLOW=void 0;var o=t(1),a=n.BUFFER_OVERFLOW="Channel's Buffer overflow!",u=1,i=2,c=3,f=4,l={isEmpty:o.kTrue,put:o.noop,take:o.noop};n.buffers={none:function(){return l},fixed:function(e){return r(e,u)},dropping:function(e){return r(e,i)},sliding:function(e){return r(e,c)},expanding:function(e){return r(e,f)}}},function(e,n,t){"use strict";function r(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function o(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"*";if(arguments.length&&(0,_.check)(arguments[0],_.is.notUndef,"take(patternOrChannel): patternOrChannel is undefined"),_.is.pattern(e))return H(C,{pattern:e});if(_.is.channel(e))return H(C,{channel:e});throw new Error("take(patternOrChannel): argument "+String(e)+" is not valid channel or a valid pattern")}function a(e,n){return arguments.length>1?((0,_.check)(e,_.is.notUndef,"put(channel, action): argument channel is undefined"),(0,_.check)(e,_.is.channel,"put(channel, action): argument "+e+" is not a valid channel"),(0,_.check)(n,_.is.notUndef,"put(channel, action): argument action is undefined")):((0,_.check)(e,_.is.notUndef,"put(action): argument action is undefined"),n=e,e=null),H(w,{channel:e,action:n})}function u(e){return H(P,e)}function i(e,n,t){(0,_.check)(n,_.is.notUndef,e+": argument fn is undefined");var r=null;if(_.is.array(n)){var o=n,a=O(o,2);r=a[0],n=a[1]}else if(n.fn){var u=n;r=u.context,n=u.fn}return(0,_.check)(n,_.is.func,e+": argument "+n+" is not a function"),{context:r,fn:n,args:t}}function c(e){for(var n=arguments.length,t=Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];return H(T,i("call",e,t))}function f(e,n){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];return H(T,i("apply",{context:e,fn:n},t))}function l(e){for(var n=arguments.length,t=Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];return H(N,i("cps",e,t))}function s(e){for(var n=arguments.length,t=Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];return H(S,i("fork",e,t))}function d(e){for(var n=arguments.length,t=Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];var o=s.apply(void 0,[e].concat(t));return o[S].detached=!0,o}function p(e){if(_.is.array(e))return e.map(p);if((0,_.check)(e,_.is.notUndef,"join(task): argument task is undefined"),!q(e))throw new Error("join(task): argument "+e+" is not a valid Task object \n(HINT: if you are getting this errors in tests, consider using createMockTask from redux-saga/utils)");return H(R,e)}function v(e){if((0,_.check)(e,_.is.notUndef,"cancel(task): argument task is undefined"),!q(e))throw new Error("cancel(task): argument "+e+" is not a valid Task object \n(HINT: if you are getting this errors in tests, consider using createMockTask from redux-saga/utils)");return H(x,e)}function h(e){for(var n=arguments.length,t=Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];return 0===arguments.length?e=_.ident:((0,_.check)(e,_.is.notUndef,"select(selector,[...]): argument selector is undefined"),(0,_.check)(e,_.is.func,"select(selector,[...]): argument "+e+" is not a function")),H(L,{selector:e,args:t})}function g(e,n){return(0,_.check)(e,_.is.notUndef,"actionChannel(pattern,...): argument pattern is undefined"),arguments.length>1&&((0,_.check)(n,_.is.notUndef,"actionChannel(pattern, buffer): argument buffer is undefined"),(0,_.check)(n,_.is.buffer,"actionChannel(pattern, buffer): argument "+n+" is not a valid buffer")),H(U,{pattern:e,buffer:n})}function y(){return H(M,{})}function b(e){return(0,_.check)(e,_.is.channel,"flush(channel): argument "+e+" is not valid channel"),H(I,e)}function m(e,n){for(var t=arguments.length,r=Array(t>2?t-2:0),o=2;o<t;o++)r[o-2]=arguments[o];return s.apply(void 0,[j.takeEveryHelper,e,n].concat(r))}function k(e,n){for(var t=arguments.length,r=Array(t>2?t-2:0),o=2;o<t;o++)r[o-2]=arguments[o];return s.apply(void 0,[j.takeLatestHelper,e,n].concat(r))}function E(e,n,t){for(var r=arguments.length,o=Array(r>3?r-3:0),a=3;a<r;a++)o[a-3]=arguments[a];return s.apply(void 0,[j.throttleHelper,e,n,t].concat(o))}Object.defineProperty(n,"__esModule",{value:!0}),n.asEffect=n.takem=void 0;var O=function(){function e(e,n){var t=[],r=!0,o=!1,a=void 0;try{for(var u,i=e[Symbol.iterator]();!(r=(u=i.next()).done)&&(t.push(u.value),!n||t.length!==n);r=!0);}catch(c){o=!0,a=c}finally{try{!r&&i.return&&i.return()}finally{if(o)throw a}}return t}return function(n,t){if(Array.isArray(n))return n;if(Symbol.iterator in Object(n))return e(n,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();n.take=o,n.put=a,n.race=u,n.call=c,n.apply=f,n.cps=l,n.fork=s,n.spawn=d,n.join=p,n.cancel=v,n.select=h,n.actionChannel=g,n.cancelled=y,n.flush=b,n.takeEvery=m,n.takeLatest=k,n.throttle=E;var _=t(1),j=t(6),A=(0,_.sym)("IO"),C="TAKE",w="PUT",P="RACE",T="CALL",N="CPS",S="FORK",R="JOIN",x="CANCEL",L="SELECT",U="ACTION_CHANNEL",M="CANCELLED",I="FLUSH",D=function(e,n){return e+" has been deprecated in favor of "+n+", please update your code"},H=function(e,n){var t;return t={},r(t,A,!0),r(t,e,n),t};o.maybe=function(){var e=o.apply(void 0,arguments);return e[C].maybe=!0,e};n.takem=(0,_.deprecate)(o.maybe,D("takem","take.maybe"));a.resolve=function(){var e=a.apply(void 0,arguments);return e[w].resolve=!0,e},a.sync=(0,_.deprecate)(a.resolve,D("put.sync","put.resolve"));var q=function(e){return e[_.TASK]},F=function(e){return function(n){return n&&n[A]&&n[e]}};n.asEffect={take:F(C),put:F(w),race:F(P),call:F(T),cps:F(N),fork:F(S),join:F(R),cancel:F(x),select:F(L),actionChannel:F(U),cancelled:F(M),flush:F(I)}},function(e,n,t){"use strict";function r(e,n){for(var t in n){var r=n[t];r.configurable=r.enumerable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,t,r)}return e}function o(e){if(Array.isArray(e)){for(var n=0,t=Array(e.length);n<e.length;n++)t[n]=e[n];return t}return Array.from(e)}function a(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function u(e){return("*"===e?b.wildcard:l.is.array(e)?b.array:l.is.func(e)?b.predicate:b.default)(e)}function i(e,n,t){function r(e){a(),t(e,!0)}function o(e){u.push(e),e.cont=function(o,a){c||((0,l.remove)(u,e),e.cont=l.noop,a?r(o):(e===n&&(i=o),u.length||(c=!0,t(i))))}}function a(){c||(c=!0,u.forEach(function(e){e.cont=l.noop,e.cancel()}),u=[])}var u=[],i=void 0,c=!1;return o(n),{addTask:o,cancelAll:a,abort:r,getTasks:function(){return u},taskNames:function(){return u.map(function(e){return e.name})}}}function c(e){var n=e.context,t=e.fn,r=e.args;if(l.is.iterator(t))return t;var o=void 0,a=void 0;try{o=t.apply(n,r)}catch(u){a=u}return l.is.iterator(o)?o:a?(0,l.makeIterator)(function(){throw a}):(0,l.makeIterator)(function(){var e=void 0,n={done:!1,value:o},t=function(e){return{done:!0,value:e}};return function(r){return e?t(r):(e=!0,n)}}())}function f(e){function n(){Y.isRunning&&!Y.isCancelled&&(Y.isCancelled=!0,b(y))}function t(){e._isRunning&&!e._isCancelled&&(e._isCancelled=!0,Z.cancelAll(),k(y))}function b(n,t){if(!Y.isRunning)throw new Error("Trying to resume an already finished generator");try{var r=void 0;t?r=e.throw(n):n===y?(Y.isCancelled=!0,b.cancel(),r=l.is.func(e.return)?e.return(y):{done:!0,value:y}):r=n===g?l.is.func(e.return)?e.return():{done:!0}:e.next(n),r.done?(Y.isMainRunning=!1,Y.cont&&Y.cont(r.value)):E(r.value,K,"",b)}catch(o){Y.isCancelled&&z("error","uncaught at "+G,o.message),Y.isMainRunning=!1,Y.cont(o,!0)}}function k(n,t){e._isRunning=!1,Q.close(),t?(n instanceof Error&&(n.sagaStack="at "+G+" \n "+(n.sagaStack||n.stack)),X.cont||(z("error","uncaught",n.sagaStack||n.stack),n instanceof Error&&J&&J(n)),e._error=n,e._isAborted=!0,e._deferredEnd&&e._deferredEnd.reject(n)):(n===y&&l.isDev&&z("info",G+" has been cancelled",""),e._result=n,e._deferredEnd&&e._deferredEnd.resolve(n)),X.cont&&X.cont(n,t),X.joiners.forEach(function(e){return e.cb(n,t)}),X.joiners=null}function E(e,n){function t(e,n){u||(u=!0,o.cancel=l.noop,V&&(n?V.effectRejected(a,e):V.effectResolved(a,e)),o(e,n))}var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",o=arguments[3],a=(0,l.uid)();V&&V.effectTriggered({effectId:a,parentEffectId:n,label:r,effect:e});var u=void 0;t.cancel=l.noop,o.cancel=function(){if(!u){u=!0;try{t.cancel()}catch(e){z("error","uncaught at "+G,e.message)}t.cancel=l.noop,V&&V.effectCancelled(a)}};var i=void 0;return l.is.promise(e)?O(e,t):l.is.helper(e)?P(m(e),a,t):l.is.iterator(e)?_(e,a,G,t):l.is.array(e)?S(e,a,t):l.is.notUndef(i=d.asEffect.take(e))?j(i,t):l.is.notUndef(i=d.asEffect.put(e))?A(i,t):l.is.notUndef(i=d.asEffect.race(e))?R(i,a,t):l.is.notUndef(i=d.asEffect.call(e))?C(i,a,t):l.is.notUndef(i=d.asEffect.cps(e))?w(i,t):l.is.notUndef(i=d.asEffect.fork(e))?P(i,a,t):l.is.notUndef(i=d.asEffect.join(e))?T(i,t):l.is.notUndef(i=d.asEffect.cancel(e))?N(i,t):l.is.notUndef(i=d.asEffect.select(e))?x(i,t):l.is.notUndef(i=d.asEffect.actionChannel(e))?L(i,t):l.is.notUndef(i=d.asEffect.flush(e))?M(i,t):l.is.notUndef(i=d.asEffect.cancelled(e))?U(i,t):t(e)}function O(e,n){var t=e[l.CANCEL];"function"==typeof t&&(n.cancel=t),e.then(n,function(e){return n(e,!0)})}function _(e,n,t,r){f(e,D,H,q,F,n,t,r)}function j(e,n){var t=e.channel,r=e.pattern,o=e.maybe;t=t||Q;var a=function(e){return e instanceof Error?n(e,!0):n((0,p.isEnd)(e)&&!o?g:e)};try{t.take(a,u(r))}catch(i){return n(i,!0)}n.cancel=a.cancel}function A(e,n){var t=e.channel,r=e.action,o=e.resolve;(0,s.asap)(function(){var e=void 0;try{e=(t?t.put:H)(r)}catch(a){if(t||o)return n(a,!0);z("error","uncaught at "+G,a.stack||a.message||a)}return o&&l.is.promise(e)?void O(e,n):n(e)})}function C(e,n,t){var r=e.context,o=e.fn,a=e.args,u=void 0;try{u=o.apply(r,a)}catch(i){return t(i,!0)}return l.is.promise(u)?O(u,t):l.is.iterator(u)?_(u,n,o.name,t):t(u)}function w(e,n){var t=e.context,r=e.fn,o=e.args;try{!function(){var e=function(e,t){return l.is.undef(e)?n(t):n(e,!0)};r.apply(t,o.concat(e)),e.cancel&&(n.cancel=function(){return e.cancel()})}()}catch(a){return n(a,!0)}}function P(e,n,t){var r=e.context,o=e.fn,a=e.args,u=e.detached,i=c({context:r,fn:o,args:a});try{(0,s.suspend)();var d=f(i,D,H,q,F,n,o.name,u?null:l.noop);u?t(d):i._isRunning?(Z.addTask(d),t(d)):i._error?Z.abort(i._error):t(d)}finally{(0,s.flush)()}}function T(e,n){e.isRunning()?!function(){var t={task:X,cb:n};n.cancel=function(){return(0,l.remove)(e.joiners,t)},e.joiners.push(t)}():e.isAborted()?n(e.error(),!0):n(e.result())}function N(e,n){e.isRunning()&&e.cancel(),n()}function S(e,n,t){function r(){o===u.length&&(a=!0,t(u))}if(!e.length)return t([]);var o=0,a=void 0,u=Array(e.length),i=e.map(function(e,n){var i=function(e,i){a||(i||(0,p.isEnd)(e)||e===g||e===y?(t.cancel(),t(e,i)):(u[n]=e,o++,r()))};return i.cancel=l.noop,i});t.cancel=function(){a||(a=!0,i.forEach(function(e){return e.cancel()}))},e.forEach(function(e,t){return E(e,n,t,i[t])})}function R(e,n,t){var r=void 0,o=Object.keys(e),u={};o.forEach(function(e){var n=function(n,o){r||(o?(t.cancel(),t(n,!0)):(0,p.isEnd)(n)||n===g||n===y||(t.cancel(),r=!0,t(a({},e,n))))};n.cancel=l.noop,u[e]=n}),t.cancel=function(){r||(r=!0,o.forEach(function(e){return u[e].cancel()}))},o.forEach(function(t){r||E(e[t],n,t,u[t])})}function x(e,n){var t=e.selector,r=e.args;try{var a=t.apply(void 0,[q()].concat(o(r)));n(a)}catch(u){n(u,!0)}}function L(e,n){var t=e.pattern,r=e.buffer,o=u(t);o.pattern=t,n((0,p.eventChannel)(D,r||v.buffers.fixed(),o))}function U(e,n){n(!!Y.isCancelled)}function M(e,n){e.flush(n)}function I(e,n,o,u){var i,c,f;return o._deferredEnd=null,c={},a(c,l.TASK,!0),a(c,"id",e),a(c,"name",n),i="done",f={},f[i]=f[i]||{},f[i].get=function(){if(o._deferredEnd)return o._deferredEnd.promise;var e=(0,l.deferred)();return o._deferredEnd=e,o._isRunning||(o._error?e.reject(o._error):e.resolve(o._result)),e.promise},a(c,"cont",u),a(c,"joiners",[]),a(c,"cancel",t),a(c,"isRunning",function(){return o._isRunning}),a(c,"isCancelled",function(){return o._isCancelled}),a(c,"isAborted",function(){return o._isAborted}),a(c,"result",function(){return o._result}),a(c,"error",function(){return o._error}),r(c,f),c}var D=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){return l.noop},H=arguments.length>2&&void 0!==arguments[2]?arguments[2]:l.noop,q=arguments.length>3&&void 0!==arguments[3]?arguments[3]:l.noop,F=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},K=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,G=arguments.length>6&&void 0!==arguments[6]?arguments[6]:"anonymous",B=arguments[7];(0,l.check)(e,l.is.iterator,h);var V=F.sagaMonitor,W=F.logger,J=F.onError,z=W||l.log,Q=(0,p.stdChannel)(D);b.cancel=l.noop;var X=I(K,G,e,B),Y={name:G,cancel:n,isRunning:!0},Z=i(G,Y,k);return B&&(B.cancel=t),e._isRunning=!0,b(),X}Object.defineProperty(n,"__esModule",{value:!0}),n.TASK_CANCEL=n.CHANNEL_END=n.NOT_ITERATOR_ERROR=void 0,n.default=f;var l=t(1),s=t(7),d=t(4),p=t(2),v=t(3),h=n.NOT_ITERATOR_ERROR="proc first argument (Saga function result) must be an iterator",g=n.CHANNEL_END={toString:function(){return"@@redux-saga/CHANNEL_END"}},y=n.TASK_CANCEL={toString:function(){return"@@redux-saga/TASK_CANCEL"}},b={wildcard:function(){return l.kTrue},"default":function(e){return function(n){return n.type===e}},array:function(e){return function(n){return e.some(function(e){return u(e)(n)})}},predicate:function(e){return function(n){return e(n)}}},m=function(e){return{fn:e}}},function(e,n,t){"use strict";function r(e,n){function t(n,t){if(a===v)return p;if(t)throw a=v,t;o&&o(n);var r=e[a](),u=c(r,3),i=u[0],f=u[1],l=u[2];return a=i,o=l,a===v?p:f}var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"iterator",o=void 0,a=n;return(0,l.makeIterator)(t,function(e){return t(null,e)},r,!0)}function o(e){return l.is.channel(e)?"channel":Array.isArray(e)?String(e.map(function(e){return String(e)})):String(e)}function a(e,n){for(var t=arguments.length,a=Array(t>2?t-2:0),u=2;u<t;u++)a[u-2]=arguments[u];var i={done:!1,value:(0,s.take)(e)},c=function(e){return{done:!1,value:s.fork.apply(void 0,[n].concat(a,[e]))}},l=void 0,d=function(e){return l=e};return r({q1:function(){return["q2",i,d]},q2:function(){return l===f.END?[v]:["q1",c(l)]}},"q1","takeEvery("+o(e)+", "+n.name+")")}function u(e,n){for(var t=arguments.length,a=Array(t>2?t-2:0),u=2;u<t;u++)a[u-2]=arguments[u];var i={done:!1,value:(0,s.take)(e)},c=function(e){return{done:!1,value:s.fork.apply(void 0,[n].concat(a,[e]))}},l=function(e){return{done:!1,value:(0,s.cancel)(e)}},d=void 0,p=void 0,h=function(e){return d=e},g=function(e){return p=e};return r({q1:function(){return["q2",i,g]},q2:function(){return p===f.END?[v]:d?["q3",l(d)]:["q1",c(p),h]},q3:function(){return["q1",c(p),h]}},"q1","takeLatest("+o(e)+", "+n.name+")")}function i(e,n,t){for(var a=arguments.length,u=Array(a>3?a-3:0),i=3;i<a;i++)u[i-3]=arguments[i];var c=void 0,p=void 0,h={done:!1,value:(0,s.actionChannel)(n,d.buffers.sliding(1))},g=function(){return{done:!1,value:(0,s.take)(p,n)}},y=function(e){return{done:!1,value:s.fork.apply(void 0,[t].concat(u,[e]))}},b={done:!1,value:(0,s.call)(l.delay,e)},m=function(e){return c=e},k=function(e){return p=e};return r({q1:function(){return["q2",h,k]},q2:function(){return["q3",g(),m]},q3:function(){return c===f.END?[v]:["q4",y(c)]},q4:function(){return["q2",b]}},"q1","throttle("+o(n)+", "+t.name+")")}Object.defineProperty(n,"__esModule",{value:!0}),n.throttle=n.takeLatest=n.takeEvery=void 0;var c=function(){function e(e,n){var t=[],r=!0,o=!1,a=void 0;try{for(var u,i=e[Symbol.iterator]();!(r=(u=i.next()).done)&&(t.push(u.value),!n||t.length!==n);r=!0);}catch(c){o=!0,a=c}finally{try{!r&&i.return&&i.return()}finally{if(o)throw a}}return t}return function(n,t){if(Array.isArray(n))return n;if(Symbol.iterator in Object(n))return e(n,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();n.takeEveryHelper=a,n.takeLatestHelper=u,n.throttleHelper=i;var f=t(2),l=t(1),s=t(4),d=t(3),p={done:!0,value:void 0},v={},h=function(e){return"import "+e+" from 'redux-saga' has been deprecated in favor of import "+e+" from 'redux-saga/effects'.\nThe latter will not work with yield*, as helper effects are wrapped automatically for you in fork effect.\nTherefore yield "+e+" will return task descriptor to your saga and execute next lines of code."};n.takeEvery=(0,l.deprecate)(a,h("takeEvery")),n.takeLatest=(0,l.deprecate)(u,h("takeLatest")),n.throttle=(0,l.deprecate)(i,h("throttle"))},function(e,n){"use strict";function t(e){try{o(),e()}finally{a()}}function r(e){i?u.push(e):t(e)}function o(){i++}function a(){i--,!i&&u.length&&t(u.shift())}Object.defineProperty(n,"__esModule",{value:!0}),n.asap=r,n.suspend=o,n.flush=a;var u=[],i=0},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t(4);Object.defineProperty(n,"take",{enumerable:!0,get:function(){return r.take}}),Object.defineProperty(n,"takem",{enumerable:!0,get:function(){return r.takem}}),Object.defineProperty(n,"put",{enumerable:!0,get:function(){return r.put}}),Object.defineProperty(n,"race",{enumerable:!0,get:function(){return r.race}}),Object.defineProperty(n,"call",{enumerable:!0,get:function(){return r.call}}),Object.defineProperty(n,"apply",{enumerable:!0,get:function(){return r.apply}}),Object.defineProperty(n,"cps",{enumerable:!0,get:function(){return r.cps}}),Object.defineProperty(n,"fork",{enumerable:!0,get:function(){return r.fork}}),Object.defineProperty(n,"spawn",{enumerable:!0,get:function(){return r.spawn}}),Object.defineProperty(n,"join",{enumerable:!0,get:function(){return r.join}}),Object.defineProperty(n,"cancel",{enumerable:!0,get:function(){return r.cancel}}),Object.defineProperty(n,"select",{enumerable:!0,get:function(){return r.select}}),Object.defineProperty(n,"actionChannel",{enumerable:!0,get:function(){return r.actionChannel}}),Object.defineProperty(n,"cancelled",{enumerable:!0,get:function(){return r.cancelled}}),Object.defineProperty(n,"flush",{enumerable:!0,get:function(){return r.flush}}),Object.defineProperty(n,"takeEvery",{enumerable:!0,get:function(){return r.takeEvery}}),Object.defineProperty(n,"takeLatest",{enumerable:!0,get:function(){return r.takeLatest}}),Object.defineProperty(n,"throttle",{enumerable:!0,get:function(){return r.throttle}})},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function o(e){if(Array.isArray(e)){for(var n=0,t=Array(e.length);n<e.length;n++)t[n]=e[n];return t}return Array.from(e)}function a(){function e(e){function a(e,t,r){return(0,c.default)(e.apply(void 0,o(t)),s.subscribe,d,i,n,r,e.name)}var i=e.getState,l=e.dispatch;t=a;var s=(0,f.emitter)(),d=(0,u.wrapSagaDispatch)(l);return function(e){return function(n){r&&r.actionDispatched(n);var t=e(n);return s.emit(n),t}}}var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=void 0,r=n.sagaMonitor;if(r&&(r.effectTriggered=r.effectTriggered||u.noop,r.effectResolved=r.effectResolved||u.noop,r.effectRejected=r.effectRejected||u.noop,r.effectCancelled=r.effectCancelled||u.noop,r.actionDispatched=r.actionDispatched||u.noop),u.is.func(n))throw new Error("Saga middleware no longer accept Generator functions. Use sagaMiddleware.run instead");if(n.logger&&!u.is.func(n.logger))throw new Error("`options.logger` passed to the Saga middleware is not a function!");if(n.onerror&&(u.isDev&&(0,u.log)("warn","`options.onerror` is deprecated. Use `options.onError` instead."),n.onError=n.onerror,delete n.onerror),n.onError&&!u.is.func(n.onError))throw new Error("`options.onError` passed to the Saga middleware is not a function!");return e.run=function(e){for(var n=arguments.length,o=Array(n>1?n-1:0),a=1;a<n;a++)o[a-1]=arguments[a];(0,u.check)(t,u.is.notUndef,"Before running a Saga, you must mount the Saga middleware on the Store using applyMiddleware"),(0,u.check)(e,u.is.func,"sagaMiddleware.run(saga, ...args): saga argument must be a Generator function!");var i=(0,u.uid)();r&&r.effectTriggered({effectId:i,root:!0,parentEffectId:0,effect:{root:!0,saga:e,args:o}});var c=t(e,o,i);return r&&r.effectResolved(i,c),c},e}Object.defineProperty(n,"__esModule",{value:!0}),n.default=a;var u=t(1),i=t(5),c=r(i),f=t(2)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function o(e,n){var t=n.subscribe,r=n.dispatch,o=n.getState,u=n.sagaMonitor,c=n.logger;(0,a.check)(e,a.is.iterator,"runSaga must be called on an iterator");var f=(0,a.uid)();u&&(r=(0,a.wrapSagaDispatch)(r),u.effectTriggered({effectId:f,root:!0,parentEffectId:0,effect:{root:!0,saga:e,args:[]}}));var l=(0,i.default)(e,t,r,o,{sagaMonitor:u,logger:c},f,e.name);return u&&u.effectResolved(f,l),l}Object.defineProperty(n,"__esModule",{value:!0}),n.runSaga=o;var a=t(1),u=t(5),i=r(u)},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t(1);Object.defineProperty(n,"TASK",{enumerable:!0,get:function(){return r.TASK}}),Object.defineProperty(n,"SAGA_ACTION",{enumerable:!0,get:function(){return r.SAGA_ACTION}}),Object.defineProperty(n,"noop",{enumerable:!0,get:function(){return r.noop}}),Object.defineProperty(n,"is",{enumerable:!0,get:function(){return r.is}}),Object.defineProperty(n,"deferred",{enumerable:!0,get:function(){return r.deferred}}),Object.defineProperty(n,"arrayOfDeffered",{enumerable:!0,get:function(){return r.arrayOfDeffered}}),Object.defineProperty(n,"createMockTask",{enumerable:!0,get:function(){return r.createMockTask}});var o=t(4);Object.defineProperty(n,"asEffect",{enumerable:!0,get:function(){return o.asEffect}});var a=t(2);Object.defineProperty(n,"CHANNEL_END",{enumerable:!0,get:function(){return a.CHANNEL_END}})}])});
!function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.ReduxSaga=n():e.ReduxSaga=n()}(this,function(){return function(e){function n(r){if(t[r])return t[r].exports;var o=t[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}var t={};return n.m=e,n.c=t,n.p="",n(0)}([function(e,n,t){"use strict";function r(e){if(e&&e.__esModule)return e;var n={};if(null!=e)for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t]);return n.default=e,n}function o(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0}),n.utils=n.effects=n.CANCEL=n.delay=n.throttle=n.takeLatest=n.takeEvery=n.buffers=n.channel=n.eventChannel=n.END=n.runSaga=void 0;var a=t(10);Object.defineProperty(n,"runSaga",{enumerable:!0,get:function(){return a.runSaga}});var u=t(2);Object.defineProperty(n,"END",{enumerable:!0,get:function(){return u.END}}),Object.defineProperty(n,"eventChannel",{enumerable:!0,get:function(){return u.eventChannel}}),Object.defineProperty(n,"channel",{enumerable:!0,get:function(){return u.channel}});var i=t(3);Object.defineProperty(n,"buffers",{enumerable:!0,get:function(){return i.buffers}});var c=t(6);Object.defineProperty(n,"takeEvery",{enumerable:!0,get:function(){return c.takeEvery}}),Object.defineProperty(n,"takeLatest",{enumerable:!0,get:function(){return c.takeLatest}}),Object.defineProperty(n,"throttle",{enumerable:!0,get:function(){return c.throttle}});var f=t(1);Object.defineProperty(n,"delay",{enumerable:!0,get:function(){return f.delay}}),Object.defineProperty(n,"CANCEL",{enumerable:!0,get:function(){return f.CANCEL}});var l=t(9),s=o(l),d=t(8),p=r(d),v=t(11),h=r(v);n.default=s.default,n.effects=p,n.utils=h},function(e,n,t){"use strict";function r(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function o(e,n,t){if(!n(e))throw d("error","uncaught at check",t),new Error(t)}function a(e,n){var t=e.indexOf(n);t>=0&&e.splice(t,1)}function u(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=h({},e),t=new Promise(function(e,t){n.resolve=e,n.reject=t});return n.promise=t,n}function i(e){for(var n=[],t=0;t<e;t++)n.push(u());return n}function c(e){var n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],t=void 0,r=new Promise(function(r){t=setTimeout(function(){return r(n)},e)});return r[E]=function(){return clearTimeout(t)},r}function f(){var e,n=!0,t=void 0,o=void 0;return e={},r(e,b,!0),r(e,"isRunning",function(){return n}),r(e,"result",function(){return t}),r(e,"error",function(){return o}),r(e,"setRunning",function(e){return n=e}),r(e,"setResult",function(e){return t=e}),r(e,"setError",function(e){return o=e}),e}function l(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return function(){return++e}}function s(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:A,t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",r=arguments[3],o={name:t,next:e,"throw":n,"return":w};return r&&(o[m]=!0),"undefined"!=typeof Symbol&&(o[Symbol.iterator]=function(){return o}),o}function d(e,n){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";"undefined"==typeof window?console.log("redux-saga "+e+": "+n+"\n"+(t&&t.stack||t)):console[e](n,t)}function p(e,n){return function(){return _&&d("warn",n),e.apply(void 0,arguments)}}function v(e){return function(n){var t=Object.defineProperty(n,k,{value:!0});return e(t)}}Object.defineProperty(n,"__esModule",{value:!0});var h=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},g="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};n.check=o,n.remove=a,n.deferred=u,n.arrayOfDeffered=i,n.delay=c,n.createMockTask=f,n.autoInc=l,n.makeIterator=s,n.log=d,n.deprecate=p,n.wrapSagaDispatch=v;var y=n.sym=function(e){return"@@redux-saga/"+e},b=n.TASK=y("TASK"),m=n.HELPER=y("HELPER"),E=(n.MATCH=y("MATCH"),n.CANCEL=y("cancelPromise")),k=n.SAGA_ACTION=y("SAGA_ACTION"),O=n.konst=function(e){return function(){return e}},_=(n.kTrue=O(!0),n.kFalse=O(!1),n.noop=function(){},n.ident=function(e){return e},n.isDev=!1),j=n.is={undef:function(e){return null===e||void 0===e},notUndef:function(e){return null!==e&&void 0!==e},func:function(e){return"function"==typeof e},number:function(e){return"number"==typeof e},array:Array.isArray,promise:function(e){return e&&j.func(e.then)},iterator:function(e){return e&&j.func(e.next)&&j.func(e.throw)},task:function(e){return e&&e[b]},observable:function(e){return e&&j.func(e.subscribe)},buffer:function(e){return e&&j.func(e.isEmpty)&&j.func(e.take)&&j.func(e.put)},pattern:function(e){return e&&("string"==typeof e||"symbol"===("undefined"==typeof e?"undefined":g(e))||j.func(e)||j.array(e))},channel:function(e){return e&&j.func(e.take)&&j.func(e.close)},helper:function(e){return e&&e[m]}},A=(n.uid=l(),function(e){throw e}),w=function(e){return{value:e,done:!0}};n.internalErr=function(e){return new Error("\n redux-saga: Error checking hooks detected an inconsistent state. This is likely a bug\n in redux-saga code and not yours. Thanks for reporting this in the project's github repo.\n Error: "+e+"\n")}},function(e,n,t){"use strict";function r(){function e(e){return t.push(e),function(){return(0,c.remove)(t,e)}}function n(e){for(var n=t.slice(),r=0,o=n.length;r<o;r++)n[r](e)}var t=[];return{subscribe:e,emit:n}}function o(){function e(){if(u&&i.length)throw(0,c.internalErr)("Cannot have a closed channel with pending takers");if(i.length&&!a.isEmpty())throw(0,c.internalErr)("Cannot have pending takers with non empty buffer")}function n(n){if(e(),(0,c.check)(n,c.is.notUndef,h),!u){if(!i.length)return a.put(n);for(var t=0;t<i.length;t++){var r=i[t];if(!r[c.MATCH]||r[c.MATCH](n))return i.splice(t,1),r(n)}}}function t(n){e(),(0,c.check)(n,c.is.func,"channel.take's callback must be a function"),u&&a.isEmpty()?n(d):a.isEmpty()?(i.push(n),n.cancel=function(){return(0,c.remove)(i,n)}):n(a.take())}function r(n){return e(),(0,c.check)(n,c.is.func,"channel.flush' callback must be a function"),u&&a.isEmpty()?void n(d):void n(a.flush())}function o(){if(e(),!u&&(u=!0,i.length)){var n=i;i=[];for(var t=0,r=n.length;t<r;t++)n[t](d)}}var a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:f.buffers.fixed(),u=!1,i=[];return(0,c.check)(a,c.is.buffer,v),{take:t,put:n,flush:r,close:o,get __takers__(){return i},get __closed__(){return u}}}function a(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:f.buffers.none(),t=arguments[2];arguments.length>2&&(0,c.check)(t,c.is.func,"Invalid match function passed to eventChannel");var r=o(n),a=e(function(e){return p(e)?void r.close():void(t&&!t(e)||r.put(e))});if(!c.is.func(a))throw new Error("in eventChannel: subscribe should return a function to unsubscribe");return{take:r.take,flush:r.flush,close:function(){r.__closed__||(r.close(),a())}}}function u(e){var n=a(function(n){return e(function(e){return e[c.SAGA_ACTION]?void n(e):void(0,l.asap)(function(){return n(e)})})});return i({},n,{take:function(e,t){arguments.length>1&&((0,c.check)(t,c.is.func,"channel.take's matcher argument must be a function"),e[c.MATCH]=t),n.take(e)}})}Object.defineProperty(n,"__esModule",{value:!0}),n.UNDEFINED_INPUT_ERROR=n.INVALID_BUFFER=n.isEnd=n.END=void 0;var i=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e};n.emitter=r,n.channel=o,n.eventChannel=a,n.stdChannel=u;var c=t(1),f=t(3),l=t(7),s="@@redux-saga/CHANNEL_END",d=n.END={type:s},p=n.isEnd=function(e){return e&&e.type===s},v=n.INVALID_BUFFER="invalid buffer passed to channel factory function",h=n.UNDEFINED_INPUT_ERROR="Saga was provided with an undefined action"},function(e,n,t){"use strict";function r(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10,n=arguments[1],t=new Array(e),r=0,o=0,i=0,l=function(n){t[o]=n,o=(o+1)%e,r++},s=function(){if(0!=r){var n=t[i];return t[i]=null,r--,i=(i+1)%e,n}},d=function(){for(var e=[];r;)e.push(s());return e};return{isEmpty:function(){return 0==r},put:function(s){if(r<e)l(s);else{var p=void 0;switch(n){case u:throw new Error(a);case c:t[o]=s,o=(o+1)%e,i=o;break;case f:p=2*e,t=d(),r=t.length,o=t.length,i=0,t.length=p,e=p,l(s)}}},take:s,flush:d}}Object.defineProperty(n,"__esModule",{value:!0}),n.buffers=n.BUFFER_OVERFLOW=void 0;var o=t(1),a=n.BUFFER_OVERFLOW="Channel's Buffer overflow!",u=1,i=2,c=3,f=4,l={isEmpty:o.kTrue,put:o.noop,take:o.noop};n.buffers={none:function(){return l},fixed:function(e){return r(e,u)},dropping:function(e){return r(e,i)},sliding:function(e){return r(e,c)},expanding:function(e){return r(e,f)}}},function(e,n,t){"use strict";function r(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function o(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"*";if(arguments.length&&(0,_.check)(arguments[0],_.is.notUndef,"take(patternOrChannel): patternOrChannel is undefined"),_.is.pattern(e))return H(w,{pattern:e});if(_.is.channel(e))return H(w,{channel:e});throw new Error("take(patternOrChannel): argument "+String(e)+" is not valid channel or a valid pattern")}function a(e,n){return arguments.length>1?((0,_.check)(e,_.is.notUndef,"put(channel, action): argument channel is undefined"),(0,_.check)(e,_.is.channel,"put(channel, action): argument "+e+" is not a valid channel"),(0,_.check)(n,_.is.notUndef,"put(channel, action): argument action is undefined")):((0,_.check)(e,_.is.notUndef,"put(action): argument action is undefined"),n=e,e=null),H(C,{channel:e,action:n})}function u(e){return H(P,e)}function i(e,n,t){(0,_.check)(n,_.is.notUndef,e+": argument fn is undefined");var r=null;if(_.is.array(n)){var o=n,a=O(o,2);r=a[0],n=a[1]}else if(n.fn){var u=n;r=u.context,n=u.fn}return(0,_.check)(n,_.is.func,e+": argument "+n+" is not a function"),{context:r,fn:n,args:t}}function c(e){for(var n=arguments.length,t=Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];return H(T,i("call",e,t))}function f(e,n){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];return H(T,i("apply",{context:e,fn:n},t))}function l(e){for(var n=arguments.length,t=Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];return H(N,i("cps",e,t))}function s(e){for(var n=arguments.length,t=Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];return H(S,i("fork",e,t))}function d(e){for(var n=arguments.length,t=Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];var o=s.apply(void 0,[e].concat(t));return o[S].detached=!0,o}function p(e){if(_.is.array(e))return e.map(p);if((0,_.check)(e,_.is.notUndef,"join(task): argument task is undefined"),!q(e))throw new Error("join(task): argument "+e+" is not a valid Task object \n(HINT: if you are getting this errors in tests, consider using createMockTask from redux-saga/utils)");return H(R,e)}function v(e){if((0,_.check)(e,_.is.notUndef,"cancel(task): argument task is undefined"),!q(e))throw new Error("cancel(task): argument "+e+" is not a valid Task object \n(HINT: if you are getting this errors in tests, consider using createMockTask from redux-saga/utils)");return H(x,e)}function h(e){for(var n=arguments.length,t=Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];return 0===arguments.length?e=_.ident:((0,_.check)(e,_.is.notUndef,"select(selector,[...]): argument selector is undefined"),(0,_.check)(e,_.is.func,"select(selector,[...]): argument "+e+" is not a function")),H(L,{selector:e,args:t})}function g(e,n){return(0,_.check)(e,_.is.notUndef,"actionChannel(pattern,...): argument pattern is undefined"),arguments.length>1&&((0,_.check)(n,_.is.notUndef,"actionChannel(pattern, buffer): argument buffer is undefined"),(0,_.check)(n,_.is.buffer,"actionChannel(pattern, buffer): argument "+n+" is not a valid buffer")),H(U,{pattern:e,buffer:n})}function y(){return H(M,{})}function b(e){return(0,_.check)(e,_.is.channel,"flush(channel): argument "+e+" is not valid channel"),H(I,e)}function m(e,n){for(var t=arguments.length,r=Array(t>2?t-2:0),o=2;o<t;o++)r[o-2]=arguments[o];return s.apply(void 0,[j.takeEveryHelper,e,n].concat(r))}function E(e,n){for(var t=arguments.length,r=Array(t>2?t-2:0),o=2;o<t;o++)r[o-2]=arguments[o];return s.apply(void 0,[j.takeLatestHelper,e,n].concat(r))}function k(e,n,t){for(var r=arguments.length,o=Array(r>3?r-3:0),a=3;a<r;a++)o[a-3]=arguments[a];return s.apply(void 0,[j.throttleHelper,e,n,t].concat(o))}Object.defineProperty(n,"__esModule",{value:!0}),n.asEffect=n.takem=void 0;var O=function(){function e(e,n){var t=[],r=!0,o=!1,a=void 0;try{for(var u,i=e[Symbol.iterator]();!(r=(u=i.next()).done)&&(t.push(u.value),!n||t.length!==n);r=!0);}catch(c){o=!0,a=c}finally{try{!r&&i.return&&i.return()}finally{if(o)throw a}}return t}return function(n,t){if(Array.isArray(n))return n;if(Symbol.iterator in Object(n))return e(n,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();n.take=o,n.put=a,n.race=u,n.call=c,n.apply=f,n.cps=l,n.fork=s,n.spawn=d,n.join=p,n.cancel=v,n.select=h,n.actionChannel=g,n.cancelled=y,n.flush=b,n.takeEvery=m,n.takeLatest=E,n.throttle=k;var _=t(1),j=t(6),A=(0,_.sym)("IO"),w="TAKE",C="PUT",P="RACE",T="CALL",N="CPS",S="FORK",R="JOIN",x="CANCEL",L="SELECT",U="ACTION_CHANNEL",M="CANCELLED",I="FLUSH",D=function(e,n){return e+" has been deprecated in favor of "+n+", please update your code"},H=function(e,n){var t;return t={},r(t,A,!0),r(t,e,n),t};o.maybe=function(){var e=o.apply(void 0,arguments);return e[w].maybe=!0,e};n.takem=(0,_.deprecate)(o.maybe,D("takem","take.maybe"));a.resolve=function(){var e=a.apply(void 0,arguments);return e[C].resolve=!0,e},a.sync=(0,_.deprecate)(a.resolve,D("put.sync","put.resolve"));var q=function(e){return e[_.TASK]},F=function(e){return function(n){return n&&n[A]&&n[e]}};n.asEffect={take:F(w),put:F(C),race:F(P),call:F(T),cps:F(N),fork:F(S),join:F(R),cancel:F(x),select:F(L),actionChannel:F(U),cancelled:F(M),flush:F(I)}},function(e,n,t){"use strict";function r(e,n){for(var t in n){var r=n[t];r.configurable=r.enumerable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,t,r)}return e}function o(e){if(Array.isArray(e)){for(var n=0,t=Array(e.length);n<e.length;n++)t[n]=e[n];return t}return Array.from(e)}function a(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function u(e){return("*"===e?b.wildcard:l.is.array(e)?b.array:l.is.func(e)?b.predicate:b.default)(e)}function i(e,n,t){function r(e){a(),t(e,!0)}function o(e){u.push(e),e.cont=function(o,a){c||((0,l.remove)(u,e),e.cont=l.noop,a?r(o):(e===n&&(i=o),u.length||(c=!0,t(i))))}}function a(){c||(c=!0,u.forEach(function(e){e.cont=l.noop,e.cancel()}),u=[])}var u=[],i=void 0,c=!1;return o(n),{addTask:o,cancelAll:a,abort:r,getTasks:function(){return u},taskNames:function(){return u.map(function(e){return e.name})}}}function c(e){var n=e.context,t=e.fn,r=e.args;if(l.is.iterator(t))return t;var o=void 0,a=void 0;try{o=t.apply(n,r)}catch(u){a=u}return l.is.iterator(o)?o:a?(0,l.makeIterator)(function(){throw a}):(0,l.makeIterator)(function(){var e=void 0,n={done:!1,value:o},t=function(e){return{done:!0,value:e}};return function(r){return e?t(r):(e=!0,n)}}())}function f(e){function n(){Y.isRunning&&!Y.isCancelled&&(Y.isCancelled=!0,b(y))}function t(){e._isRunning&&!e._isCancelled&&(e._isCancelled=!0,Z.cancelAll(),E(y))}function b(n,t){if(!Y.isRunning)throw new Error("Trying to resume an already finished generator");try{var r=void 0;t?r=e.throw(n):n===y?(Y.isCancelled=!0,b.cancel(),r=l.is.func(e.return)?e.return(y):{done:!0,value:y}):r=n===g?l.is.func(e.return)?e.return():{done:!0}:e.next(n),r.done?(Y.isMainRunning=!1,Y.cont&&Y.cont(r.value)):k(r.value,K,"",b)}catch(o){Y.isCancelled&&z("error","uncaught at "+G,o.message),Y.isMainRunning=!1,Y.cont(o,!0)}}function E(n,t){e._isRunning=!1,Q.close(),t?(n instanceof Error&&(n.sagaStack="at "+G+" \n "+(n.sagaStack||n.stack)),X.cont||(z("error","uncaught",n.sagaStack||n.stack),n instanceof Error&&J&&J(n)),e._error=n,e._isAborted=!0,e._deferredEnd&&e._deferredEnd.reject(n)):(n===y&&l.isDev&&z("info",G+" has been cancelled",""),e._result=n,e._deferredEnd&&e._deferredEnd.resolve(n)),X.cont&&X.cont(n,t),X.joiners.forEach(function(e){return e.cb(n,t)}),X.joiners=null}function k(e,n){function t(e,n){u||(u=!0,o.cancel=l.noop,V&&(n?V.effectRejected(a,e):V.effectResolved(a,e)),o(e,n))}var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",o=arguments[3],a=(0,l.uid)();V&&V.effectTriggered({effectId:a,parentEffectId:n,label:r,effect:e});var u=void 0;t.cancel=l.noop,o.cancel=function(){if(!u){u=!0;try{t.cancel()}catch(e){z("error","uncaught at "+G,e.message)}t.cancel=l.noop,V&&V.effectCancelled(a)}};var i=void 0;return l.is.promise(e)?O(e,t):l.is.helper(e)?P(m(e),a,t):l.is.iterator(e)?_(e,a,G,t):l.is.array(e)?S(e,a,t):l.is.notUndef(i=d.asEffect.take(e))?j(i,t):l.is.notUndef(i=d.asEffect.put(e))?A(i,t):l.is.notUndef(i=d.asEffect.race(e))?R(i,a,t):l.is.notUndef(i=d.asEffect.call(e))?w(i,a,t):l.is.notUndef(i=d.asEffect.cps(e))?C(i,t):l.is.notUndef(i=d.asEffect.fork(e))?P(i,a,t):l.is.notUndef(i=d.asEffect.join(e))?T(i,t):l.is.notUndef(i=d.asEffect.cancel(e))?N(i,t):l.is.notUndef(i=d.asEffect.select(e))?x(i,t):l.is.notUndef(i=d.asEffect.actionChannel(e))?L(i,t):l.is.notUndef(i=d.asEffect.flush(e))?M(i,t):l.is.notUndef(i=d.asEffect.cancelled(e))?U(i,t):t(e)}function O(e,n){var t=e[l.CANCEL];"function"==typeof t&&(n.cancel=t),e.then(n,function(e){return n(e,!0)})}function _(e,n,t,r){f(e,D,H,q,F,n,t,r)}function j(e,n){var t=e.channel,r=e.pattern,o=e.maybe;t=t||Q;var a=function(e){return e instanceof Error?n(e,!0):n((0,p.isEnd)(e)&&!o?g:e)};try{t.take(a,u(r))}catch(i){return n(i,!0)}n.cancel=a.cancel}function A(e,n){var t=e.channel,r=e.action,o=e.resolve;(0,s.asap)(function(){var e=void 0;try{e=(t?t.put:H)(r)}catch(a){if(t||o)return n(a,!0);z("error","uncaught at "+G,a.stack||a.message||a)}return o&&l.is.promise(e)?void O(e,n):n(e)})}function w(e,n,t){var r=e.context,o=e.fn,a=e.args,u=void 0;try{u=o.apply(r,a)}catch(i){return t(i,!0)}return l.is.promise(u)?O(u,t):l.is.iterator(u)?_(u,n,o.name,t):t(u)}function C(e,n){var t=e.context,r=e.fn,o=e.args;try{!function(){var e=function(e,t){return l.is.undef(e)?n(t):n(e,!0)};r.apply(t,o.concat(e)),e.cancel&&(n.cancel=function(){return e.cancel()})}()}catch(a){return n(a,!0)}}function P(e,n,t){var r=e.context,o=e.fn,a=e.args,u=e.detached,i=c({context:r,fn:o,args:a});try{(0,s.suspend)();var d=f(i,D,H,q,F,n,o.name,u?null:l.noop);u?t(d):i._isRunning?(Z.addTask(d),t(d)):i._error?Z.abort(i._error):t(d)}finally{(0,s.flush)()}}function T(e,n){e.isRunning()?!function(){var t={task:X,cb:n};n.cancel=function(){return(0,l.remove)(e.joiners,t)},e.joiners.push(t)}():e.isAborted()?n(e.error(),!0):n(e.result())}function N(e,n){e.isRunning()&&e.cancel(),n()}function S(e,n,t){function r(){o===u.length&&(a=!0,t(u))}if(!e.length)return t([]);var o=0,a=void 0,u=Array(e.length),i=e.map(function(e,n){var i=function(e,i){a||(i||(0,p.isEnd)(e)||e===g||e===y?(t.cancel(),t(e,i)):(u[n]=e,o++,r()))};return i.cancel=l.noop,i});t.cancel=function(){a||(a=!0,i.forEach(function(e){return e.cancel()}))},e.forEach(function(e,t){return k(e,n,t,i[t])})}function R(e,n,t){var r=void 0,o=Object.keys(e),u={};o.forEach(function(e){var n=function(n,o){r||(o?(t.cancel(),t(n,!0)):(0,p.isEnd)(n)||n===g||n===y||(t.cancel(),r=!0,t(a({},e,n))))};n.cancel=l.noop,u[e]=n}),t.cancel=function(){r||(r=!0,o.forEach(function(e){return u[e].cancel()}))},o.forEach(function(t){r||k(e[t],n,t,u[t])})}function x(e,n){var t=e.selector,r=e.args;try{var a=t.apply(void 0,[q()].concat(o(r)));n(a)}catch(u){n(u,!0)}}function L(e,n){var t=e.pattern,r=e.buffer,o=u(t);o.pattern=t,n((0,p.eventChannel)(D,r||v.buffers.fixed(),o))}function U(e,n){n(!!Y.isCancelled)}function M(e,n){e.flush(n)}function I(e,n,o,u){var i,c,f;return o._deferredEnd=null,c={},a(c,l.TASK,!0),a(c,"id",e),a(c,"name",n),i="done",f={},f[i]=f[i]||{},f[i].get=function(){if(o._deferredEnd)return o._deferredEnd.promise;var e=(0,l.deferred)();return o._deferredEnd=e,o._isRunning||(o._error?e.reject(o._error):e.resolve(o._result)),e.promise},a(c,"cont",u),a(c,"joiners",[]),a(c,"cancel",t),a(c,"isRunning",function(){return o._isRunning}),a(c,"isCancelled",function(){return o._isCancelled}),a(c,"isAborted",function(){return o._isAborted}),a(c,"result",function(){return o._result}),a(c,"error",function(){return o._error}),r(c,f),c}var D=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){return l.noop},H=arguments.length>2&&void 0!==arguments[2]?arguments[2]:l.noop,q=arguments.length>3&&void 0!==arguments[3]?arguments[3]:l.noop,F=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},K=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,G=arguments.length>6&&void 0!==arguments[6]?arguments[6]:"anonymous",B=arguments[7];(0,l.check)(e,l.is.iterator,h);var V=F.sagaMonitor,W=F.logger,J=F.onError,z=W||l.log,Q=(0,p.stdChannel)(D);b.cancel=l.noop;var X=I(K,G,e,B),Y={name:G,cancel:n,isRunning:!0},Z=i(G,Y,E);return B&&(B.cancel=t),e._isRunning=!0,b(),X}Object.defineProperty(n,"__esModule",{value:!0}),n.TASK_CANCEL=n.CHANNEL_END=n.NOT_ITERATOR_ERROR=void 0,n.default=f;var l=t(1),s=t(7),d=t(4),p=t(2),v=t(3),h=n.NOT_ITERATOR_ERROR="proc first argument (Saga function result) must be an iterator",g=n.CHANNEL_END={toString:function(){return"@@redux-saga/CHANNEL_END"}},y=n.TASK_CANCEL={toString:function(){return"@@redux-saga/TASK_CANCEL"}},b={wildcard:function(){return l.kTrue},"default":function(e){return function(n){return n.type===e}},array:function(e){return function(n){return e.some(function(e){return u(e)(n)})}},predicate:function(e){return function(n){return e(n)}}},m=function(e){return{fn:e}}},function(e,n,t){"use strict";function r(e,n){function t(n,t){if(a===v)return p;if(t)throw a=v,t;o&&o(n);var r=e[a](),u=c(r,3),i=u[0],f=u[1],l=u[2];return a=i,o=l,a===v?p:f}var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"iterator",o=void 0,a=n;return(0,l.makeIterator)(t,function(e){return t(null,e)},r,!0)}function o(e){return l.is.channel(e)?"channel":Array.isArray(e)?String(e.map(function(e){return String(e)})):String(e)}function a(e,n){for(var t=arguments.length,a=Array(t>2?t-2:0),u=2;u<t;u++)a[u-2]=arguments[u];var i={done:!1,value:(0,s.take)(e)},c=function(e){return{done:!1,value:s.fork.apply(void 0,[n].concat(a,[e]))}},l=void 0,d=function(e){return l=e};return r({q1:function(){return["q2",i,d]},q2:function(){return l===f.END?[v]:["q1",c(l)]}},"q1","takeEvery("+o(e)+", "+n.name+")")}function u(e,n){for(var t=arguments.length,a=Array(t>2?t-2:0),u=2;u<t;u++)a[u-2]=arguments[u];var i={done:!1,value:(0,s.take)(e)},c=function(e){return{done:!1,value:s.fork.apply(void 0,[n].concat(a,[e]))}},l=function(e){return{done:!1,value:(0,s.cancel)(e)}},d=void 0,p=void 0,h=function(e){return d=e},g=function(e){return p=e};return r({q1:function(){return["q2",i,g]},q2:function(){return p===f.END?[v]:d?["q3",l(d)]:["q1",c(p),h]},q3:function(){return["q1",c(p),h]}},"q1","takeLatest("+o(e)+", "+n.name+")")}function i(e,n,t){for(var a=arguments.length,u=Array(a>3?a-3:0),i=3;i<a;i++)u[i-3]=arguments[i];var c=void 0,p=void 0,h={done:!1,value:(0,s.actionChannel)(n,d.buffers.sliding(1))},g=function(){return{done:!1,value:(0,s.take)(p,n)}},y=function(e){return{done:!1,value:s.fork.apply(void 0,[t].concat(u,[e]))}},b={done:!1,value:(0,s.call)(l.delay,e)},m=function(e){return c=e},E=function(e){return p=e};return r({q1:function(){return["q2",h,E]},q2:function(){return["q3",g(),m]},q3:function(){return c===f.END?[v]:["q4",y(c)]},q4:function(){return["q2",b]}},"q1","throttle("+o(n)+", "+t.name+")")}Object.defineProperty(n,"__esModule",{value:!0}),n.throttle=n.takeLatest=n.takeEvery=void 0;var c=function(){function e(e,n){var t=[],r=!0,o=!1,a=void 0;try{for(var u,i=e[Symbol.iterator]();!(r=(u=i.next()).done)&&(t.push(u.value),!n||t.length!==n);r=!0);}catch(c){o=!0,a=c}finally{try{!r&&i.return&&i.return()}finally{if(o)throw a}}return t}return function(n,t){if(Array.isArray(n))return n;if(Symbol.iterator in Object(n))return e(n,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();n.takeEveryHelper=a,n.takeLatestHelper=u,n.throttleHelper=i;var f=t(2),l=t(1),s=t(4),d=t(3),p={done:!0,value:void 0},v={},h=function(e){return"import "+e+" from 'redux-saga' has been deprecated in favor of import "+e+" from 'redux-saga/effects'.\nThe latter will not work with yield*, as helper effects are wrapped automatically for you in fork effect.\nTherefore yield "+e+" will return task descriptor to your saga and execute next lines of code."};n.takeEvery=(0,l.deprecate)(a,h("takeEvery")),n.takeLatest=(0,l.deprecate)(u,h("takeLatest")),n.throttle=(0,l.deprecate)(i,h("throttle"))},function(e,n){"use strict";function t(e){try{o(),e()}finally{a()}}function r(e){i?u.push(e):t(e)}function o(){i++}function a(){i--,!i&&u.length&&t(u.shift())}Object.defineProperty(n,"__esModule",{value:!0}),n.asap=r,n.suspend=o,n.flush=a;var u=[],i=0},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t(4);Object.defineProperty(n,"take",{enumerable:!0,get:function(){return r.take}}),Object.defineProperty(n,"takem",{enumerable:!0,get:function(){return r.takem}}),Object.defineProperty(n,"put",{enumerable:!0,get:function(){return r.put}}),Object.defineProperty(n,"race",{enumerable:!0,get:function(){return r.race}}),Object.defineProperty(n,"call",{enumerable:!0,get:function(){return r.call}}),Object.defineProperty(n,"apply",{enumerable:!0,get:function(){return r.apply}}),Object.defineProperty(n,"cps",{enumerable:!0,get:function(){return r.cps}}),Object.defineProperty(n,"fork",{enumerable:!0,get:function(){return r.fork}}),Object.defineProperty(n,"spawn",{enumerable:!0,get:function(){return r.spawn}}),Object.defineProperty(n,"join",{enumerable:!0,get:function(){return r.join}}),Object.defineProperty(n,"cancel",{enumerable:!0,get:function(){return r.cancel}}),Object.defineProperty(n,"select",{enumerable:!0,get:function(){return r.select}}),Object.defineProperty(n,"actionChannel",{enumerable:!0,get:function(){return r.actionChannel}}),Object.defineProperty(n,"cancelled",{enumerable:!0,get:function(){return r.cancelled}}),Object.defineProperty(n,"flush",{enumerable:!0,get:function(){return r.flush}}),Object.defineProperty(n,"takeEvery",{enumerable:!0,get:function(){return r.takeEvery}}),Object.defineProperty(n,"takeLatest",{enumerable:!0,get:function(){return r.takeLatest}}),Object.defineProperty(n,"throttle",{enumerable:!0,get:function(){return r.throttle}})},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function o(e){if(Array.isArray(e)){for(var n=0,t=Array(e.length);n<e.length;n++)t[n]=e[n];return t}return Array.from(e)}function a(){function e(e){function a(e,t,r){return(0,c.default)(e.apply(void 0,o(t)),s.subscribe,d,i,n,r,e.name)}var i=e.getState,l=e.dispatch;t=a;var s=(0,f.emitter)();s.emit=(n.emitter||u.ident)(s.emit);var d=(0,u.wrapSagaDispatch)(l);return function(e){return function(n){r&&r.actionDispatched(n);var t=e(n);return s.emit(n),t}}}var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=void 0,r=n.sagaMonitor;if(r&&(r.effectTriggered=r.effectTriggered||u.noop,r.effectResolved=r.effectResolved||u.noop,r.effectRejected=r.effectRejected||u.noop,r.effectCancelled=r.effectCancelled||u.noop,r.actionDispatched=r.actionDispatched||u.noop),u.is.func(n))throw new Error("Saga middleware no longer accept Generator functions. Use sagaMiddleware.run instead");if(n.logger&&!u.is.func(n.logger))throw new Error("`options.logger` passed to the Saga middleware is not a function!");if(n.onerror&&(u.isDev&&(0,u.log)("warn","`options.onerror` is deprecated. Use `options.onError` instead."),n.onError=n.onerror,delete n.onerror),n.onError&&!u.is.func(n.onError))throw new Error("`options.onError` passed to the Saga middleware is not a function!");if(n.emitter&&!u.is.func(n.emitter))throw new Error("`options.emitter` passed to the Saga middleware is not a function!");return e.run=function(e){for(var n=arguments.length,o=Array(n>1?n-1:0),a=1;a<n;a++)o[a-1]=arguments[a];(0,u.check)(t,u.is.notUndef,"Before running a Saga, you must mount the Saga middleware on the Store using applyMiddleware"),(0,u.check)(e,u.is.func,"sagaMiddleware.run(saga, ...args): saga argument must be a Generator function!");var i=(0,u.uid)();r&&r.effectTriggered({effectId:i,root:!0,parentEffectId:0,effect:{root:!0,saga:e,args:o}});var c=t(e,o,i);return r&&r.effectResolved(i,c),c},e}Object.defineProperty(n,"__esModule",{value:!0}),n.default=a;var u=t(1),i=t(5),c=r(i),f=t(2)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function o(e,n){var t=n.subscribe,r=n.dispatch,o=n.getState,u=n.sagaMonitor,c=n.logger;(0,a.check)(e,a.is.iterator,"runSaga must be called on an iterator");var f=(0,a.uid)();u&&(r=(0,a.wrapSagaDispatch)(r),u.effectTriggered({effectId:f,root:!0,parentEffectId:0,effect:{root:!0,saga:e,args:[]}}));var l=(0,i.default)(e,t,r,o,{sagaMonitor:u,logger:c},f,e.name);return u&&u.effectResolved(f,l),l}Object.defineProperty(n,"__esModule",{value:!0}),n.runSaga=o;var a=t(1),u=t(5),i=r(u)},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t(1);Object.defineProperty(n,"TASK",{enumerable:!0,get:function(){return r.TASK}}),Object.defineProperty(n,"SAGA_ACTION",{enumerable:!0,get:function(){return r.SAGA_ACTION}}),Object.defineProperty(n,"noop",{enumerable:!0,get:function(){return r.noop}}),Object.defineProperty(n,"is",{enumerable:!0,get:function(){return r.is}}),Object.defineProperty(n,"deferred",{enumerable:!0,get:function(){return r.deferred}}),Object.defineProperty(n,"arrayOfDeffered",{enumerable:!0,get:function(){return r.arrayOfDeffered}}),Object.defineProperty(n,"createMockTask",{enumerable:!0,get:function(){return r.createMockTask}});var o=t(4);Object.defineProperty(n,"asEffect",{enumerable:!0,get:function(){return o.asEffect}});var a=t(2);Object.defineProperty(n,"CHANNEL_END",{enumerable:!0,get:function(){return a.CHANNEL_END}})}])});

@@ -6,2 +6,3 @@ function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }

import { emitter } from './channel';
import { ident } from './utils';

@@ -46,2 +47,6 @@ export default function sagaMiddlewareFactory() {

if (options.emitter && !is.func(options.emitter)) {
throw new Error('`options.emitter` passed to the Saga middleware is not a function!');
}
function sagaMiddleware(_ref) {

@@ -53,2 +58,3 @@ var getState = _ref.getState,

var sagaEmitter = emitter();
sagaEmitter.emit = (options.emitter || ident)(sagaEmitter.emit);
var sagaDispatch = wrapSagaDispatch(dispatch);

@@ -55,0 +61,0 @@

@@ -48,4 +48,5 @@ import {Action, Middleware} from "redux";

export default function sagaMiddlewareFactory(options?: {
export default function sagaMiddlewareFactory<T>(options?: {
sagaMonitor?: Monitor;
emitter: (emit: Emit<T>) => Emit<T>;
}): SagaMiddleware;

@@ -57,3 +58,9 @@

export type Emit<T> = (input: T) => void;
export interface Emitter<T> {
emit(message: T): void;
subscribe: Subscribe<T>;
}
export function runSaga<S, SA, DA>(iterator: SagaIterator, io: {

@@ -60,0 +67,0 @@ subscribe: Subscribe<SA>;

@@ -58,2 +58,6 @@ 'use strict';

if (options.emitter && !_utils.is.func(options.emitter)) {
throw new Error('`options.emitter` passed to the Saga middleware is not a function!');
}
function sagaMiddleware(_ref) {

@@ -65,2 +69,3 @@ var getState = _ref.getState,

var sagaEmitter = (0, _channel.emitter)();
sagaEmitter.emit = (options.emitter || _utils.ident)(sagaEmitter.emit);
var sagaDispatch = (0, _utils.wrapSagaDispatch)(dispatch);

@@ -67,0 +72,0 @@

{
"name": "redux-saga",
"version": "0.14.1",
"version": "0.14.2",
"description": "Saga middleware for Redux to handle Side Effects",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

# redux-saga
[![Join the chat at https://gitter.im/yelouafi/redux-saga](https://badges.gitter.im/yelouafi/redux-saga.svg)](https://gitter.im/yelouafi/redux-saga?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![npm version](https://img.shields.io/npm/v/redux-saga.svg?style=flat-square)](https://www.npmjs.com/package/redux-saga) [![CDNJS](https://img.shields.io/cdnjs/v/redux-saga.svg?style=flat-square)](https://cdnjs.com/libraries/redux-saga)
[![Join the chat at https://gitter.im/yelouafi/redux-saga](https://badges.gitter.im/yelouafi/redux-saga.svg)](https://gitter.im/yelouafi/redux-saga?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![npm version](https://img.shields.io/npm/v/redux-saga.svg?style=flat-square)](https://www.npmjs.com/package/redux-saga) [![CDNJS]
(https://img.shields.io/cdnjs/v/redux-saga.svg?style=flat-square)](https://cdnjs.com/libraries/redux-saga)
[![OpenCollective](https://opencollective.com/redux-saga/backers/badge.svg)](#backers)
[![OpenCollective](https://opencollective.com/redux-saga/sponsors/badge.svg)](#sponsors)

@@ -124,2 +127,3 @@ `redux-saga` is a library that aims to make side effects (i.e. asynchronous things like data fetching and impure things like accessing the browser cache) in React/Redux applications easier and better.

- [Japanese](https://github.com/redux-saga/redux-saga/blob/master/README_ja.md)
- [Korean](https://github.com/redux-saga/redux-saga/blob/master/README_ko.md)

@@ -212,1 +216,71 @@ # Using umd build in the browser

```
### Backers
Support us with a monthly donation and help us continue our activities. [[Become a backer](https://opencollective.com/redux-saga#backer)]
<a href="https://opencollective.com/redux-saga/backer/0/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/0/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/1/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/1/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/2/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/2/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/3/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/3/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/4/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/4/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/5/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/5/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/6/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/6/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/7/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/7/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/8/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/8/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/9/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/9/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/10/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/10/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/11/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/11/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/12/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/12/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/13/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/13/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/14/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/14/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/15/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/15/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/16/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/16/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/17/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/17/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/18/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/18/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/19/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/19/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/20/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/20/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/21/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/21/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/22/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/22/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/23/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/23/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/24/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/24/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/25/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/25/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/26/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/26/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/27/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/27/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/28/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/28/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/backer/29/website" target="_blank"><img src="https://opencollective.com/redux-saga/backer/29/avatar.svg"></a>
### Sponsors
Become a sponsor and get your logo on our README on Github with a link to your site. [[Become a sponsor](https://opencollective.com/redux-saga#sponsor)]
<a href="https://opencollective.com/redux-saga/sponsor/0/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/0/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/1/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/1/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/2/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/2/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/3/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/3/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/4/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/4/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/5/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/5/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/6/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/6/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/7/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/7/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/8/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/8/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/9/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/9/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/10/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/10/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/11/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/11/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/12/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/12/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/13/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/13/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/14/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/14/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/15/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/15/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/16/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/16/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/17/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/17/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/18/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/18/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/19/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/19/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/20/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/20/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/21/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/21/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/22/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/22/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/23/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/23/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/24/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/24/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/25/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/25/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/26/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/26/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/27/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/27/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/28/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/28/avatar.svg"></a>
<a href="https://opencollective.com/redux-saga/sponsor/29/website" target="_blank"><img src="https://opencollective.com/redux-saga/sponsor/29/avatar.svg"></a>
import { noop, is, check, uid as nextSagaId, wrapSagaDispatch, isDev, log } from './utils'
import proc from './proc'
import {emitter} from './channel'
import { emitter } from './channel'
import { ident } from './utils'
export default function sagaMiddlewareFactory(options = {}) {

@@ -52,5 +52,10 @@ let runSagaDynamically

if(options.emitter && !is.func(options.emitter)) {
throw new Error('`options.emitter` passed to the Saga middleware is not a function!')
}
function sagaMiddleware({getState, dispatch}) {
runSagaDynamically = runSaga
const sagaEmitter = emitter()
sagaEmitter.emit = (options.emitter || ident)(sagaEmitter.emit)
const sagaDispatch = wrapSagaDispatch(dispatch)

@@ -57,0 +62,0 @@

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

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