!function(t,r){"object"==typeofexports&&"object"==typeofmodule?module.exports=r():"function"==typeofdefine&&define.amd?define("Eth",[],r):"object"==typeofexports?exports.Eth=r():t.Eth=r()}(this,function(){returnfunction(t){functionr(i){if(e[i])returne[i].exports;varn=e[i]={i:i,l:!1,exports:{}};returnt[i].call(n.exports,n,n.exports,r),n.l=!0,n.exports}vare={};returnr.m=t,r.c=e,r.i=function(t){returnt},r.d=function(t,r,e){Object.defineProperty(t,r,{configurable:!1,enumerable:!0,get:e})},r.o=function(t,r){returnObject.prototype.hasOwnProperty.call(t,r)},r.p="",r(r.s=26)}([function(t,r,e){"use strict";(function(t,i){functionn(){try{vart=newUint8Array(1);returnt.__proto__={__proto__:Uint8Array.prototype,foo:function(){return42}},42===t.foo()&&"function"==typeoft.subarray&&0===t.subarray(1,1).byteLength}catch(r){return!1}}functiono(){returnt.TYPED_ARRAY_SUPPORT?2147483647:1073741823}functions(r,e){if(o()<e)thrownewRangeError("Invalid typed array length");returnt.TYPED_ARRAY_SUPPORT?(r=newUint8Array(e),r.__proto__=t.prototype):(null===r&&(r=newt(e)),r.length=e),r}functiont(r,e,i){if(!(t.TYPED_ARRAY_SUPPORT||thisinstanceoft))returnnewt(r,e,i);if("number"==typeofr){if("string"==typeofe)throwError("If encoding is specified then the first argument must be a string");returnf(this,r)}returnh(this,r,e,i)}functionh(t,r,e,i){if("number"==typeofr)thrownewTypeError('"value" argument must not be a number');return"undefined"!=typeofArrayBuffer&&rinstanceofArrayBuffer?p(t,r,e,i):"string"==typeofr?l(t,r,e):d(t,r)}functionu(t){if("number"!=typeoft)thrownewTypeError('"size" argument must be a number');if(0>t)thrownewRangeError('"size" argument must not be negative')}functiona(t,r,e,i){returnu(r),r>0&&void0!==e?"string"==typeofi?s(t,r).fill(e,i):s(t,r).fill(e):s(t,r)}functionf(r,e){if(u(e),r=s(r,0>e?0:0|m(e)),!t.TYPED_ARRAY_SUPPORT)for(vari=0;e>i;++i)r[i]=0;returnr}functionl(r,e,i){if("string"==typeofi&&""!==i||(i="utf8"),!t.isEncoding(i))thrownewTypeError('"encoding" must be a valid string encoding');varn=0|v(e,i);r=s(r,n);varo=r.write(e,i);returno!==n&&(r=r.slice(0,o)),r}functionc(t,r){vare=0>r.length?0:0|m(r.length);t=s(t,e);for(vari=0;e>i;i+=1)t[i]=255&r[i];returnt}functionp(r,e,i,n){if(0>i||i>e.byteLength)thrownewRangeError("'offset' is out of bounds");if(i+(n||0)>e.byteLength)thrownewRangeError("'length' is out of bounds");returne=void0===i&&void0===n?newUint8Array(e):void0===n?newUint8Array(e,i):newUint8Array(e,i,n),t.TYPED_ARRAY_SUPPORT?(r=e,r.__proto__=t.prototype):r=c(r,e),r}functiond(r,e){if(t.isBuffer(e)){vari=0|m(e.length);returnr=s(r,i),0===r.length?r:(e.copy(r,0,0,i),r)}if(e){if("undefined"!=typeofArrayBuffer&&e.bufferinstanceofArrayBuffer||"length"ine)return"number"!=typeofe.length||W(e.length)?s(r,0):c(r,e);if("Buffer"===e.type&&X(e.data))returnc(r,e.data)}thrownewTypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}functionm(t){if(t>=o())thrownewRangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o().toString(16)+" bytes");return0|t}functiong(r){return+r!=r&&(r=0),t.alloc(+r)}functionv(r,e){if(t.isBuffer(r))returnr.length;if("undefined"!=typeofArrayBuffer&&"function"==typeofArrayBuffer.isView&&(ArrayBuffer.isView(r)||rinstanceofArrayBuffer))returnr.byteLength;"string"!=typeofr&&(r=""+r);vari=r.length;if(0===i)return0;for(varn=!1;;)switch(e){case"ascii":case"latin1":case"binary":returni;case"utf8":case"utf-8":casevoid0:returnz(r).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return2*i;case"hex":returni>>>1;case"base64":returnK(r).length;default:if(n)returnz(r).length;e=(""+e).toLowerCase(),n=!0}}functiony(t,r,e){vari=!1;if((void0===r||0>r)&&(r=0),r>this.length)return"";if((void0===e||e>this.length)&&(e=this.length),0>=e)return"";if(e>>>=0,r>>>=0,r>=e)return"";for(t||(t="utf8");;)switch(t){case"hex":returnR(this,r,e);case"utf8":case"utf-8":returnk(this,r,e);case"ascii":returnD(this,r,e);case"latin1":case"binary":returnP(this,r,e);case"
if(Array.isArray(r)!==!0)throwError("[ethjs-util] method arrayContainsArray requires input 'subset' to be an array got type '"+typeofr+"'");returnr[!!e&&"some"||"every"](function(r){returnt.indexOf(r)>=0})}functionu(t){vare=newr(i(m(t).replace(/^0+|0+$/g,"")),"hex");returne.toString("utf8")}functiona(t){varr="",e=0,i=t.length;for("0x"===t.substring(0,2)&&(e=2);i>e;e+=2){varn=parseInt(t.substr(e,2),16);r+=String.fromCharCode(n)}returnr}functionf(t){vare=newr(t,"utf8");return"0x"+i(e.toString("hex")).replace(/^0+|0+$/g,"")}functionl(t){for(varr="",e=0;t.length>e;e++){vari=t.charCodeAt(e),n=i.toString(16);r+=2>n.length?"0"+n:n}return"0x"+r}functionc(t,r,e){if(!Array.isArray(t))throwError("[ethjs-util] method getKeys expecting type Array as 'params' input, got '"+typeoft+"'");if("string"!=typeofr)throwError("[ethjs-util] method getKeys expecting type String for input 'key' got '"+typeofr+"'.");for(vari=[],n=0;t.length>n;n++){varo=t[n][r];if(e&&!o)o="";elseif("string"!=typeofo)throwError("invalid abi");i.push(o)}returni}functionp(t,r){return!("string"!=typeoft||!t.match(/^0x[0-9A-Fa-f]*$/))&&(!r||t.length===2+2*r)}vard=e(8),m=e(5);t.exports={arrayContainsArray:h,intToBuffer:o,getBinarySize:s,isHexPrefixed:d,stripHexPrefix:m,padToEven:i,intToHex:n,fromAscii:l,fromUtf8:f,toAscii:a,toUtf8:u,getKeys:c,isHexString:p}}).call(r,e(0).Buffer)},function(t,r,e){vari=e(1),n=e(5);t.exports=function(t){if("string"==typeoft||"number"==typeoft){varr=newi(1),e=(t+"").toLowerCase().trim(),o="0x"===e.substr(0,2)||"-0x"===e.substr(0,3),s=n(e);if("-"===s.substr(0,1)&&(s=n(s.slice(1)),r=newi((-1),10)),s=""===s?"0":s,!s.match(/^-?[0-9]+$/)&&s.match(/^[0-9A-Fa-f]+$/)||s.match(/^[a-fA-F]+$/)||o===!0&&s.match(/^[0-9A-Fa-f]+$/))returnnewi(s,16).mul(r);if((s.match(/^-?[0-9]+$/)||""===s)&&o===!1)returnnewi(s,10).mul(r)}elseif("object"==typeoft&&t.toString&&!t.pop&&!t.push&&t.toString(10).match(/^-?[0-9]+$/)&&(t.mul||t.dividedToIntegerBy))returnnewi(t.toString(10),10);throwError("[number-to-bn] while converting number "+JSON.stringify(t)+" to BN.js instance, error: invalid number value. Value must be an integer, hex string, BN or BigNumber instance. Note, decimals are not supported.")}},function(t,r,e){(function(r,e){/**