jcc-call-utils
Version:
Toolkit of crossing chain from Call chain to SWTC chain
15 lines • 580 kB
JavaScript
var call=function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=91)}([function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(92);t.constants=n;var i=r(37);t.errors=i;var o=r(95);t.validate=o;var s=r(236);t.serverInfo=s;var a=r(46);t.dropsToCall=a.dropsToCall,t.callToDrops=a.callToDrops,t.toCalledAmount=a.toCalledAmount,t.removeUndefined=a.removeUndefined,t.convertKeysFromSnakeCaseToCamelCase=a.convertKeysFromSnakeCaseToCamelCase,t.iso8601ToCallTime=a.iso8601ToCallTime,t.callTimeToISO8601=a.callTimeToISO8601;var c=r(237);t.Connection=c.default;var u=r(57);t.txFlags=u.txFlags},function(e,t){e.exports=_},function(e,t,r){"use strict";(function(t){
/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
* @license MIT
*/
function n(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,i=0,o=Math.min(r,n);i<o;++i)if(e[i]!==t[i]){r=e[i],n=t[i];break}return r<n?-1:n<r?1:0}function i(e){return t.Buffer&&"function"==typeof t.Buffer.isBuffer?t.Buffer.isBuffer(e):!(null==e||!e._isBuffer)}var o=r(24),s=Object.prototype.hasOwnProperty,a=Array.prototype.slice,c="foo"===function(){}.name;function u(e){return Object.prototype.toString.call(e)}function f(e){return!i(e)&&("function"==typeof t.ArrayBuffer&&("function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(e):!!e&&(e instanceof DataView||!!(e.buffer&&e.buffer instanceof ArrayBuffer))))}var d=e.exports=y,h=/\s*function\s+([^\(\s]*)\s*/;function l(e){if(o.isFunction(e)){if(c)return e.name;var t=e.toString().match(h);return t&&t[1]}}function p(e,t){return"string"==typeof e?e.length<t?e:e.slice(0,t):e}function m(e){if(c||!o.isFunction(e))return o.inspect(e);var t=l(e);return"[Function"+(t?": "+t:"")+"]"}function g(e,t,r,n,i){throw new d.AssertionError({message:r,actual:e,expected:t,operator:n,stackStartFunction:i})}function y(e,t){e||g(e,!0,t,"==",d.ok)}function b(e,t,r,s){if(e===t)return!0;if(i(e)&&i(t))return 0===n(e,t);if(o.isDate(e)&&o.isDate(t))return e.getTime()===t.getTime();if(o.isRegExp(e)&&o.isRegExp(t))return e.source===t.source&&e.global===t.global&&e.multiline===t.multiline&&e.lastIndex===t.lastIndex&&e.ignoreCase===t.ignoreCase;if(null!==e&&"object"==typeof e||null!==t&&"object"==typeof t){if(f(e)&&f(t)&&u(e)===u(t)&&!(e instanceof Float32Array||e instanceof Float64Array))return 0===n(new Uint8Array(e.buffer),new Uint8Array(t.buffer));if(i(e)!==i(t))return!1;var c=(s=s||{actual:[],expected:[]}).actual.indexOf(e);return-1!==c&&c===s.expected.indexOf(t)||(s.actual.push(e),s.expected.push(t),function(e,t,r,n){if(null===e||void 0===e||null===t||void 0===t)return!1;if(o.isPrimitive(e)||o.isPrimitive(t))return e===t;if(r&&Object.getPrototypeOf(e)!==Object.getPrototypeOf(t))return!1;var i=v(e),s=v(t);if(i&&!s||!i&&s)return!1;if(i)return e=a.call(e),t=a.call(t),b(e,t,r);var c,u,f=A(e),d=A(t);if(f.length!==d.length)return!1;for(f.sort(),d.sort(),u=f.length-1;u>=0;u--)if(f[u]!==d[u])return!1;for(u=f.length-1;u>=0;u--)if(c=f[u],!b(e[c],t[c],r,n))return!1;return!0}(e,t,r,s))}return r?e===t:e==t}function v(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function w(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(e){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function S(e,t,r,n){var i;if("function"!=typeof t)throw new TypeError('"block" argument must be a function');"string"==typeof r&&(n=r,r=null),i=function(e){var t;try{e()}catch(e){t=e}return t}(t),n=(r&&r.name?" ("+r.name+").":".")+(n?" "+n:"."),e&&!i&&g(i,r,"Missing expected exception"+n);var s="string"==typeof n,a=!e&&o.isError(i),c=!e&&i&&!r;if((a&&s&&w(i,r)||c)&&g(i,r,"Got unwanted exception"+n),e&&i&&r&&!w(i,r)||!e&&i)throw i}d.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=function(e){return p(m(e.actual),128)+" "+e.operator+" "+p(m(e.expected),128)}(this),this.generatedMessage=!0);var t=e.stackStartFunction||g;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var r=new Error;if(r.stack){var n=r.stack,i=l(t),o=n.indexOf("\n"+i);if(o>=0){var s=n.indexOf("\n",o+1);n=n.substring(s+1)}this.stack=n}}},o.inherits(d.AssertionError,Error),d.fail=g,d.ok=y,d.equal=function(e,t,r){e!=t&&g(e,t,r,"==",d.equal)},d.notEqual=function(e,t,r){e==t&&g(e,t,r,"!=",d.notEqual)},d.deepEqual=function(e,t,r){b(e,t,!1)||g(e,t,r,"deepEqual",d.deepEqual)},d.deepStrictEqual=function(e,t,r){b(e,t,!0)||g(e,t,r,"deepStrictEqual",d.deepStrictEqual)},d.notDeepEqual=function(e,t,r){b(e,t,!1)&&g(e,t,r,"notDeepEqual",d.notDeepEqual)},d.notDeepStrictEqual=function e(t,r,n){b(t,r,!0)&&g(t,r,n,"notDeepStrictEqual",e)},d.strictEqual=function(e,t,r){e!==t&&g(e,t,r,"===",d.strictEqual)},d.notStrictEqual=function(e,t,r){e===t&&g(e,t,r,"!==",d.notStrictEqual)},d.throws=function(e,t,r){S(!0,e,t,r)},d.doesNotThrow=function(e,t,r){S(!1,e,t,r)},d.ifError=function(e){if(e)throw e};var A=Object.keys||function(e){var t=[];for(var r in e)s.call(e,r)&&t.push(r);return t}}).call(t,r(10))},function(e,t){"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}},function(e,t,r){"use strict";var _=r(1),n=r(3);function i(e,t){Object.keys(e||{}).forEach(function(r){t(e[r],r)})}e.exports=function(e,t){var r=t||e,o="function"==typeof e?e:null;if(null===o)for(var s in r)if(s[0].match(/[A-Z]/)){o=r[s];break}var a=r.inherits;a&&(null===o&&(o=function(){a.apply(this,arguments)}),n(o,a),_.defaults(o,a)),null===o&&(o=function(){});var c=o.prototype;function u(e,t,r){c[t]=r||e}return(r.getters||[]).forEach(function(e){var t="_"+e;c[e]=function(){return this[t]}}),i(r.virtuals,function(e,t){u(e,t,function(){throw new Error("unimplemented")})}),i(r.methods,u),i(r,function(e,t){_.isFunction(e)&&e!==o&&u(e,t)}),_.assign(o,r.statics),"function"==typeof o.init&&o.init(),i(r.cached,function(e,t){var r="_"+t;u(e,t,function(){var t=this[r];return void 0===t&&(t=this[r]=e.call(this)),t})}),r.mixins&&function(){var e={};(function(e){return Array.isArray(e)?e:[e]})(r.mixins).reverse().forEach(function(t){_.defaults(e,t)}),_.defaults(c,e)}(),o}},function(e,t,r){var n;/*! bignumber.js v4.1.0 https://github.com/MikeMcl/bignumber.js/LICENCE */!function(i){"use strict";var o,s=/^-?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,a=Math.ceil,c=Math.floor,u=" not a boolean or binary digit",f="rounding mode",d="number type has more than 15 significant digits",h="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_",l=1e14,p=14,m=9007199254740991,g=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],y=1e7,b=1e9;function v(e){var t=0|e;return e>0||e===t?t:t-1}function w(e){for(var t,r,n=1,i=e.length,o=e[0]+"";n<i;){for(t=e[n++]+"",r=p-t.length;r--;t="0"+t);o+=t}for(i=o.length;48===o.charCodeAt(--i););return o.slice(0,i+1||1)}function S(e,t){var r,n,i=e.c,o=t.c,s=e.s,a=t.s,c=e.e,u=t.e;if(!s||!a)return null;if(r=i&&!i[0],n=o&&!o[0],r||n)return r?n?0:-a:s;if(s!=a)return s;if(r=s<0,n=c==u,!i||!o)return n?0:!i^r?1:-1;if(!n)return c>u^r?1:-1;for(a=(c=i.length)<(u=o.length)?c:u,s=0;s<a;s++)if(i[s]!=o[s])return i[s]>o[s]^r?1:-1;return c==u?0:c>u^r?1:-1}function A(e,t,r){return(e=C(e))>=t&&e<=r}function x(e){return"[object Array]"==Object.prototype.toString.call(e)}function E(e,t,r){for(var n,i,o=[0],s=0,a=e.length;s<a;){for(i=o.length;i--;o[i]*=t);for(o[n=0]+=h.indexOf(e.charAt(s++));n<o.length;n++)o[n]>r-1&&(null==o[n+1]&&(o[n+1]=0),o[n+1]+=o[n]/r|0,o[n]%=r)}return o.reverse()}function T(e,t){return(e.length>1?e.charAt(0)+"."+e.slice(1):e)+(t<0?"e":"e+")+t}function M(e,t){var r,n;if(t<0){for(n="0.";++t;n+="0");e=n+e}else if(++t>(r=e.length)){for(n="0",t-=r;--t;n+="0");e+=n}else t<r&&(e=e.slice(0,t)+"."+e.slice(t));return e}function C(e){return(e=parseFloat(e))<0?a(e):c(e)}(o=function e(t){var r,n,i=0,o=z.prototype,P=new z(1),L=20,I=4,O=-7,k=21,N=-1e7,F=1e7,R=!0,j=K,q=!1,B=1,D=0,U={decimalSeparator:".",groupSeparator:",",groupSize:3,secondaryGroupSize:0,fractionGroupSeparator:" ",fractionGroupSize:0};function z(e,t){var r,o,a,u,f,l,g=this;if(!(g instanceof z))return R&&Z(26,"constructor call without new",e),new z(e,t);if(null!=t&&j(t,2,64,i,"base")){if(l=e+"",10==(t|=0))return Y(g=new z(e instanceof z?e:l),L+g.e+1,I);if((u="number"==typeof e)&&0*e!=0||!new RegExp("^-?"+(r="["+h.slice(0,t)+"]+")+"(?:\\."+r+")?$",t<37?"i":"").test(l))return n(g,l,u,t);u?(g.s=1/e<0?(l=l.slice(1),-1):1,R&&l.replace(/^0\.0*|\./,"").length>15&&Z(i,d,e),u=!1):g.s=45===l.charCodeAt(0)?(l=l.slice(1),-1):1,l=V(l,10,t,g.s)}else{if(e instanceof z)return g.s=e.s,g.e=e.e,g.c=(e=e.c)?e.slice():e,void(i=0);if((u="number"==typeof e)&&0*e==0){if(g.s=1/e<0?(e=-e,-1):1,e===~~e){for(o=0,a=e;a>=10;a/=10,o++);return g.e=o,g.c=[e],void(i=0)}l=e+""}else{if(!s.test(l=e+""))return n(g,l,u);g.s=45===l.charCodeAt(0)?(l=l.slice(1),-1):1}}for((o=l.indexOf("."))>-1&&(l=l.replace(".","")),(a=l.search(/e/i))>0?(o<0&&(o=a),o+=+l.slice(a+1),l=l.substring(0,a)):o<0&&(o=l.length),a=0;48===l.charCodeAt(a);a++);for(f=l.length;48===l.charCodeAt(--f););if(l=l.slice(a,f+1))if(f=l.length,u&&R&&f>15&&(e>m||e!==c(e))&&Z(i,d,g.s*e),(o=o-a-1)>F)g.c=g.e=null;else if(o<N)g.c=[g.e=0];else{if(g.e=o,g.c=[],a=(o+1)%p,o<0&&(a+=p),a<f){for(a&&g.c.push(+l.slice(0,a)),f-=p;a<f;)g.c.push(+l.slice(a,a+=p));l=l.slice(a),a=p-l.length}else a-=f;for(;a--;l+="0");g.c.push(+l)}else g.c=[g.e=0];i=0}function V(e,t,n,i){var o,s,a,c,u,f,d,l=e.indexOf("."),p=L,m=I;for(n<37&&(e=e.toLowerCase()),l>=0&&(a=D,D=0,e=e.replace(".",""),u=(d=new z(n)).pow(e.length-l),D=a,d.c=E(M(w(u.c),u.e),10,t),d.e=d.c.length),s=a=(f=E(e,n,t)).length;0==f[--a];f.pop());if(!f[0])return"0";if(l<0?--s:(u.c=f,u.e=s,u.s=i,f=(u=r(u,d,p,m,t)).c,c=u.r,s=u.e),l=f[o=s+p+1],a=t/2,c=c||o<0||null!=f[o+1],c=m<4?(null!=l||c)&&(0==m||m==(u.s<0?3:2)):l>a||l==a&&(4==m||c||6==m&&1&f[o-1]||m==(u.s<0?8:7)),o<1||!f[0])e=c?M("1",-p):"0";else{if(f.length=o,c)for(--t;++f[--o]>t;)f[o]=0,o||(++s,f=[1].concat(f));for(a=f.length;!f[--a];);for(l=0,e="";l<=a;e+=h.charAt(f[l++]));e=M(e,s)}return e}function $(e,t,r,n){var i,o,s,a,c;if(r=null!=r&&j(r,0,8,n,f)?0|r:I,!e.c)return e.toString();if(i=e.c[0],s=e.e,null==t)c=w(e.c),c=19==n||24==n&&s<=O?T(c,s):M(c,s);else if(o=(e=Y(new z(e),t,r)).e,a=(c=w(e.c)).length,19==n||24==n&&(t<=o||o<=O)){for(;a<t;c+="0",a++);c=T(c,o)}else if(t-=s,c=M(c,o),o+1>a){if(--t>0)for(c+=".";t--;c+="0");}else if((t+=o-a)>0)for(o+1==a&&(c+=".");t--;c+="0");return e.s<0&&i?"-"+c:c}function H(e,t){var r,n,i=0;for(x(e[0])&&(e=e[0]),r=new z(e[0]);++i<e.length;){if(!(n=new z(e[i])).s){r=n;break}t.call(r,n)&&(r=n)}return r}function K(e,t,r,n,i){return(e<t||e>r||e!=C(e))&&Z(n,(i||"decimal places")+(e<t||e>r?" out of range":" not an integer"),e),!0}function J(e,t,r){for(var n=1,i=t.length;!t[--i];t.pop());for(i=t[0];i>=10;i/=10,n++);return(r=n+r*p-1)>F?e.c=e.e=null:r<N?e.c=[e.e=0]:(e.e=r,e.c=t),e}function Z(e,t,r){var n=new Error(["new BigNumber","cmp","config","div","divToInt","eq","gt","gte","lt","lte","minus","mod","plus","precision","random","round","shift","times","toDigits","toExponential","toFixed","toFormat","toFraction","pow","toPrecision","toString","BigNumber"][e]+"() "+t+": "+r);throw n.name="BigNumber Error",i=0,n}function Y(e,t,r,n){var i,o,s,u,f,d,h,m=e.c,y=g;if(m){e:{for(i=1,u=m[0];u>=10;u/=10,i++);if((o=t-i)<0)o+=p,s=t,h=(f=m[d=0])/y[i-s-1]%10|0;else if((d=a((o+1)/p))>=m.length){if(!n)break e;for(;m.length<=d;m.push(0));f=h=0,i=1,s=(o%=p)-p+1}else{for(f=u=m[d],i=1;u>=10;u/=10,i++);h=(s=(o%=p)-p+i)<0?0:f/y[i-s-1]%10|0}if(n=n||t<0||null!=m[d+1]||(s<0?f:f%y[i-s-1]),n=r<4?(h||n)&&(0==r||r==(e.s<0?3:2)):h>5||5==h&&(4==r||n||6==r&&(o>0?s>0?f/y[i-s]:0:m[d-1])%10&1||r==(e.s<0?8:7)),t<1||!m[0])return m.length=0,n?(t-=e.e+1,m[0]=y[(p-t%p)%p],e.e=-t||0):m[0]=e.e=0,e;if(0==o?(m.length=d,u=1,d--):(m.length=d+1,u=y[p-o],m[d]=s>0?c(f/y[i-s]%y[s])*u:0),n)for(;;){if(0==d){for(o=1,s=m[0];s>=10;s/=10,o++);for(s=m[0]+=u,u=1;s>=10;s/=10,u++);o!=u&&(e.e++,m[0]==l&&(m[0]=1));break}if(m[d]+=u,m[d]!=l)break;m[d--]=0,u=1}for(o=m.length;0===m[--o];m.pop());}e.e>F?e.c=e.e=null:e.e<N&&(e.c=[e.e=0])}return e}return z.another=e,z.ROUND_UP=0,z.ROUND_DOWN=1,z.ROUND_CEIL=2,z.ROUND_FLOOR=3,z.ROUND_HALF_UP=4,z.ROUND_HALF_DOWN=5,z.ROUND_HALF_EVEN=6,z.ROUND_HALF_CEIL=7,z.ROUND_HALF_FLOOR=8,z.EUCLID=9,z.config=z.set=function(){var e,t,r=0,n={},o=arguments,s=o[0],a=s&&"object"==typeof s?function(){if(s.hasOwnProperty(t))return null!=(e=s[t])}:function(){if(o.length>r)return null!=(e=o[r++])};return a(t="DECIMAL_PLACES")&&j(e,0,b,2,t)&&(L=0|e),n[t]=L,a(t="ROUNDING_MODE")&&j(e,0,8,2,t)&&(I=0|e),n[t]=I,a(t="EXPONENTIAL_AT")&&(x(e)?j(e[0],-b,0,2,t)&&j(e[1],0,b,2,t)&&(O=0|e[0],k=0|e[1]):j(e,-b,b,2,t)&&(O=-(k=0|(e<0?-e:e)))),n[t]=[O,k],a(t="RANGE")&&(x(e)?j(e[0],-b,-1,2,t)&&j(e[1],1,b,2,t)&&(N=0|e[0],F=0|e[1]):j(e,-b,b,2,t)&&(0|e?N=-(F=0|(e<0?-e:e)):R&&Z(2,t+" cannot be zero",e))),n[t]=[N,F],a(t="ERRORS")&&(e===!!e||1===e||0===e?(i=0,j=(R=!!e)?K:A):R&&Z(2,t+u,e)),n[t]=R,a(t="CRYPTO")&&(!0===e||!1===e||1===e||0===e?e?!(e="undefined"==typeof crypto)&&crypto&&(crypto.getRandomValues||crypto.randomBytes)?q=!0:R?Z(2,"crypto unavailable",e?void 0:crypto):q=!1:q=!1:R&&Z(2,t+u,e)),n[t]=q,a(t="MODULO_MODE")&&j(e,0,9,2,t)&&(B=0|e),n[t]=B,a(t="POW_PRECISION")&&j(e,0,b,2,t)&&(D=0|e),n[t]=D,a(t="FORMAT")&&("object"==typeof e?U=e:R&&Z(2,t+" not an object",e)),n[t]=U,n},z.max=function(){return H(arguments,o.lt)},z.min=function(){return H(arguments,o.gt)},z.random=function(){var e=9007199254740992*Math.random()&2097151?function(){return c(9007199254740992*Math.random())}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)};return function(t){var r,n,i,o,s,u=0,f=[],d=new z(P);if(t=null!=t&&j(t,0,b,14)?0|t:L,o=a(t/p),q)if(crypto.getRandomValues){for(r=crypto.getRandomValues(new Uint32Array(o*=2));u<o;)(s=131072*r[u]+(r[u+1]>>>11))>=9e15?(n=crypto.getRandomValues(new Uint32Array(2)),r[u]=n[0],r[u+1]=n[1]):(f.push(s%1e14),u+=2);u=o/2}else if(crypto.randomBytes){for(r=crypto.randomBytes(o*=7);u<o;)(s=281474976710656*(31&r[u])+1099511627776*r[u+1]+4294967296*r[u+2]+16777216*r[u+3]+(r[u+4]<<16)+(r[u+5]<<8)+r[u+6])>=9e15?crypto.randomBytes(7).copy(r,u):(f.push(s%1e14),u+=7);u=o/7}else q=!1,R&&Z(14,"crypto unavailable",crypto);if(!q)for(;u<o;)(s=e())<9e15&&(f[u++]=s%1e14);for(o=f[--u],t%=p,o&&t&&(s=g[p-t],f[u]=c(o/s)*s);0===f[u];f.pop(),u--);if(u<0)f=[i=0];else{for(i=-1;0===f[0];f.splice(0,1),i-=p);for(u=1,s=f[0];s>=10;s/=10,u++);u<p&&(i-=p-u)}return d.e=i,d.c=f,d}}(),r=function(){function e(e,t,r){var n,i,o,s,a=0,c=e.length,u=t%y,f=t/y|0;for(e=e.slice();c--;)a=((i=u*(o=e[c]%y)+(n=f*o+(s=e[c]/y|0)*u)%y*y+a)/r|0)+(n/y|0)+f*s,e[c]=i%r;return a&&(e=[a].concat(e)),e}function t(e,t,r,n){var i,o;if(r!=n)o=r>n?1:-1;else for(i=o=0;i<r;i++)if(e[i]!=t[i]){o=e[i]>t[i]?1:-1;break}return o}function r(e,t,r,n){for(var i=0;r--;)e[r]-=i,i=e[r]<t[r]?1:0,e[r]=i*n+e[r]-t[r];for(;!e[0]&&e.length>1;e.splice(0,1));}return function(n,i,o,s,a){var u,f,d,h,m,g,y,b,w,S,A,x,E,T,M,C,P,L=n.s==i.s?1:-1,I=n.c,O=i.c;if(!(I&&I[0]&&O&&O[0]))return new z(n.s&&i.s&&(I?!O||I[0]!=O[0]:O)?I&&0==I[0]||!O?0*L:L/0:NaN);for(w=(b=new z(L)).c=[],L=o+(f=n.e-i.e)+1,a||(a=l,f=v(n.e/p)-v(i.e/p),L=L/p|0),d=0;O[d]==(I[d]||0);d++);if(O[d]>(I[d]||0)&&f--,L<0)w.push(1),h=!0;else{for(T=I.length,C=O.length,d=0,L+=2,(m=c(a/(O[0]+1)))>1&&(O=e(O,m,a),I=e(I,m,a),C=O.length,T=I.length),E=C,A=(S=I.slice(0,C)).length;A<C;S[A++]=0);P=O.slice(),P=[0].concat(P),M=O[0],O[1]>=a/2&&M++;do{if(m=0,(u=t(O,S,C,A))<0){if(x=S[0],C!=A&&(x=x*a+(S[1]||0)),(m=c(x/M))>1)for(m>=a&&(m=a-1),y=(g=e(O,m,a)).length,A=S.length;1==t(g,S,y,A);)m--,r(g,C<y?P:O,y,a),y=g.length,u=1;else 0==m&&(u=m=1),y=(g=O.slice()).length;if(y<A&&(g=[0].concat(g)),r(S,g,A,a),A=S.length,-1==u)for(;t(O,S,C,A)<1;)m++,r(S,C<A?P:O,A,a),A=S.length}else 0===u&&(m++,S=[0]);w[d++]=m,S[0]?S[A++]=I[E]||0:(S=[I[E]],A=1)}while((E++<T||null!=S[0])&&L--);h=null!=S[0],w[0]||w.splice(0,1)}if(a==l){for(d=1,L=w[0];L>=10;L/=10,d++);Y(b,o+(b.e=d+f*p-1)+1,s,h)}else b.e=f,b.r=+h;return b}}(),n=function(){var e=/^(-?)0([xbo])(?=\w[\w.]*$)/i,t=/^([^.]+)\.$/,r=/^\.([^.]+)$/,n=/^-?(Infinity|NaN)$/,o=/^\s*\+(?=[\w.])|^\s+|\s+$/g;return function(s,a,c,u){var f,d=c?a:a.replace(o,"");if(n.test(d))s.s=isNaN(d)?null:d<0?-1:1;else{if(!c&&(d=d.replace(e,function(e,t,r){return f="x"==(r=r.toLowerCase())?16:"b"==r?2:8,u&&u!=f?e:t}),u&&(f=u,d=d.replace(t,"$1").replace(r,"0.$1")),a!=d))return new z(d,f);R&&Z(i,"not a"+(u?" base "+u:"")+" number",a),s.s=null}s.c=s.e=null,i=0}}(),o.absoluteValue=o.abs=function(){var e=new z(this);return e.s<0&&(e.s=1),e},o.ceil=function(){return Y(new z(this),this.e+1,2)},o.comparedTo=o.cmp=function(e,t){return i=1,S(this,new z(e,t))},o.decimalPlaces=o.dp=function(){var e,t,r=this.c;if(!r)return null;if(e=((t=r.length-1)-v(this.e/p))*p,t=r[t])for(;t%10==0;t/=10,e--);return e<0&&(e=0),e},o.dividedBy=o.div=function(e,t){return i=3,r(this,new z(e,t),L,I)},o.dividedToIntegerBy=o.divToInt=function(e,t){return i=4,r(this,new z(e,t),0,1)},o.equals=o.eq=function(e,t){return i=5,0===S(this,new z(e,t))},o.floor=function(){return Y(new z(this),this.e+1,3)},o.greaterThan=o.gt=function(e,t){return i=6,S(this,new z(e,t))>0},o.greaterThanOrEqualTo=o.gte=function(e,t){return i=7,1===(t=S(this,new z(e,t)))||0===t},o.isFinite=function(){return!!this.c},o.isInteger=o.isInt=function(){return!!this.c&&v(this.e/p)>this.c.length-2},o.isNaN=function(){return!this.s},o.isNegative=o.isNeg=function(){return this.s<0},o.isZero=function(){return!!this.c&&0==this.c[0]},o.lessThan=o.lt=function(e,t){return i=8,S(this,new z(e,t))<0},o.lessThanOrEqualTo=o.lte=function(e,t){return i=9,-1===(t=S(this,new z(e,t)))||0===t},o.minus=o.sub=function(e,t){var r,n,o,s,a=this,c=a.s;if(i=10,t=(e=new z(e,t)).s,!c||!t)return new z(NaN);if(c!=t)return e.s=-t,a.plus(e);var u=a.e/p,f=e.e/p,d=a.c,h=e.c;if(!u||!f){if(!d||!h)return d?(e.s=-t,e):new z(h?a:NaN);if(!d[0]||!h[0])return h[0]?(e.s=-t,e):new z(d[0]?a:3==I?-0:0)}if(u=v(u),f=v(f),d=d.slice(),c=u-f){for((s=c<0)?(c=-c,o=d):(f=u,o=h),o.reverse(),t=c;t--;o.push(0));o.reverse()}else for(n=(s=(c=d.length)<(t=h.length))?c:t,c=t=0;t<n;t++)if(d[t]!=h[t]){s=d[t]<h[t];break}if(s&&(o=d,d=h,h=o,e.s=-e.s),(t=(n=h.length)-(r=d.length))>0)for(;t--;d[r++]=0);for(t=l-1;n>c;){if(d[--n]<h[n]){for(r=n;r&&!d[--r];d[r]=t);--d[r],d[n]+=l}d[n]-=h[n]}for(;0==d[0];d.splice(0,1),--f);return d[0]?J(e,d,f):(e.s=3==I?-1:1,e.c=[e.e=0],e)},o.modulo=o.mod=function(e,t){var n,o,s=this;return i=11,e=new z(e,t),!s.c||!e.s||e.c&&!e.c[0]?new z(NaN):!e.c||s.c&&!s.c[0]?new z(s):(9==B?(o=e.s,e.s=1,n=r(s,e,0,3),e.s=o,n.s*=o):n=r(s,e,0,B),s.minus(n.times(e)))},o.negated=o.neg=function(){var e=new z(this);return e.s=-e.s||null,e},o.plus=o.add=function(e,t){var r,n=this,o=n.s;if(i=12,t=(e=new z(e,t)).s,!o||!t)return new z(NaN);if(o!=t)return e.s=-t,n.minus(e);var s=n.e/p,a=e.e/p,c=n.c,u=e.c;if(!s||!a){if(!c||!u)return new z(o/0);if(!c[0]||!u[0])return u[0]?e:new z(c[0]?n:0*o)}if(s=v(s),a=v(a),c=c.slice(),o=s-a){for(o>0?(a=s,r=u):(o=-o,r=c),r.reverse();o--;r.push(0));r.reverse()}for((o=c.length)-(t=u.length)<0&&(r=u,u=c,c=r,t=o),o=0;t;)o=(c[--t]=c[t]+u[t]+o)/l|0,c[t]=l===c[t]?0:c[t]%l;return o&&(c=[o].concat(c),++a),J(e,c,a)},o.precision=o.sd=function(e){var t,r,n=this,i=n.c;if(null!=e&&e!==!!e&&1!==e&&0!==e&&(R&&Z(13,"argument"+u,e),e!=!!e&&(e=null)),!i)return null;if(t=(r=i.length-1)*p+1,r=i[r]){for(;r%10==0;r/=10,t--);for(r=i[0];r>=10;r/=10,t++);}return e&&n.e+1>t&&(t=n.e+1),t},o.round=function(e,t){var r=new z(this);return(null==e||j(e,0,b,15))&&Y(r,~~e+this.e+1,null!=t&&j(t,0,8,15,f)?0|t:I),r},o.shift=function(e){var t=this;return j(e,-m,m,16,"argument")?t.times("1e"+C(e)):new z(t.c&&t.c[0]&&(e<-m||e>m)?t.s*(e<0?0:1/0):t)},o.squareRoot=o.sqrt=function(){var e,t,n,i,o,s=this,a=s.c,c=s.s,u=s.e,f=L+4,d=new z("0.5");if(1!==c||!a||!a[0])return new z(!c||c<0&&(!a||a[0])?NaN:a?s:1/0);if(0==(c=Math.sqrt(+s))||c==1/0?(((t=w(a)).length+u)%2==0&&(t+="0"),c=Math.sqrt(t),u=v((u+1)/2)-(u<0||u%2),n=new z(t=c==1/0?"1e"+u:(t=c.toExponential()).slice(0,t.indexOf("e")+1)+u)):n=new z(c+""),n.c[0])for((c=(u=n.e)+f)<3&&(c=0);;)if(o=n,n=d.times(o.plus(r(s,o,f,1))),w(o.c).slice(0,c)===(t=w(n.c)).slice(0,c)){if(n.e<u&&--c,"9999"!=(t=t.slice(c-3,c+1))&&(i||"4999"!=t)){+t&&(+t.slice(1)||"5"!=t.charAt(0))||(Y(n,n.e+L+2,1),e=!n.times(n).eq(s));break}if(!i&&(Y(o,o.e+L+2,0),o.times(o).eq(s))){n=o;break}f+=4,c+=4,i=1}return Y(n,n.e+L+1,I,e)},o.times=o.mul=function(e,t){var r,n,o,s,a,c,u,f,d,h,m,g,b,w,S,A=this,x=A.c,E=(i=17,e=new z(e,t)).c;if(!(x&&E&&x[0]&&E[0]))return!A.s||!e.s||x&&!x[0]&&!E||E&&!E[0]&&!x?e.c=e.e=e.s=null:(e.s*=A.s,x&&E?(e.c=[0],e.e=0):e.c=e.e=null),e;for(n=v(A.e/p)+v(e.e/p),e.s*=A.s,(u=x.length)<(h=E.length)&&(b=x,x=E,E=b,o=u,u=h,h=o),o=u+h,b=[];o--;b.push(0));for(w=l,S=y,o=h;--o>=0;){for(r=0,m=E[o]%S,g=E[o]/S|0,s=o+(a=u);s>o;)r=((f=m*(f=x[--a]%S)+(c=g*f+(d=x[a]/S|0)*m)%S*S+b[s]+r)/w|0)+(c/S|0)+g*d,b[s--]=f%w;b[s]=r}return r?++n:b.splice(0,1),J(e,b,n)},o.toDigits=function(e,t){var r=new z(this);return e=null!=e&&j(e,1,b,18,"precision")?0|e:null,t=null!=t&&j(t,0,8,18,f)?0|t:I,e?Y(r,e,t):r},o.toExponential=function(e,t){return $(this,null!=e&&j(e,0,b,19)?1+~~e:null,t,19)},o.toFixed=function(e,t){return $(this,null!=e&&j(e,0,b,20)?~~e+this.e+1:null,t,20)},o.toFormat=function(e,t){var r=$(this,null!=e&&j(e,0,b,21)?~~e+this.e+1:null,t,21);if(this.c){var n,i=r.split("."),o=+U.groupSize,s=+U.secondaryGroupSize,a=U.groupSeparator,c=i[0],u=i[1],f=this.s<0,d=f?c.slice(1):c,h=d.length;if(s&&(n=o,o=s,s=n,h-=n),o>0&&h>0){for(n=h%o||o,c=d.substr(0,n);n<h;n+=o)c+=a+d.substr(n,o);s>0&&(c+=a+d.slice(n)),f&&(c="-"+c)}r=u?c+U.decimalSeparator+((s=+U.fractionGroupSize)?u.replace(new RegExp("\\d{"+s+"}\\B","g"),"$&"+U.fractionGroupSeparator):u):c}return r},o.toFraction=function(e){var t,n,i,o,s,a,c,u,f,d=R,h=this,l=h.c,m=new z(P),y=n=new z(P),b=c=new z(P);if(null!=e&&(R=!1,a=new z(e),R=d,(d=a.isInt())&&!a.lt(P)||(R&&Z(22,"max denominator "+(d?"out of range":"not an integer"),e),e=!d&&a.c&&Y(a,a.e+1,1).gte(P)?a:null)),!l)return h.toString();for(f=w(l),o=m.e=f.length-h.e-1,m.c[0]=g[(s=o%p)<0?p+s:s],e=!e||a.cmp(m)>0?o>0?m:y:a,s=F,F=1/0,a=new z(f),c.c[0]=0;u=r(a,m,0,1),1!=(i=n.plus(u.times(b))).cmp(e);)n=b,b=i,y=c.plus(u.times(i=y)),c=i,m=a.minus(u.times(i=m)),a=i;return i=r(e.minus(n),b,0,1),c=c.plus(i.times(y)),n=n.plus(i.times(b)),c.s=y.s=h.s,t=r(y,b,o*=2,I).minus(h).abs().cmp(r(c,n,o,I).minus(h).abs())<1?[y.toString(),b.toString()]:[c.toString(),n.toString()],F=s,t},o.toNumber=function(){return+this},o.toPower=o.pow=function(e,t){var r,n,o,s=c(e<0?-e:+e),u=this;if(null!=t&&(i=23,t=new z(t)),!j(e,-m,m,23,"exponent")&&(!isFinite(e)||s>m&&(e/=0)||parseFloat(e)!=e&&!(e=NaN))||0==e)return r=Math.pow(+u,e),new z(t?r%t:r);for(t?e>1&&u.gt(P)&&u.isInt()&&t.gt(P)&&t.isInt()?u=u.mod(t):(o=t,t=null):D&&(r=a(D/p+2)),n=new z(P);;){if(s%2){if(!(n=n.times(u)).c)break;r?n.c.length>r&&(n.c.length=r):t&&(n=n.mod(t))}if(!(s=c(s/2)))break;u=u.times(u),r?u.c&&u.c.length>r&&(u.c.length=r):t&&(u=u.mod(t))}return t?n:(e<0&&(n=P.div(n)),o?n.mod(o):r?Y(n,D,I):n)},o.toPrecision=function(e,t){return $(this,null!=e&&j(e,1,b,24,"precision")?0|e:null,t,24)},o.toString=function(e){var t,r=this,n=r.s,i=r.e;return null===i?n?(t="Infinity",n<0&&(t="-"+t)):t="NaN":(t=w(r.c),t=null!=e&&j(e,2,64,25,"base")?V(M(t,i),0|e,10,n):i<=O||i>=k?T(t,i):M(t,i),n<0&&r.c[0]&&(t="-"+t)),t},o.truncated=o.trunc=function(){return Y(new z(this),this.e+1,1)},o.valueOf=o.toJSON=function(){var e,t=this,r=t.e;return null===r?t.toString():(e=w(t.c),e=r<=O||r>=k?T(e,r):M(e,r),t.s<0?"-"+e:e)},o.isBigNumber=!0,null!=t&&z.config(t),z}()).default=o.BigNumber=o,void 0===(n=function(){return o}.call(t,r,t,e))||(e.exports=n)}()},function(e,t,r){"use strict";(function(e){
/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
* @license MIT
*/
var n=r(238),i=r(239),o=r(64);function s(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function a(e,t){if(s()<t)throw new RangeError("Invalid typed array length");return c.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=c.prototype:(null===e&&(e=new c(t)),e.length=t),e}function c(e,t,r){if(!(c.TYPED_ARRAY_SUPPORT||this instanceof c))return new c(e,t,r);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return d(this,e)}return u(this,e,t,r)}function u(e,t,r,n){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,r,n){if(t.byteLength,r<0||t.byteLength<r)throw new RangeError("'offset' is out of bounds");if(t.byteLength<r+(n||0))throw new RangeError("'length' is out of bounds");t=void 0===r&&void 0===n?new Uint8Array(t):void 0===n?new Uint8Array(t,r):new Uint8Array(t,r,n);c.TYPED_ARRAY_SUPPORT?(e=t).__proto__=c.prototype:e=h(e,t);return e}(e,t,r,n):"string"==typeof t?function(e,t,r){"string"==typeof r&&""!==r||(r="utf8");if(!c.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var n=0|p(t,r),i=(e=a(e,n)).write(t,r);i!==n&&(e=e.slice(0,i));return e}(e,t,r):function(e,t){if(c.isBuffer(t)){var r=0|l(t.length);return 0===(e=a(e,r)).length?e:(t.copy(e,0,0,r),e)}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||function(e){return e!=e}(t.length)?a(e,0):h(e,t);if("Buffer"===t.type&&o(t.data))return h(e,t.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function f(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function d(e,t){if(f(t),e=a(e,t<0?0:0|l(t)),!c.TYPED_ARRAY_SUPPORT)for(var r=0;r<t;++r)e[r]=0;return e}function h(e,t){var r=t.length<0?0:0|l(t.length);e=a(e,r);for(var n=0;n<r;n+=1)e[n]=255&t[n];return e}function l(e){if(e>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function p(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var r=e.length;if(0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return U(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return z(e).length;default:if(n)return U(e).length;t=(""+t).toLowerCase(),n=!0}}function m(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function g(e,t,r,n,i){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=i?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(i)return-1;r=e.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof t&&(t=c.from(t,n)),c.isBuffer(t))return 0===t.length?-1:y(e,t,r,n,i);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):y(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function y(e,t,r,n,i){var o,s=1,a=e.length,c=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;s=2,a/=2,c/=2,r/=2}function u(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(i){var f=-1;for(o=r;o<a;o++)if(u(e,o)===u(t,-1===f?0:o-f)){if(-1===f&&(f=o),o-f+1===c)return f*s}else-1!==f&&(o-=o-f),f=-1}else for(r+c>a&&(r=a-c),o=r;o>=0;o--){for(var d=!0,h=0;h<c;h++)if(u(e,o+h)!==u(t,h)){d=!1;break}if(d)return o}return-1}function b(e,t,r,n){r=Number(r)||0;var i=e.length-r;n?(n=Number(n))>i&&(n=i):n=i;var o=t.length;if(o%2!=0)throw new TypeError("Invalid hex string");n>o/2&&(n=o/2);for(var s=0;s<n;++s){var a=parseInt(t.substr(2*s,2),16);if(isNaN(a))return s;e[r+s]=a}return s}function v(e,t,r,n){return V(U(t,e.length-r),e,r,n)}function w(e,t,r,n){return V(function(e){for(var t=[],r=0;r<e.length;++r)t.push(255&e.charCodeAt(r));return t}(t),e,r,n)}function S(e,t,r,n){return w(e,t,r,n)}function A(e,t,r,n){return V(z(t),e,r,n)}function x(e,t,r,n){return V(function(e,t){for(var r,n,i,o=[],s=0;s<e.length&&!((t-=2)<0);++s)r=e.charCodeAt(s),n=r>>8,i=r%256,o.push(i),o.push(n);return o}(t,e.length-r),e,r,n)}function E(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function T(e,t,r){r=Math.min(e.length,r);for(var n=[],i=t;i<r;){var o,s,a,c,u=e[i],f=null,d=u>239?4:u>223?3:u>191?2:1;if(i+d<=r)switch(d){case 1:u<128&&(f=u);break;case 2:128==(192&(o=e[i+1]))&&(c=(31&u)<<6|63&o)>127&&(f=c);break;case 3:o=e[i+1],s=e[i+2],128==(192&o)&&128==(192&s)&&(c=(15&u)<<12|(63&o)<<6|63&s)>2047&&(c<55296||c>57343)&&(f=c);break;case 4:o=e[i+1],s=e[i+2],a=e[i+3],128==(192&o)&&128==(192&s)&&128==(192&a)&&(c=(15&u)<<18|(63&o)<<12|(63&s)<<6|63&a)>65535&&c<1114112&&(f=c)}null===f?(f=65533,d=1):f>65535&&(f-=65536,n.push(f>>>10&1023|55296),f=56320|1023&f),n.push(f),i+=d}return function(e){var t=e.length;if(t<=M)return String.fromCharCode.apply(String,e);var r="",n=0;for(;n<t;)r+=String.fromCharCode.apply(String,e.slice(n,n+=M));return r}(n)}t.Buffer=c,t.SlowBuffer=function(e){+e!=e&&(e=0);return c.alloc(+e)},t.INSPECT_MAX_BYTES=50,c.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),t.kMaxLength=s(),c.poolSize=8192,c._augment=function(e){return e.__proto__=c.prototype,e},c.from=function(e,t,r){return u(null,e,t,r)},c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&c[Symbol.species]===c&&Object.defineProperty(c,Symbol.species,{value:null,configurable:!0})),c.alloc=function(e,t,r){return function(e,t,r,n){return f(t),t<=0?a(e,t):void 0!==r?"string"==typeof n?a(e,t).fill(r,n):a(e,t).fill(r):a(e,t)}(null,e,t,r)},c.allocUnsafe=function(e){return d(null,e)},c.allocUnsafeSlow=function(e){return d(null,e)},c.isBuffer=function(e){return!(null==e||!e._isBuffer)},c.compare=function(e,t){if(!c.isBuffer(e)||!c.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var r=e.length,n=t.length,i=0,o=Math.min(r,n);i<o;++i)if(e[i]!==t[i]){r=e[i],n=t[i];break}return r<n?-1:n<r?1:0},c.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},c.concat=function(e,t){if(!o(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return c.alloc(0);var r;if(void 0===t)for(t=0,r=0;r<e.length;++r)t+=e[r].length;var n=c.allocUnsafe(t),i=0;for(r=0;r<e.length;++r){var s=e[r];if(!c.isBuffer(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(n,i),i+=s.length}return n},c.byteLength=p,c.prototype._isBuffer=!0,c.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)m(this,t,t+1);return this},c.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)m(this,t,t+3),m(this,t+1,t+2);return this},c.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)m(this,t,t+7),m(this,t+1,t+6),m(this,t+2,t+5),m(this,t+3,t+4);return this},c.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?T(this,0,e):function(e,t,r){var n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return L(this,t,r);case"utf8":case"utf-8":return T(this,t,r);case"ascii":return C(this,t,r);case"latin1":case"binary":return P(this,t,r);case"base64":return E(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}.apply(this,arguments)},c.prototype.equals=function(e){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===c.compare(this,e)},c.prototype.inspect=function(){var e="",r=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(e+=" ... ")),"<Buffer "+e+">"},c.prototype.compare=function(e,t,r,n,i){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),t<0||r>e.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&t>=r)return 0;if(n>=i)return-1;if(t>=r)return 1;if(t>>>=0,r>>>=0,n>>>=0,i>>>=0,this===e)return 0;for(var o=i-n,s=r-t,a=Math.min(o,s),u=this.slice(n,i),f=e.slice(t,r),d=0;d<a;++d)if(u[d]!==f[d]){o=u[d],s=f[d];break}return o<s?-1:s<o?1:0},c.prototype.includes=function(e,t,r){return-1!==this.indexOf(e,t,r)},c.prototype.indexOf=function(e,t,r){return g(this,e,t,r,!0)},c.prototype.lastIndexOf=function(e,t,r){return g(this,e,t,r,!1)},c.prototype.write=function(e,t,r,n){if(void 0===t)n="utf8",r=this.length,t=0;else if(void 0===r&&"string"==typeof t)n=t,r=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(r)?(r|=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var i=this.length-t;if((void 0===r||r>i)&&(r=i),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o=!1;;)switch(n){case"hex":return b(this,e,t,r);case"utf8":case"utf-8":return v(this,e,t,r);case"ascii":return w(this,e,t,r);case"latin1":case"binary":return S(this,e,t,r);case"base64":return A(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return x(this,e,t,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var M=4096;function C(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;i<r;++i)n+=String.fromCharCode(127&e[i]);return n}function P(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;i<r;++i)n+=String.fromCharCode(e[i]);return n}function L(e,t,r){var n=e.length;(!t||t<0)&&(t=0),(!r||r<0||r>n)&&(r=n);for(var i="",o=t;o<r;++o)i+=D(e[o]);return i}function I(e,t,r){for(var n=e.slice(t,r),i="",o=0;o<n.length;o+=2)i+=String.fromCharCode(n[o]+256*n[o+1]);return i}function O(e,t,r){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>r)throw new RangeError("Trying to access beyond buffer length")}function k(e,t,r,n,i,o){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<o)throw new RangeError('"value" argument is out of bounds');if(r+n>e.length)throw new RangeError("Index out of range")}function N(e,t,r,n){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-r,2);i<o;++i)e[r+i]=(t&255<<8*(n?i:1-i))>>>8*(n?i:1-i)}function F(e,t,r,n){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-r,4);i<o;++i)e[r+i]=t>>>8*(n?i:3-i)&255}function R(e,t,r,n,i,o){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function j(e,t,r,n,o){return o||R(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function q(e,t,r,n,o){return o||R(e,0,r,8),i.write(e,t,r,n,52,8),r+8}c.prototype.slice=function(e,t){var r,n=this.length;if(e=~~e,t=void 0===t?n:~~t,e<0?(e+=n)<0&&(e=0):e>n&&(e=n),t<0?(t+=n)<0&&(t=0):t>n&&(t=n),t<e&&(t=e),c.TYPED_ARRAY_SUPPORT)(r=this.subarray(e,t)).__proto__=c.prototype;else{var i=t-e;r=new c(i,void 0);for(var o=0;o<i;++o)r[o]=this[o+e]}return r},c.prototype.readUIntLE=function(e,t,r){e|=0,t|=0,r||O(e,t,this.length);for(var n=this[e],i=1,o=0;++o<t&&(i*=256);)n+=this[e+o]*i;return n},c.prototype.readUIntBE=function(e,t,r){e|=0,t|=0,r||O(e,t,this.length);for(var n=this[e+--t],i=1;t>0&&(i*=256);)n+=this[e+--t]*i;return n},c.prototype.readUInt8=function(e,t){return t||O(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||O(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||O(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||O(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||O(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,r){e|=0,t|=0,r||O(e,t,this.length);for(var n=this[e],i=1,o=0;++o<t&&(i*=256);)n+=this[e+o]*i;return n>=(i*=128)&&(n-=Math.pow(2,8*t)),n},c.prototype.readIntBE=function(e,t,r){e|=0,t|=0,r||O(e,t,this.length);for(var n=t,i=1,o=this[e+--n];n>0&&(i*=256);)o+=this[e+--n]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},c.prototype.readInt8=function(e,t){return t||O(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||O(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt16BE=function(e,t){t||O(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt32LE=function(e,t){return t||O(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||O(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||O(e,4,this.length),i.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||O(e,4,this.length),i.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||O(e,8,this.length),i.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||O(e,8,this.length),i.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,r,n){(e=+e,t|=0,r|=0,n)||k(this,e,t,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[t]=255&e;++o<r&&(i*=256);)this[t+o]=e/i&255;return t+r},c.prototype.writeUIntBE=function(e,t,r,n){(e=+e,t|=0,r|=0,n)||k(this,e,t,r,Math.pow(2,8*r)-1,0);var i=r-1,o=1;for(this[t+i]=255&e;--i>=0&&(o*=256);)this[t+i]=e/o&255;return t+r},c.prototype.writeUInt8=function(e,t,r){return e=+e,t|=0,r||k(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,r){return e=+e,t|=0,r||k(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):N(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,r){return e=+e,t|=0,r||k(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):N(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,r){return e=+e,t|=0,r||k(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):F(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,r){return e=+e,t|=0,r||k(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):F(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);k(this,e,t,r,i-1,-i)}var o=0,s=1,a=0;for(this[t]=255&e;++o<r&&(s*=256);)e<0&&0===a&&0!==this[t+o-1]&&(a=1),this[t+o]=(e/s>>0)-a&255;return t+r},c.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);k(this,e,t,r,i-1,-i)}var o=r-1,s=1,a=0;for(this[t+o]=255&e;--o>=0&&(s*=256);)e<0&&0===a&&0!==this[t+o+1]&&(a=1),this[t+o]=(e/s>>0)-a&255;return t+r},c.prototype.writeInt8=function(e,t,r){return e=+e,t|=0,r||k(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,r){return e=+e,t|=0,r||k(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):N(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,r){return e=+e,t|=0,r||k(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):N(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,r){return e=+e,t|=0,r||k(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):F(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,r){return e=+e,t|=0,r||k(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):F(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,r){return j(this,e,t,!0,r)},c.prototype.writeFloatBE=function(e,t,r){return j(this,e,t,!1,r)},c.prototype.writeDoubleLE=function(e,t,r){return q(this,e,t,!0,r)},c.prototype.writeDoubleBE=function(e,t,r){return q(this,e,t,!1,r)},c.prototype.copy=function(e,t,r,n){if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n<r&&(n=r),n===r)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t<n-r&&(n=e.length-t+r);var i,o=n-r;if(this===e&&r<t&&t<n)for(i=o-1;i>=0;--i)e[i+t]=this[i+r];else if(o<1e3||!c.TYPED_ARRAY_SUPPORT)for(i=0;i<o;++i)e[i+t]=this[i+r];else Uint8Array.prototype.set.call(e,this.subarray(r,r+o),t);return o},c.prototype.fill=function(e,t,r,n){if("string"==typeof e){if("string"==typeof t?(n=t,t=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),1===e.length){var i=e.charCodeAt(0);i<256&&(e=i)}if(void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!c.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<r)throw new RangeError("Out of range index");if(r<=t)return this;var o;if(t>>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(o=t;o<r;++o)this[o]=e;else{var s=c.isBuffer(e)?e:U(new c(e,n).toString()),a=s.length;for(o=0;o<r-t;++o)this[o+t]=s[o%a]}return this};var B=/[^+\/0-9A-Za-z-_]/g;function D(e){return e<16?"0"+e.toString(16):e.toString(16)}function U(e,t){var r;t=t||1/0;for(var n=e.length,i=null,o=[],s=0;s<n;++s){if((r=e.charCodeAt(s))>55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(s+1===n){(t-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function z(e){return n.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(B,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function V(e,t,r,n){for(var i=0;i<n&&!(i+r>=t.length||i>=e.length);++i)t[i+r]=e[i];return i}}).call(t,r(10))},function(e,t,r){var n=r(6),i=n.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function s(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(o(n,t),t.Buffer=s),o(i,s),s.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},s.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},s.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},s.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},function(e,t,r){"use strict";var n=r(2);function i(e,t){return e<t?-1:e===t?0:1}var o=function(){for(var e={},t=e.reverse=new Array(256),r=0;r<16;r++){var n=r.toString(16).toUpperCase();e[n]=r;for(var i=0;i<16;i++){var o=(r<<4)+i,s=n+i.toString(16).toUpperCase();e[s]=o,t[o]=s}}return e}(),s=o.reverse;function a(e){var t=o[e];if(void 0===t)throw new Error("`"+e+"` is not a valid hex representation of a byte");return t}e.exports={parseBytes:function(e){var t=arguments.length<=1||void 0===arguments[1]?Array:arguments[1];if(!e||void 0===e.length)throw new Error(e+" is not a sequence");if("string"==typeof e){for(var r=e.length%2,n=new t((e.length+r)/2),i=e.length,o=n.length-1;o>=r;i-=2,o--)n[o]=a(e.slice(i-2,i));return 1===r&&(n[0]=a(e[0])),n}if(e instanceof t)return e;if(t===Uint8Array)return new t(e);for(var s=new t(e.length),c=e.length-1;c>=0;c--)s[c]=e[c];return s},bytesToHex:function(e){for(var t=Array(e.length),r=e.length-1;r>=0;r--)t[r]=s[e[r]];return t.join("")},slice:function(e){var t=arguments.length<=1||void 0===arguments[1]?0:arguments[1],r=arguments.length<=2||void 0===arguments[2]?e.length:arguments[2],n=arguments.length<=3||void 0===arguments[3]?e.constructor:arguments[3];t<0&&(t+=e.length),r<0&&(r+=e.length);for(var i=new n(r-t),o=r-1;o>=t;o--)i[o-t]=e[o];return i},compareBytes:function(e,t){n(e.length===t.length);for(var r=0;r<e.length;r++){var o=i(e[r],t[r]);if(0!==o)return o}return 0},serializeUIntN:function(e,t){for(var r=new Uint8Array(t),n=t-1,i=0;i<t;i++)r[n-i]=e>>>8*i&255;return r}}},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});var n=r(5),i=r(0);t.common=i;var o=i.txFlags;function s(e,t,r){return void 0===r&&(r=0),new n.default(e).times(t).plus(r).toString()}function a(t){return new e(t,"utf8").toString("hex").toUpperCase()}t.prepareTransaction=function(t,r,a){i.validate.instructions(a);var c=t.Account;function u(e){for(var t="",r=0;r<e.length;r++){var n=e.charCodeAt(r);0<=n&&n<16&&(t+="000"+n.toString(16)),16<=n&&n<255&&(t+="00"+n.toString(16)),255<=n&&n<4095&&(t+="0"+n.toString(16)),4095<=n&&n<65535&&(t+=n.toString(16))}return t}return function(e){e.Flags|=o.Universal.FullyCanonicalSig,e.Flags=e.Flags>>>0}(t),t.NickName&&(t.NickName=u(u(t.NickName))),Promise.all([function(){var o=void 0===a.signersCount?1:a.signersCount+1;if(void 0!==a.fee)return t.Fee=s(i.callToDrops(a.fee),o),Promise.resolve(t);var c=r._feeCushion;return i.serverInfo.getFee(r.connection,c).then(function(u){return r.connection.getFeeRef().then(function(r){var f="EscrowFinish"!==t.TransactionType||void 0===t.Fulfillment?0:c*r*(32+Math.floor(new e(t.Fulfillment,"hex").length/16)),d=i.callToDrops(u);if(void 0!==a.maxFee){var h=i.callToDrops(a.maxFee),l=s(d,o,f);t.Fee=n.default.min(l,h).toString()}else t.Fee=s(d,o,f);return t})})}(),function(){if(void 0!==a.sequence)return t.Sequence=a.sequence,Promise.resolve(t);var e={command:"account_info",account:c};return r.connection.request(e).then(function(e){return t.Sequence=e.account_data.Sequence,t})}()]).then(function(){return function(e){var t={fee:i.dropsToCall(e.Fee),sequence:e.Sequence};return{tx_json:JSON.stringify(e),instructions:t}}(t)})},t.convertStringToHex=a,t.convertMemo=function(e){return{Memo:i.removeUndefined({MemoData:e.data?a(e.data):void 0,MemoType:e.type?a(e.type):void 0,MemoFormat:e.format?a(e.format):void 0})}}}).call(t,r(6).Buffer)},function(e,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(r=window)}e.exports=r},function(e,t,r){"use strict";var n=t;n.version=r(115).version,n.utils=r(116),n.rand=r(62),n.hmacDRBG=r(117),n.curve=r(38),n.curves=r(122),n.ec=r(124),n.eddsa=r(127)},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});var _=r(1),n=r(261),i=r(5),o=r(0),s=r(16);function a(e){if("number"==typeof e)return o.callTimeToISO8601(e)}function c(e){""===e.counterparty&&delete e.counterparty}function u(e){return 0!=(e.Flags&o.txFlags.Payment.PartialPayment)}function f(t){return t?new e(t,"hex").toString("utf-8"):void 0}t.adjustQualityForCALL=function(e,t,r){var n=("CALL"===r?-6:0)-("CALL"===t?-6:0);return 0===n?e:new i.default(e).shift(n).toString()},t.parseQuality=function(e){if("number"==typeof e)return new i.default(e).shift(-9).toNumber()},t.parseTimestamp=a,t.isPartialPayment=u,t.parseOutcome=function(e){var t=e.meta||e.metaData;if(t){var r=n.parseBalanceChanges(t),i=n.parseOrderbookChanges(t);return function(e){_.forEach(e,function(e){_.forEach(e,c)})}(r),function(e){_.forEach(e,function(e){_.forEach(e,function(e){_.forEach(e,c)})})}(i),o.removeUndefined({result:e.meta.TransactionResult,timestamp:a(e.date),fee:o.dropsToCall(e.Fee),balanceChanges:r,orderbookChanges:i,ledgerVersion:e.ledger_index,indexInLedger:e.meta.TransactionIndex,deliveredAmount:function(e){if("Payment"===e.TransactionType&&"tesSUCCESS"===e.meta.TransactionResult&&(!e.meta.delivered_amount||"unavailable"!==e.meta.delivere