@waves/assets-pairs-order
Advanced tools
Comparing version 2.0.0 to 2.1.0
@@ -1,11 +0,136 @@ | ||
(function(a,b){'object'==typeof exports&&'undefined'!=typeof module?module.exports=b(require('buffer')):'function'==typeof define&&define.amd?define(['buffer'],b):a.orderAssetsPairs=b(a.buffer)})(this,function(a){'use strict';a=a&&a.hasOwnProperty('default')?a['default']:a;var b=function(a,b){return b={exports:{}},a(b,b.exports),b.exports}(function(b,c){// alternative to using Object.keys for old browsers | ||
function d(a,b){for(var c in a)b[c]=a[c]}function e(a,b,c){return f(a,b,c)}// Copy static methods from Buffer | ||
/* eslint-disable node/no-deprecated-api */var f=a.Buffer;f.from&&f.alloc&&f.allocUnsafe&&f.allocUnsafeSlow?b.exports=a:(d(a,c),c.Buffer=e),d(f,e),e.from=function(a,b,c){if('number'==typeof a)throw new TypeError('Argument must not be a number');return f(a,b,c)},e.alloc=function(a,b,c){if('number'!=typeof a)throw new TypeError('Argument must be a number');var d=f(a);return void 0===b?d.fill(0):'string'==typeof c?d.fill(b,c):d.fill(b),d},e.allocUnsafe=function(a){if('number'!=typeof a)throw new TypeError('Argument must be a number');return f(a)},e.allocUnsafeSlow=function(b){if('number'!=typeof b)throw new TypeError('Argument must be a number');return a.SlowBuffer(b)}}),c=b.Buffer,d=b.Buffer,e=function(a){function b(a){if('string'!=typeof a)throw new TypeError('Expected String');if(0===a.length)return d.allocUnsafe(0);for(var b,c=[0],h=0;h<a.length;h++){if(b=e[a[h]],void 0===b)return;for(var i=0,j=b;i<c.length;++i)j+=c[i]*f,c[i]=255&j,j>>=8;for(;0<j;)c.push(255&j),j>>=8}// deal with leading zeros | ||
for(var l=0;a[l]===g&&l<a.length-1;++l)c.push(0);return d.from(c.reverse())}// pre-compute lookup table | ||
for(var c,e={},f=a.length,g=a.charAt(0),h=0;h<a.length;h++){if(c=a.charAt(h),void 0!==e[c])throw new TypeError(c+' is ambiguous');e[c]=h}return{encode:function(b){if(0===b.length)return'';for(var c=[0],d=0;d<b.length;++d){for(var e=0,h=b[d];e<c.length;++e)h+=c[e]<<8,c[e]=h%f,h=0|h/f;for(;0<h;)c.push(h%f),h=0|h/f}// deal with leading zeros | ||
for(var i='',j=0;0===b[j]&&j<b.length-1;++j)i+=g;// convert digits to a string | ||
for(var k=c.length-1;0<=k;--k)i+=a[c[k]];return i},decodeUnsafe:b,decode:function(a){var c=b(a);if(c)return c;throw new Error('Non-base'+f+' character')}}}('123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz'),f=function(a,b){// true - arr1 bigger | ||
(function(a,b){'object'==typeof exports&&'undefined'!=typeof module?module.exports=b():'function'==typeof define&&define.amd?define(b):a.orderAssetsPairs=b()})(this,function(){'use strict';function a(){ka=!0;for(var a='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/',b=0,c=a.length;b<c;++b)ha[b]=a[b],ia[a.charCodeAt(b)]=b;ia[45]=62,ia[95]=63}function b(b){ka||a();var c,d,e,f,g,h,i=b.length;if(0<i%4)throw new Error('Invalid string. Length must be a multiple of 4');// the number of equal signs (place holders) | ||
// if there are two placeholders, than the two characters before it | ||
// represent one byte | ||
// if there is only one, then the three characters before it represent 2 bytes | ||
// this is just a cheap hack to not do indexOf twice | ||
g='='===b[i-2]?2:'='===b[i-1]?1:0,h=new ja(3*i/4-g),e=0<g?i-4:i;var j=0;for(c=0,d=0;c<e;c+=4,d+=3)f=ia[b.charCodeAt(c)]<<18|ia[b.charCodeAt(c+1)]<<12|ia[b.charCodeAt(c+2)]<<6|ia[b.charCodeAt(c+3)],h[j++]=255&f>>16,h[j++]=255&f>>8,h[j++]=255&f;return 2===g?(f=ia[b.charCodeAt(c)]<<2|ia[b.charCodeAt(c+1)]>>4,h[j++]=255&f):1==g&&(f=ia[b.charCodeAt(c)]<<10|ia[b.charCodeAt(c+1)]<<4|ia[b.charCodeAt(c+2)]>>2,h[j++]=255&f>>8,h[j++]=255&f),h}function c(a){return ha[63&a>>18]+ha[63&a>>12]+ha[63&a>>6]+ha[63&a]}function d(a,b,d){for(var e,f=[],g=b;g<d;g+=3)e=(a[g]<<16)+(a[g+1]<<8)+a[g+2],f.push(c(e));return f.join('')}function e(b){ka||a();// must be multiple of 3 | ||
// go through the array every three bytes, we'll deal with trailing stuff later | ||
// if we have 1 byte left, pad 2 bytes | ||
for(var c,e=b.length,f=e%3,g='',h=[],j=16383,k=0,i=e-f;k<i;k+=j)h.push(d(b,k,k+j>i?i:k+j));// pad the end with zeros, but make sure to not forget the extra bytes | ||
return 1==f?(c=b[e-1],g+=ha[c>>2],g+=ha[63&c<<4],g+='=='):2==f&&(c=(b[e-2]<<8)+b[e-1],g+=ha[c>>10],g+=ha[63&c>>4],g+=ha[63&c<<2],g+='='),h.push(g),h.join('')}function f(a,b,c,f,g){var h,e,j=8*g-f-1,k=(1<<j)-1,l=k>>1,m=-7,n=c?g-1:0,i=c?-1:1,d=a[b+n];for(n+=i,h=d&(1<<-m)-1,d>>=-m,m+=j;0<m;h=256*h+a[b+n],n+=i,m-=8);for(e=h&(1<<-m)-1,h>>=-m,m+=f;0<m;e=256*e+a[b+n],n+=i,m-=8);if(0===h)h=1-l;else{if(h===k)return e?NaN:(d?-1:1)*Infinity;e+=ga(2,f),h-=l}return(d?-1:1)*e*ga(2,h-f)}function g(a,b,f,g,h,j){var k,l,m,c=8*j-h-1,n=(1<<c)-1,o=n>>1,p=23===h?5.960464477539063e-8-6.617444900424222e-24:0,q=g?0:j-1,i=g?1:-1,d=0>b||0===b&&0>1/b?1:0;for(b=Math.abs(b),isNaN(b)||b===Infinity?(l=isNaN(b)?1:0,k=n):(k=fa(Math.log(b)/Math.LN2),1>b*(m=ga(2,-k))&&(k--,m*=2),b+=1<=k+o?p/m:p*ga(2,1-o),2<=b*m&&(k++,m/=2),k+o>=n?(l=0,k=n):1<=k+o?(l=(b*m-1)*ga(2,h),k+=o):(l=b*ga(2,o-1)*ga(2,h),k=0));8<=h;a[f+q]=255&l,q+=i,l/=256,h-=8);for(k=k<<h|l,c+=h;0<c;a[f+q]=255&k,q+=i,k/=256,c-=8);a[f+q-i]|=128*d}function h(){return k.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function j(a,b){if(h()<b)throw new RangeError('Invalid typed array length');return k.TYPED_ARRAY_SUPPORT?(a=new Uint8Array(b),a.__proto__=k.prototype):(null===a&&(a=new k(b)),a.length=b),a}/** | ||
* The Buffer constructor returns instances of `Uint8Array` that have their | ||
* prototype changed to `Buffer.prototype`. Furthermore, `Buffer` is a subclass of | ||
* `Uint8Array`, so the returned instances will have all the node `Buffer` methods | ||
* and the `Uint8Array` methods. Square bracket notation works as expected -- it | ||
* returns a single octet. | ||
* | ||
* The `Uint8Array` prototype remains unmodified. | ||
*/function k(a,b,c){if(!k.TYPED_ARRAY_SUPPORT&&!(this instanceof k))return new k(a,b,c);// Common case. | ||
if('number'==typeof a){if('string'==typeof b)throw new Error('If encoding is specified then the first argument must be a string');return n(this,a)}return i(this,a,b,c)}function i(a,b,c,d){if('number'==typeof b)throw new TypeError('"value" argument must not be a number');return'undefined'!=typeof ArrayBuffer&&b instanceof ArrayBuffer?q(a,b,c,d):'string'==typeof b?o(a,b,c):r(a,b)}/** | ||
* Functionally equivalent to Buffer(arg, encoding) but throws a TypeError | ||
* if value is a number. | ||
* Buffer.from(str[, encoding]) | ||
* Buffer.from(array) | ||
* Buffer.from(buffer) | ||
* Buffer.from(arrayBuffer[, byteOffset[, length]]) | ||
**/function l(a){if('number'!=typeof a)throw new TypeError('"size" argument must be a number');else if(0>a)throw new RangeError('"size" argument must not be negative')}function m(a,b,c,d){return l(b),0>=b?j(a,b):void 0===c?j(a,b):'string'==typeof d?j(a,b).fill(c,d):j(a,b).fill(c)}/** | ||
* Creates a new filled Buffer instance. | ||
* alloc(size[, fill[, encoding]]) | ||
**/function n(a,b){if(l(b),a=j(a,0>b?0:0|s(b)),!k.TYPED_ARRAY_SUPPORT)for(var c=0;c<b;++c)a[c]=0;return a}/** | ||
* Equivalent to Buffer(num), by default creates a non-zero-filled Buffer instance. | ||
* */function o(a,b,c){if(('string'!=typeof c||''===c)&&(c='utf8'),!k.isEncoding(c))throw new TypeError('"encoding" must be a valid string encoding');var d=0|u(b,c);a=j(a,d);var e=a.write(b,c);return e!==d&&(a=a.slice(0,e)),a}function p(a,b){var c=0>b.length?0:0|s(b.length);a=j(a,c);for(var d=0;d<c;d+=1)a[d]=255&b[d];return a}function q(a,b,c,d){// this throws if `array` is not a valid ArrayBuffer | ||
if(b.byteLength,0>c||b.byteLength<c)throw new RangeError('\'offset\' is out of bounds');if(b.byteLength<c+(d||0))throw new RangeError('\'length\' is out of bounds');return b=void 0===c&&void 0===d?new Uint8Array(b):void 0===d?new Uint8Array(b,c):new Uint8Array(b,c,d),k.TYPED_ARRAY_SUPPORT?(a=b,a.__proto__=k.prototype):a=p(a,b),a}function r(a,b){if(t(b)){var c=0|s(b.length);return(a=j(a,c),0===a.length)?a:(b.copy(a,0,0,c),a)}if(b){if('undefined'!=typeof ArrayBuffer&&b.buffer instanceof ArrayBuffer||'length'in b)return'number'!=typeof b.length||_(b.length)?j(a,0):p(a,b);if('Buffer'===b.type&&ma(b.data))return p(a,b.data)}throw new TypeError('First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.')}function s(a){// Note: cannot use `length < kMaxLength()` here because that fails when | ||
// length is NaN (which is otherwise coerced to zero.) | ||
if(a>=h())throw new RangeError('Attempt to allocate Buffer larger than maximum size: 0x'+h().toString(16)+' bytes');return 0|a}function t(a){return!!(null!=a&&a._isBuffer)}function u(a,b){if(t(a))return a.length;if('undefined'!=typeof ArrayBuffer&&'function'==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(a)||a instanceof ArrayBuffer))return a.byteLength;'string'!=typeof a&&(a=''+a);var c=a.length;if(0===c)return 0;// Use a for loop to avoid recursion | ||
for(var d=!1;;)switch(b){case'ascii':case'latin1':case'binary':return c;case'utf8':case'utf-8':case void 0:return W(a).length;case'ucs2':case'ucs-2':case'utf16le':case'utf-16le':return 2*c;case'hex':return c>>>1;case'base64':return Z(a).length;default:if(d)return W(a).length;// assume utf8 | ||
b=(''+b).toLowerCase(),d=!0;}}function v(a,b,c){var d=!1;// No need to verify that "this.length <= MAX_UINT32" since it's a read-only | ||
// property of a typed array. | ||
// This behaves neither like String nor Uint8Array in that we set start/end | ||
// to their upper/lower bounds if the value passed is out of range. | ||
// undefined is handled specially as per ECMA-262 6th Edition, | ||
// Section 13.3.3.7 Runtime Semantics: KeyedBindingInitialization. | ||
// Return early if start > this.length. Done here to prevent potential uint32 | ||
// coercion fail below. | ||
if((void 0===b||0>b)&&(b=0),b>this.length)return'';if((void 0===c||c>this.length)&&(c=this.length),0>=c)return'';// Force coersion to uint32. This will also coerce falsey/NaN values to 0. | ||
if(c>>>=0,b>>>=0,c<=b)return'';for(a||(a='utf8');;)switch(a){case'hex':return K(this,b,c);case'utf8':case'utf-8':return G(this,b,c);case'ascii':return I(this,b,c);case'latin1':case'binary':return J(this,b,c);case'base64':return F(this,b,c);case'ucs2':case'ucs-2':case'utf16le':case'utf-16le':return L(this,b,c);default:if(d)throw new TypeError('Unknown encoding: '+a);a=(a+'').toLowerCase(),d=!0;}}// The property is used by `Buffer.isBuffer` and `is-buffer` (in Safari 5-7) to detect | ||
// Buffer instances. | ||
function w(a,b,c){var d=a[b];a[b]=a[c],a[c]=d}// Finds either the first index of `val` in `buffer` at offset >= `byteOffset`, | ||
// OR the last index of `val` in `buffer` at offset <= `byteOffset`. | ||
// | ||
// Arguments: | ||
// - buffer - a Buffer to search | ||
// - val - a string, Buffer, or number | ||
// - byteOffset - an index into `buffer`; will be clamped to an int32 | ||
// - encoding - an optional encoding, relevant is val is a string | ||
// - dir - true for indexOf, false for lastIndexOf | ||
function x(a,b,c,d,e){// Empty buffer means no match | ||
if(0===a.length)return-1;// Normalize byteOffset | ||
if('string'==typeof c?(d=c,c=0):2147483647<c?c=2147483647:-2147483648>c&&(c=-2147483648),c=+c,isNaN(c)&&(c=e?0:a.length-1),0>c&&(c=a.length+c),c>=a.length){if(e)return-1;c=a.length-1}else if(0>c)if(e)c=0;else return-1;// Normalize val | ||
// Finally, search either indexOf (if dir is true) or lastIndexOf | ||
if('string'==typeof b&&(b=k.from(b,d)),t(b))// Special case: looking for empty string/buffer always fails | ||
return 0===b.length?-1:y(a,b,c,d,e);if('number'==typeof b)// Search for a byte value [0-255] | ||
return b&=255,k.TYPED_ARRAY_SUPPORT&&'function'==typeof Uint8Array.prototype.indexOf?e?Uint8Array.prototype.indexOf.call(a,b,c):Uint8Array.prototype.lastIndexOf.call(a,b,c):y(a,[b],c,d,e);throw new TypeError('val must be string, number or Buffer')}function y(a,b,c,d,e){function f(a,b){return 1===g?a[b]:a.readUInt16BE(b*g)}var g=1,h=a.length,k=b.length;if(void 0!==d&&(d=(d+'').toLowerCase(),'ucs2'===d||'ucs-2'===d||'utf16le'===d||'utf-16le'===d)){if(2>a.length||2>b.length)return-1;g=2,h/=2,k/=2,c/=2}var l;if(e){var i=-1;for(l=c;l<h;l++)if(f(a,l)!==f(b,-1==i?0:l-i))-1!=i&&(l-=l-i),i=-1;else if(-1==i&&(i=l),l-i+1===k)return i*g}else for(c+k>h&&(c=h-k),l=c;0<=l;l--){for(var m=!0,n=0;n<k;n++)if(f(a,l+n)!==f(b,n)){m=!1;break}if(m)return l}return-1}function z(a,b,c,d){c=+c||0;var e=a.length-c;d?(d=+d,d>e&&(d=e)):d=e;// must be an even number of digits | ||
var f=b.length;if(0!=f%2)throw new TypeError('Invalid hex string');d>f/2&&(d=f/2);for(var g,h=0;h<d;++h){if(g=parseInt(b.substr(2*h,2),16),isNaN(g))return h;a[c+h]=g}return h}function A(a,b,c,d){return $(W(b,a.length-c),a,c,d)}function B(a,b,c,d){return $(X(b),a,c,d)}function C(a,b,c,d){return B(a,b,c,d)}function D(a,b,c,d){return $(Z(b),a,c,d)}function E(a,b,c,d){return $(Y(b,a.length-c),a,c,d)}function F(a,b,c){return 0===b&&c===a.length?e(a):e(a.slice(b,c))}function G(a,b,c){c=ea(a.length,c);for(var d=[],e=b;e<c;){var f=a[e],g=null,h=239<f?4:223<f?3:191<f?2:1;if(e+h<=c){var i,j,k,l;1==h?128>f&&(g=f):2==h?(i=a[e+1],128==(192&i)&&(l=(31&f)<<6|63&i,127<l&&(g=l))):3==h?(i=a[e+1],j=a[e+2],128==(192&i)&&128==(192&j)&&(l=(15&f)<<12|(63&i)<<6|63&j,2047<l&&(55296>l||57343<l)&&(g=l))):4==h?(i=a[e+1],j=a[e+2],k=a[e+3],128==(192&i)&&128==(192&j)&&128==(192&k)&&(l=(15&f)<<18|(63&i)<<12|(63&j)<<6|63&k,65535<l&&1114112>l&&(g=l))):void 0}null===g?(g=65533,h=1):65535<g&&(g-=65536,d.push(55296|1023&g>>>10),g=56320|1023&g),d.push(g),e+=h}return H(d)}// Based on http://stackoverflow.com/a/22747272/680742, the browser with | ||
// the lowest limit is Chrome, with 0x10000 args. | ||
// We go 1 magnitude less, for safety | ||
function H(a){var b=a.length;if(b<=pa)return da.apply(String,a);// avoid extra slice() | ||
// Decode in chunks to avoid "call stack size exceeded". | ||
for(var c='',d=0;d<b;)c+=da.apply(String,a.slice(d,d+=pa));return c}function I(a,b,c){var d='';c=ea(a.length,c);for(var e=b;e<c;++e)d+=da(127&a[e]);return d}function J(a,b,c){var d='';c=ea(a.length,c);for(var e=b;e<c;++e)d+=da(a[e]);return d}function K(a,b,c){var d=a.length;(!b||0>b)&&(b=0),(!c||0>c||c>d)&&(c=d);for(var e='',f=b;f<c;++f)e+=V(a[f]);return e}function L(a,b,c){for(var d=a.slice(b,c),e='',f=0;f<d.length;f+=2)e+=da(d[f]+256*d[f+1]);return e}/* | ||
* Need to make sure that buffer isn't trying to write out of bounds. | ||
*/function M(a,b,c){if(0!=a%1||0>a)throw new RangeError('offset is not uint');if(a+b>c)throw new RangeError('Trying to access beyond buffer length')}function N(a,b,c,d,e,f){if(!t(a))throw new TypeError('"buffer" argument must be a Buffer instance');if(b>e||b<f)throw new RangeError('"value" argument is out of bounds');if(c+d>a.length)throw new RangeError('Index out of range')}function O(a,b,c,d){0>b&&(b=65535+b+1);for(var e=0,f=ea(a.length-c,2);e<f;++e)a[c+e]=(b&255<<8*(d?e:1-e))>>>8*(d?e:1-e)}function P(a,b,c,d){0>b&&(b=4294967295+b+1);for(var e=0,f=ea(a.length-c,4);e<f;++e)a[c+e]=255&b>>>8*(d?e:3-e)}function Q(a,b,c,d){if(c+d>a.length)throw new RangeError('Index out of range');if(0>c)throw new RangeError('Index out of range')}function R(a,b,c,d,e){return e||Q(a,b,c,4,34028234663852886e22,-34028234663852886e22),g(a,b,c,d,23,4),c+4}function S(a,b,c,d,e){return e||Q(a,b,c,8,17976931348623157e292,-17976931348623157e292),g(a,b,c,d,52,8),c+8}function T(a){// Node converts strings with length < 2 to '' | ||
if(a=U(a).replace(qa,''),2>a.length)return'';// Node allows for non-padded base64 strings (missing trailing ===), base64-js does not | ||
for(;0!=a.length%4;)a+='=';return a}function U(a){return a.trim?a.trim():a.replace(/^\s+|\s+$/g,'')}function V(a){return 16>a?'0'+a.toString(16):a.toString(16)}function W(a,b){b=b||Infinity;for(var c,d=a.length,e=null,f=[],g=0;g<d;++g){// is surrogate component | ||
if(c=a.charCodeAt(g),55295<c&&57344>c){// last char was a lead | ||
if(!e){// no lead yet | ||
if(56319<c){-1<(b-=3)&&f.push(239,191,189);continue}else if(g+1===d){-1<(b-=3)&&f.push(239,191,189);continue}// valid lead | ||
e=c;continue}// 2 leads in a row | ||
if(56320>c){-1<(b-=3)&&f.push(239,191,189),e=c;continue}// valid surrogate pair | ||
c=(e-55296<<10|c-56320)+65536}else e&&-1<(b-=3)&&f.push(239,191,189);// encode utf8 | ||
if(e=null,128>c){if(0>(b-=1))break;f.push(c)}else if(2048>c){if(0>(b-=2))break;f.push(192|c>>6,128|63&c)}else if(65536>c){if(0>(b-=3))break;f.push(224|c>>12,128|63&c>>6,128|63&c)}else if(1114112>c){if(0>(b-=4))break;f.push(240|c>>18,128|63&c>>12,128|63&c>>6,128|63&c)}else throw new Error('Invalid code point')}return f}function X(a){for(var b=[],c=0;c<a.length;++c)// Node's code seems to be doing this and not & 0x7F.. | ||
b.push(255&a.charCodeAt(c));return b}function Y(a,b){for(var d,c,e,f=[],g=0;g<a.length&&!(0>(b-=2));++g)d=a.charCodeAt(g),c=d>>8,e=d%256,f.push(e),f.push(c);return f}function Z(a){return b(T(a))}function $(a,b,c,d){for(var e=0;e<d&&!(e+c>=b.length||e>=a.length);++e)b[e+c]=a[e];return e}function _(a){return a!==a;// eslint-disable-line no-self-compare | ||
}// the following is from is-buffer, also by Feross Aboukhadijeh and with same lisence | ||
// The _isBuffer check is for Safari 5-7 support, because it's missing | ||
// Object.prototype.constructor. Remove this eventually | ||
function aa(a){return null!=a&&(!!a._isBuffer||ba(a)||ca(a))}function ba(a){return!!a.constructor&&'function'==typeof a.constructor.isBuffer&&a.constructor.isBuffer(a)}// For Node v0.10 support. Remove this eventually. | ||
function ca(a){return'function'==typeof a.readFloatLE&&'function'==typeof a.slice&&ba(a.slice(0,0))}var da=String.fromCharCode,ea=Math.min,fa=Math.floor,ga=Math.pow,ha=[],ia=[],ja='undefined'==typeof Uint8Array?Array:Uint8Array,ka=!1,la={}.toString,ma=Array.isArray||function(a){return'[object Array]'==la.call(a)},na=50;/*! | ||
* The buffer module from node.js, for the browser. | ||
* | ||
* @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org> | ||
* @license MIT | ||
*//** | ||
* If `Buffer.TYPED_ARRAY_SUPPORT`: | ||
* === true Use Uint8Array implementation (fastest) | ||
* === false Use Object implementation (most compatible, even IE6) | ||
* | ||
* Browsers that support typed arrays are IE 10+, Firefox 4+, Chrome 7+, Safari 5.1+, | ||
* Opera 11.6+, iOS 4.2+. | ||
* | ||
* Due to various browser bugs, sometimes the Object implementation will be used even | ||
* when the browser supports typed arrays. | ||
* | ||
* Note: | ||
* | ||
* - Firefox 4-29 lacks support for adding new properties to `Uint8Array` instances, | ||
* See: https://bugzilla.mozilla.org/show_bug.cgi?id=695438. | ||
* | ||
* - Chrome 9-10 is missing the `TypedArray.prototype.subarray` function. | ||
* | ||
* - IE10 has a broken `TypedArray.prototype.subarray` function which returns arrays of | ||
* incorrect length in some situations. | ||
* We detect these buggy browsers and set `Buffer.TYPED_ARRAY_SUPPORT` to `false` so they | ||
* get the Object implementation, which is slower but behaves correctly. | ||
*/k.TYPED_ARRAY_SUPPORT=!(global.TYPED_ARRAY_SUPPORT!==void 0)||global.TYPED_ARRAY_SUPPORT;/* | ||
* Export kMaxLength after typed array support is determined. | ||
*/var oa=h();k.poolSize=8192,k._augment=function(a){return a.__proto__=k.prototype,a},k.from=function(a,b,c){return i(null,a,b,c)},k.TYPED_ARRAY_SUPPORT&&(k.prototype.__proto__=Uint8Array.prototype,k.__proto__=Uint8Array),k.alloc=function(a,b,c){return m(null,a,b,c)},k.allocUnsafe=function(a){return n(null,a)},k.allocUnsafeSlow=function(a){return n(null,a)},k.isBuffer=aa,k.compare=function(c,a){if(!t(c)||!t(a))throw new TypeError('Arguments must be Buffers');if(c===a)return 0;for(var b=c.length,d=a.length,e=0,f=ea(b,d);e<f;++e)if(c[e]!==a[e]){b=c[e],d=a[e];break}return b<d?-1:d<b?1:0},k.isEncoding=function(a){switch((a+'').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;}},k.concat=function(a,b){if(!ma(a))throw new TypeError('"list" argument must be an Array of Buffers');if(0===a.length)return k.alloc(0);var c;if(b===void 0)for(b=0,c=0;c<a.length;++c)b+=a[c].length;var d=k.allocUnsafe(b),e=0;for(c=0;c<a.length;++c){var f=a[c];if(!t(f))throw new TypeError('"list" argument must be an Array of Buffers');f.copy(d,e),e+=f.length}return d},k.byteLength=u,k.prototype._isBuffer=!0,k.prototype.swap16=function(){var a=this.length;if(0!=a%2)throw new RangeError('Buffer size must be a multiple of 16-bits');for(var b=0;b<a;b+=2)w(this,b,b+1);return this},k.prototype.swap32=function(){var a=this.length;if(0!=a%4)throw new RangeError('Buffer size must be a multiple of 32-bits');for(var b=0;b<a;b+=4)w(this,b,b+3),w(this,b+1,b+2);return this},k.prototype.swap64=function(){var a=this.length;if(0!=a%8)throw new RangeError('Buffer size must be a multiple of 64-bits');for(var b=0;b<a;b+=8)w(this,b,b+7),w(this,b+1,b+6),w(this,b+2,b+5),w(this,b+3,b+4);return this},k.prototype.toString=function(){var a=0|this.length;return 0==a?'':0===arguments.length?G(this,0,a):v.apply(this,arguments)},k.prototype.equals=function(a){if(!t(a))throw new TypeError('Argument must be a Buffer');return this===a||0===k.compare(this,a)},k.prototype.inspect=function(){var a='',b=na;return 0<this.length&&(a=this.toString('hex',0,b).match(/.{2}/g).join(' '),this.length>b&&(a+=' ... ')),'<Buffer '+a+'>'},k.prototype.compare=function(a,b,c,d,e){if(!t(a))throw new TypeError('Argument must be a Buffer');if(void 0===b&&(b=0),void 0===c&&(c=a?a.length:0),void 0===d&&(d=0),void 0===e&&(e=this.length),0>b||c>a.length||0>d||e>this.length)throw new RangeError('out of range index');if(d>=e&&b>=c)return 0;if(d>=e)return-1;if(b>=c)return 1;if(b>>>=0,c>>>=0,d>>>=0,e>>>=0,this===a)return 0;for(var f=e-d,g=c-b,h=ea(f,g),j=this.slice(d,e),k=a.slice(b,c),l=0;l<h;++l)if(j[l]!==k[l]){f=j[l],g=k[l];break}return f<g?-1:g<f?1:0},k.prototype.includes=function(a,b,c){return-1!==this.indexOf(a,b,c)},k.prototype.indexOf=function(a,b,c){return x(this,a,b,c,!0)},k.prototype.lastIndexOf=function(a,b,c){return x(this,a,b,c,!1)},k.prototype.write=function(a,b,c,d){// Buffer#write(string) | ||
if(void 0===b)d='utf8',c=this.length,b=0;else if(void 0===c&&'string'==typeof b)d=b,c=this.length,b=0;else if(isFinite(b))b|=0,isFinite(c)?(c|=0,void 0===d&&(d='utf8')):(d=c,c=void 0);else throw new Error('Buffer.write(string, encoding, offset[, length]) is no longer supported');var e=this.length-b;if((void 0===c||c>e)&&(c=e),0<a.length&&(0>c||0>b)||b>this.length)throw new RangeError('Attempt to write outside buffer bounds');d||(d='utf8');for(var f=!1;;)switch(d){case'hex':return z(this,a,b,c);case'utf8':case'utf-8':return A(this,a,b,c);case'ascii':return B(this,a,b,c);case'latin1':case'binary':return C(this,a,b,c);case'base64':// Warning: maxLength not taken into account in base64Write | ||
return D(this,a,b,c);case'ucs2':case'ucs-2':case'utf16le':case'utf-16le':return E(this,a,b,c);default:if(f)throw new TypeError('Unknown encoding: '+d);d=(''+d).toLowerCase(),f=!0;}},k.prototype.toJSON=function(){return{type:'Buffer',data:Array.prototype.slice.call(this._arr||this,0)}};var pa=4096;k.prototype.slice=function(a,b){var c=this.length;a=~~a,b=b===void 0?c:~~b,0>a?(a+=c,0>a&&(a=0)):a>c&&(a=c),0>b?(b+=c,0>b&&(b=0)):b>c&&(b=c),b<a&&(b=a);var d;if(k.TYPED_ARRAY_SUPPORT)d=this.subarray(a,b),d.__proto__=k.prototype;else{var e=b-a;d=new k(e,void 0);for(var f=0;f<e;++f)d[f]=this[f+a]}return d},k.prototype.readUIntLE=function(a,b,c){a|=0,b|=0,c||M(a,b,this.length);for(var d=this[a],e=1,f=0;++f<b&&(e*=256);)d+=this[a+f]*e;return d},k.prototype.readUIntBE=function(a,b,c){a|=0,b|=0,c||M(a,b,this.length);for(var d=this[a+--b],e=1;0<b&&(e*=256);)d+=this[a+--b]*e;return d},k.prototype.readUInt8=function(a,b){return b||M(a,1,this.length),this[a]},k.prototype.readUInt16LE=function(a,b){return b||M(a,2,this.length),this[a]|this[a+1]<<8},k.prototype.readUInt16BE=function(a,b){return b||M(a,2,this.length),this[a]<<8|this[a+1]},k.prototype.readUInt32LE=function(a,b){return b||M(a,4,this.length),(this[a]|this[a+1]<<8|this[a+2]<<16)+16777216*this[a+3]},k.prototype.readUInt32BE=function(a,b){return b||M(a,4,this.length),16777216*this[a]+(this[a+1]<<16|this[a+2]<<8|this[a+3])},k.prototype.readIntLE=function(a,b,c){a|=0,b|=0,c||M(a,b,this.length);for(var d=this[a],e=1,f=0;++f<b&&(e*=256);)d+=this[a+f]*e;return e*=128,d>=e&&(d-=ga(2,8*b)),d},k.prototype.readIntBE=function(a,b,c){a|=0,b|=0,c||M(a,b,this.length);for(var d=b,e=1,f=this[a+--d];0<d&&(e*=256);)f+=this[a+--d]*e;return e*=128,f>=e&&(f-=ga(2,8*b)),f},k.prototype.readInt8=function(a,b){return b||M(a,1,this.length),128&this[a]?-1*(255-this[a]+1):this[a]},k.prototype.readInt16LE=function(a,b){b||M(a,2,this.length);var c=this[a]|this[a+1]<<8;return 32768&c?4294901760|c:c},k.prototype.readInt16BE=function(a,b){b||M(a,2,this.length);var c=this[a+1]|this[a]<<8;return 32768&c?4294901760|c:c},k.prototype.readInt32LE=function(a,b){return b||M(a,4,this.length),this[a]|this[a+1]<<8|this[a+2]<<16|this[a+3]<<24},k.prototype.readInt32BE=function(a,b){return b||M(a,4,this.length),this[a]<<24|this[a+1]<<16|this[a+2]<<8|this[a+3]},k.prototype.readFloatLE=function(a,b){return b||M(a,4,this.length),f(this,a,!0,23,4)},k.prototype.readFloatBE=function(a,b){return b||M(a,4,this.length),f(this,a,!1,23,4)},k.prototype.readDoubleLE=function(a,b){return b||M(a,8,this.length),f(this,a,!0,52,8)},k.prototype.readDoubleBE=function(a,b){return b||M(a,8,this.length),f(this,a,!1,52,8)},k.prototype.writeUIntLE=function(a,b,c,d){if(a=+a,b|=0,c|=0,!d){var e=ga(2,8*c)-1;N(this,a,b,c,e,0)}var f=1,g=0;for(this[b]=255&a;++g<c&&(f*=256);)this[b+g]=255&a/f;return b+c},k.prototype.writeUIntBE=function(a,b,c,d){if(a=+a,b|=0,c|=0,!d){var e=ga(2,8*c)-1;N(this,a,b,c,e,0)}var f=c-1,g=1;for(this[b+f]=255&a;0<=--f&&(g*=256);)this[b+f]=255&a/g;return b+c},k.prototype.writeUInt8=function(a,b,c){return a=+a,b|=0,c||N(this,a,b,1,255,0),k.TYPED_ARRAY_SUPPORT||(a=fa(a)),this[b]=255&a,b+1},k.prototype.writeUInt16LE=function(a,b,c){return a=+a,b|=0,c||N(this,a,b,2,65535,0),k.TYPED_ARRAY_SUPPORT?(this[b]=255&a,this[b+1]=a>>>8):O(this,a,b,!0),b+2},k.prototype.writeUInt16BE=function(a,b,c){return a=+a,b|=0,c||N(this,a,b,2,65535,0),k.TYPED_ARRAY_SUPPORT?(this[b]=a>>>8,this[b+1]=255&a):O(this,a,b,!1),b+2},k.prototype.writeUInt32LE=function(a,b,c){return a=+a,b|=0,c||N(this,a,b,4,4294967295,0),k.TYPED_ARRAY_SUPPORT?(this[b+3]=a>>>24,this[b+2]=a>>>16,this[b+1]=a>>>8,this[b]=255&a):P(this,a,b,!0),b+4},k.prototype.writeUInt32BE=function(a,b,c){return a=+a,b|=0,c||N(this,a,b,4,4294967295,0),k.TYPED_ARRAY_SUPPORT?(this[b]=a>>>24,this[b+1]=a>>>16,this[b+2]=a>>>8,this[b+3]=255&a):P(this,a,b,!1),b+4},k.prototype.writeIntLE=function(a,b,c,d){if(a=+a,b|=0,!d){var e=ga(2,8*c-1);N(this,a,b,c,e-1,-e)}var f=0,g=1,h=0;for(this[b]=255&a;++f<c&&(g*=256);)0>a&&0==h&&0!==this[b+f-1]&&(h=1),this[b+f]=255&(a/g>>0)-h;return b+c},k.prototype.writeIntBE=function(a,b,c,d){if(a=+a,b|=0,!d){var e=ga(2,8*c-1);N(this,a,b,c,e-1,-e)}var f=c-1,g=1,h=0;for(this[b+f]=255&a;0<=--f&&(g*=256);)0>a&&0==h&&0!==this[b+f+1]&&(h=1),this[b+f]=255&(a/g>>0)-h;return b+c},k.prototype.writeInt8=function(a,b,c){return a=+a,b|=0,c||N(this,a,b,1,127,-128),k.TYPED_ARRAY_SUPPORT||(a=fa(a)),0>a&&(a=255+a+1),this[b]=255&a,b+1},k.prototype.writeInt16LE=function(a,b,c){return a=+a,b|=0,c||N(this,a,b,2,32767,-32768),k.TYPED_ARRAY_SUPPORT?(this[b]=255&a,this[b+1]=a>>>8):O(this,a,b,!0),b+2},k.prototype.writeInt16BE=function(a,b,c){return a=+a,b|=0,c||N(this,a,b,2,32767,-32768),k.TYPED_ARRAY_SUPPORT?(this[b]=a>>>8,this[b+1]=255&a):O(this,a,b,!1),b+2},k.prototype.writeInt32LE=function(a,b,c){return a=+a,b|=0,c||N(this,a,b,4,2147483647,-2147483648),k.TYPED_ARRAY_SUPPORT?(this[b]=255&a,this[b+1]=a>>>8,this[b+2]=a>>>16,this[b+3]=a>>>24):P(this,a,b,!0),b+4},k.prototype.writeInt32BE=function(a,b,c){return a=+a,b|=0,c||N(this,a,b,4,2147483647,-2147483648),0>a&&(a=4294967295+a+1),k.TYPED_ARRAY_SUPPORT?(this[b]=a>>>24,this[b+1]=a>>>16,this[b+2]=a>>>8,this[b+3]=255&a):P(this,a,b,!1),b+4},k.prototype.writeFloatLE=function(a,b,c){return R(this,a,b,!0,c)},k.prototype.writeFloatBE=function(a,b,c){return R(this,a,b,!1,c)},k.prototype.writeDoubleLE=function(a,b,c){return S(this,a,b,!0,c)},k.prototype.writeDoubleBE=function(a,b,c){return S(this,a,b,!1,c)},k.prototype.copy=function(a,b,c,d){// Copy 0 bytes; we're done | ||
if(c||(c=0),d||0===d||(d=this.length),b>=a.length&&(b=a.length),b||(b=0),0<d&&d<c&&(d=c),d===c)return 0;if(0===a.length||0===this.length)return 0;// Fatal error conditions | ||
if(0>b)throw new RangeError('targetStart out of bounds');if(0>c||c>=this.length)throw new RangeError('sourceStart out of bounds');if(0>d)throw new RangeError('sourceEnd out of bounds');// Are we oob? | ||
d>this.length&&(d=this.length),a.length-b<d-c&&(d=a.length-b+c);var e,f=d-c;if(this===a&&c<b&&b<d)// descending copy from end | ||
for(e=f-1;0<=e;--e)a[e+b]=this[e+c];else if(1e3>f||!k.TYPED_ARRAY_SUPPORT)// ascending copy from start | ||
for(e=0;e<f;++e)a[e+b]=this[e+c];else Uint8Array.prototype.set.call(a,this.subarray(c,c+f),b);return f},k.prototype.fill=function(a,b,c,d){// Handle string cases: | ||
if('string'==typeof a){if('string'==typeof b?(d=b,b=0,c=this.length):'string'==typeof c&&(d=c,c=this.length),1===a.length){var e=a.charCodeAt(0);256>e&&(a=e)}if(void 0!==d&&'string'!=typeof d)throw new TypeError('encoding must be a string');if('string'==typeof d&&!k.isEncoding(d))throw new TypeError('Unknown encoding: '+d)}else'number'==typeof a&&(a&=255);// Invalid ranges are not set to a default, so can range check early. | ||
if(0>b||this.length<b||this.length<c)throw new RangeError('Out of range index');if(c<=b)return this;b>>>=0,c=c===void 0?this.length:c>>>0,a||(a=0);var f;if('number'==typeof a)for(f=b;f<c;++f)this[f]=a;else{var g=t(a)?a:W(new k(a,d).toString()),h=g.length;for(f=0;f<c-b;++f)this[f+b]=g[f%h]}return this};// HELPER FUNCTIONS | ||
// ================ | ||
var qa=/[^+\/0-9A-Za-z-_]/g,ra=/*#__PURE__*/Object.freeze({INSPECT_MAX_BYTES:na,kMaxLength:oa,Buffer:k,SlowBuffer:function(a){return+a!=a&&(a=0),k.alloc(+a)},isBuffer:aa}),sa=function(a,b){return b={exports:{}},a(b,b.exports),b.exports}(function(a,b){// alternative to using Object.keys for old browsers | ||
function c(a,b){for(var c in a)b[c]=a[c]}function d(a,b,c){return e(a,b,c)}// Copy static methods from Buffer | ||
/* eslint-disable node/no-deprecated-api */var e=ra.Buffer;e.from&&e.alloc&&e.allocUnsafe&&e.allocUnsafeSlow?a.exports=ra:(c(ra,b),b.Buffer=d),c(e,d),d.from=function(a,b,c){if('number'==typeof a)throw new TypeError('Argument must not be a number');return e(a,b,c)},d.alloc=function(a,b,c){if('number'!=typeof a)throw new TypeError('Argument must be a number');var d=e(a);return void 0===b?d.fill(0):'string'==typeof c?d.fill(b,c):d.fill(b),d},d.allocUnsafe=function(a){if('number'!=typeof a)throw new TypeError('Argument must be a number');return e(a)},d.allocUnsafeSlow=function(a){if('number'!=typeof a)throw new TypeError('Argument must be a number');return ra.SlowBuffer(a)}}),ta=sa.Buffer,ua=sa.Buffer,va=function(a){function b(a){if('string'!=typeof a)throw new TypeError('Expected String');if(0===a.length)return ua.allocUnsafe(0);for(var b,c=[0],g=0;g<a.length;g++){if(b=d[a[g]],void 0===b)return;for(var h=0,i=b;h<c.length;++h)i+=c[h]*e,c[h]=255&i,i>>=8;for(;0<i;)c.push(255&i),i>>=8}// deal with leading zeros | ||
for(var j=0;a[j]===f&&j<a.length-1;++j)c.push(0);return ua.from(c.reverse())}// pre-compute lookup table | ||
for(var c,d={},e=a.length,f=a.charAt(0),g=0;g<a.length;g++){if(c=a.charAt(g),void 0!==d[c])throw new TypeError(c+' is ambiguous');d[c]=g}return{encode:function(b){if(0===b.length)return'';for(var c=[0],d=0;d<b.length;++d){for(var g=0,h=b[d];g<c.length;++g)h+=c[g]<<8,c[g]=h%e,h=0|h/e;for(;0<h;)c.push(h%e),h=0|h/e}// deal with leading zeros | ||
for(var i='',j=0;0===b[j]&&j<b.length-1;++j)i+=f;// convert digits to a string | ||
for(var k=c.length-1;0<=k;--k)i+=a[c[k]];return i},decodeUnsafe:b,decode:function(a){var c=b(a);if(c)return c;throw new Error('Non-base'+e+' character')}}}('123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz'),wa=function(a,b){// true - arr1 bigger | ||
// false - arr2 bigger | ||
// false - equal | ||
return a.toString('hex')>b.toString('hex')},g=function(a){return Array.isArray(a)&&2===a.length&&a.every(function(a){return'string'==typeof a||a===null})},h=function(b){return Array.isArray(b)&&0===b.length},i=function(){function a(a,b){var c,d=[],e=!0,f=!1;try{for(var g,h=a[Symbol.iterator]();!(e=(g=h.next()).done)&&(d.push(g.value),!(b&&d.length===b));e=!0);}catch(a){f=!0,c=a}finally{try{!e&&h['return']&&h['return']()}finally{if(f)throw c}}return d}return function(b,c){if(Array.isArray(b))return b;if(Symbol.iterator in Object(b))return a(b,c);throw new TypeError('Invalid attempt to destructure non-iterable instance')}}(),j=[{ticker:'USD',id:'Ft8X1v1LTa1ABafufpaCWyVj8KkaxUWE6xBhW6sNFJck'},{ticker:'EUR',id:'Gtb1WRznfchDnTh37ezoDTJ4wcoKaRsKqKjJjy7nm2zU'},{ticker:'BTC',id:'8LQW8f7P5d5PZM7GtZEBgaqRPGSzS3DfPuiXrURJ4AJS'},{ticker:'WAVES',id:null},{ticker:'BCH',id:'zMFqXuoyrn5w17PFurTqxB7GsS71fp9dfk6XFwxbPCy'},{ticker:'ETH',id:'474jTeYx2r2Va35794tCScAXWJG9hU2HcgxzMowaZUnu'},{ticker:'LTC',id:'HZk1mbfuJpmxU1Fs4AX5MWLVYtctsNcg6e2C6VKqK8zk'},{ticker:'ZEC',id:'BrjUWjndUanm5VsJkbUip8VRYy6LWJePtxya3FNv4TQa'}].map(function(a){return a.id}),k=function a(){for(var b=arguments.length,c=Array(b),d=0;d<b;d++)c[d]=arguments[d];if(!a.predefinedList||!Array.isArray(a.predefinedList))throw new Error('Incorrect predefined assets list');switch(0===a.predefinedList.length&&console.warn('You have empty predefined assets list. This is probably not, what you desired. Check \'predefinedList\' property.'),!0){case 0===c.length||h(c[0]):return[];case 2===c.length&&g(c):return l([[c[0],c[1]]]);case Array.isArray(c[0])&&g(c[0][0]):return l.apply(void 0,c);case c.every(function(b){return g(b)}):return l([].concat(c));default:throw new Error('Incorrect arguments: '+JSON.stringify(c));}};// base-x encoding | ||
return a.toString('hex')>b.toString('hex')},xa=function(a){return Array.isArray(a)&&2===a.length&&a.every(function(a){return'string'==typeof a||a===null})},ya=function(b){return Array.isArray(b)&&0===b.length},za=function(){function a(a,b){var c,d=[],e=!0,f=!1;try{for(var g,h=a[Symbol.iterator]();!(e=(g=h.next()).done)&&(d.push(g.value),!(b&&d.length===b));e=!0);}catch(a){f=!0,c=a}finally{try{!e&&h['return']&&h['return']()}finally{if(f)throw c}}return d}return function(b,c){if(Array.isArray(b))return b;if(Symbol.iterator in Object(b))return a(b,c);throw new TypeError('Invalid attempt to destructure non-iterable instance')}}(),Aa=[{ticker:'USD',id:'Ft8X1v1LTa1ABafufpaCWyVj8KkaxUWE6xBhW6sNFJck'},{ticker:'EUR',id:'Gtb1WRznfchDnTh37ezoDTJ4wcoKaRsKqKjJjy7nm2zU'},{ticker:'BTC',id:'8LQW8f7P5d5PZM7GtZEBgaqRPGSzS3DfPuiXrURJ4AJS'},{ticker:'WAVES',id:null},{ticker:'BCH',id:'zMFqXuoyrn5w17PFurTqxB7GsS71fp9dfk6XFwxbPCy'},{ticker:'ETH',id:'474jTeYx2r2Va35794tCScAXWJG9hU2HcgxzMowaZUnu'},{ticker:'LTC',id:'HZk1mbfuJpmxU1Fs4AX5MWLVYtctsNcg6e2C6VKqK8zk'},{ticker:'ZEC',id:'BrjUWjndUanm5VsJkbUip8VRYy6LWJePtxya3FNv4TQa'}].map(function(a){return a.id}),Ba=function a(){for(var b=arguments.length,c=Array(b),d=0;d<b;d++)c[d]=arguments[d];if(!a.predefinedList||!Array.isArray(a.predefinedList))throw new Error('Incorrect predefined assets list');switch(0===a.predefinedList.length&&console.warn('You have empty predefined assets list. This is probably not, what you desired. Check \'predefinedList\' property.'),!0){case 0===c.length||ya(c[0]):return[];case 2===c.length&&xa(c):return Ca([[c[0],c[1]]]);case Array.isArray(c[0])&&xa(c[0][0]):return Ca.apply(void 0,c);case c.every(function(b){return xa(b)}):return Ca([].concat(c));default:throw new Error('Incorrect arguments: '+JSON.stringify(c));}};// base-x encoding | ||
// Forked from https://github.com/cryptocoinjs/bs58 | ||
@@ -20,2 +145,2 @@ // Originally written by Mike Hearn for BitcoinJ | ||
// By default predefinedList is mainNet data | ||
k.predefinedList=j;var l=function(a){return a.map(m)},m=function(a){var b=i(a,2),c=b[0],d=b[1],g=k.predefinedList.indexOf(c),h=k.predefinedList.indexOf(d),j=!!~g,l=!!~h;switch(!0){case j&&l:return g<h?[c,d]:[d,c];case j&&!l:return[c,d];case!j&&l:return[d,c];default:return f(e.decode(c),e.decode(d))?[c,d]:[d,c];}};return k}); | ||
Ba.predefinedList=Aa;var Ca=function(a){return a.map(Da)},Da=function(a){var b=za(a,2),c=b[0],d=b[1],e=Ba.predefinedList.indexOf(c),f=Ba.predefinedList.indexOf(d),g=!!~e,h=!!~f;switch(!0){case g&&h:return e<f?[c,d]:[d,c];case g&&!h:return[c,d];case!g&&h:return[d,c];default:return wa(va.decode(c),va.decode(d))?[c,d]:[d,c];}};return Ba}); |
{ | ||
"name": "@waves/assets-pairs-order", | ||
"version": "2.0.0", | ||
"version": "2.1.0", | ||
"main": "dist/index.js", | ||
@@ -23,2 +23,3 @@ "license": "MIT", | ||
"rollup-plugin-json": "^2.3.0", | ||
"rollup-plugin-node-builtins": "^2.1.2", | ||
"rollup-plugin-node-resolve": "^3.3.0" | ||
@@ -25,0 +26,0 @@ }, |
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
193244
221
1
12
1