diff --git a/CHANGELOG.md b/CHANGELOG.md index 260d5a2..8a80a24 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,10 +6,18 @@ All notable changes to this project will be documented in this file. - `0.2.x` Releases - [0.2.0] [0.2.1] - `0.3.x` Releases - [0.3.0] - `0.4.x` Releases - [0.4.0] [0.4.1] [0.4.3] [0.4.4] -- `0.5.x` Releases - [0.5.0] +- `0.5.x` Releases - [0.5.0] [0.5.1] --- +## [0.5.1](https://github.com/space-bunny/node-sdk/releases/tag/v0.5.1) + +#### Changed + +- Update dependencies +- Remove warnings +- Fix temp queue name + ## [0.5.0](https://github.com/space-bunny/node-sdk/releases/tag/v0.5.0) #### Changed diff --git a/dist/spacebunny.js b/dist/spacebunny.js index d5ba8f0..5815a71 100644 --- a/dist/spacebunny.js +++ b/dist/spacebunny.js @@ -1,76 +1,53 @@ -!function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={exports:{},id:r,loaded:!1};return e[r].call(i.exports,i,i.exports,t),i.loaded=!0,i.exports}var n={};return t.m=e,t.c=n,t.p="/",t(0)}(function(e){for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t))switch(typeof e[t]){case"function":break;case"object":e[t]=function(t){var n=t.slice(1),r=e[t[0]];return function(e,t,i){r.apply(this,[e,t,i].concat(n))}}(e[t]);break;default:e[t]=e[e[t]]}return e}([function(e,t,n){e.exports=n(1)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.StompStreamClient=t.MqttStreamClient=t.AmqpStreamClient=t.StreamClient=t.StompClient=t.MqttClient=t.AmqpClient=t.Client=void 0;var i=n(2),o=r(i),s=n(246),a=r(s),u=n(298),c=r(u),l=n(306),f=r(l),h=n(307),p=r(h),d=n(308),v=r(d);"undefined"!=typeof window&&(window.StompClient=c["default"],window.StompStreamClient=v["default"]),t.Client=o["default"],t.AmqpClient=o["default"],t.MqttClient=a["default"],t.StompClient=c["default"],t.StreamClient=f["default"],t.AmqpStreamClient=f["default"],t.MqttStreamClient=p["default"],t.StompStreamClient=v["default"]},function(e,t,n){(function(e){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(7),u=r(a),c=function(){function e(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{};return i=(0,f["default"])(this._publishArgs,i),new p["default"](function(o,s){r._createChannel("output",i).then(function(o){var s=new e(r._encapsulateContent(n)),a=[o.checkExchange(r.deviceId()),o.publish(r.deviceId(),r._routingKeyFor(t),s,i)];return i.withConfirm===!0&&a.push(o.waitForConfirms()),v["default"].all(a)}).then(function(e){o(e)})["catch"](function(e){s(e)})})}},{key:"disconnect",value:function(){var e=this;return new p["default"](function(t,n){void 0===e._amqpConnection?n("Not Connected"):e._amqpConnection.close().then(function(){e._amqpConnection=void 0,e._amqpChannels={},e.emit("disconnect"),t(!0)})["catch"](function(e){n(e)})})}},{key:"connect",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=(0,f["default"])(this._connectionOpts,t);return new p["default"](function(t,r){e.getEndpointConfigs().then(function(i){var o=i.connection;if(void 0!==e._amqpConnection)t(e._amqpConnection);else{var s="";e._tls?(s=e._tlsProtocol+"://"+(o.deviceId||o.client)+":"+(o.secret+"@"+o.host+":")+(o.protocols.amqp.tlsPort+"/"+o.vhost.replace("/","%2f")),n=(0,f["default"])(n,e._tlsOpts)):s=e._protocol+"://"+(o.deviceId||o.client)+":"+(o.secret+"@"+o.host+":")+(o.protocols.amqp.port+"/"+o.vhost.replace("/","%2f")),y["default"].connect(s,n).then(function(n){n.on("error",function(t){e.emit("error",t),r(t)}),n.on("close",function(t){e.emit("close",t),e._amqpConnection=void 0}),n.on("blocked",function(t){e.emit("blocked",t),console.warn(t)}),n.on("unblocked",function(t){e.emit("unblocked",t),console.warn(t)}),e._amqpConnection=n,e.emit("connect"),t(e._amqpConnection)})["catch"](function(e){r(e)})}})["catch"](function(e){r(e)})})}},{key:"isConnected",value:function(){return void 0!==this._amqpConnection}},{key:"_createChannel",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e=""+e+(n.withConfirm===!0?"WithConfirm":""),new p["default"](function(r,i){t._amqpChannels[e]?r(t._amqpChannels[e]):t.connect().then(function(e){return n.withConfirm===!0?e.createConfirmChannel():e.createChannel()}).then(function(n){t._amqpChannels[e]=n,r(n)})["catch"](function(e){i(e)})})}},{key:"_closeChannel",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e=""+e+(n.withConfirm===!0?"WithConfirm":""),new p["default"](function(n,r){var i=t._amqpChannels[e];void 0===i?r("Invalid Channel Object"):i.close().then(function(){t._amqpChannels[e]=void 0,n(!0)})["catch"](function(e){r(e)})})}},{key:"_routingKeyFor",value:function(e){return this.deviceId()+"."+e}},{key:"_autoAck",value:function(e){if(e)switch((0,u["default"])(E[this._protocol].ackTypes,e)||console.error("Wrong acknowledge type"),e){case"auto":return!0;default:return!1}return!0}}]),n}(b["default"]);t["default"]=x}).call(t,n(3).Buffer)},function(e,t,n){(function(e,r){/*! +!function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={exports:{},id:r,loaded:!1};return e[r].call(i.exports,i,i.exports,t),i.loaded=!0,i.exports}var n={};return t.m=e,t.c=n,t.p="/",t(0)}(function(e){for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t))switch(typeof e[t]){case"function":break;case"object":e[t]=function(t){var n=t.slice(1),r=e[t[0]];return function(e,t,i){r.apply(this,[e,t,i].concat(n))}}(e[t]);break;default:e[t]=e[e[t]]}return e}([function(e,t,n){e.exports=n(1)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.StompStreamClient=t.MqttStreamClient=t.AmqpStreamClient=t.StreamClient=t.StompClient=t.MqttClient=t.AmqpClient=t.Client=void 0;var i=n(2),o=r(i),s=n(295),a=r(s),u=n(339),c=r(u),l=n(347),f=r(l),h=n(348),p=r(h),d=n(349),v=r(d);"undefined"!=typeof window&&(window.StompClient=c["default"],window.StompStreamClient=v["default"]),t.Client=o["default"],t.AmqpClient=o["default"],t.MqttClient=a["default"],t.StompClient=c["default"],t.StreamClient=f["default"],t.AmqpStreamClient=f["default"],t.MqttStreamClient=p["default"],t.StompStreamClient=v["default"]},function(e,t,n){(function(e){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(7),u=r(a),c=function(){function e(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{};return i=(0,f["default"])(this._publishArgs,i),new p["default"](function(o,s){r._createChannel("output",i).then(function(o){var s=new e(r._encapsulateContent(n)),a=[o.checkExchange(r.deviceId()),o.publish(r.deviceId(),r._routingKeyFor(t),s,i)];return i.withConfirm===!0&&a.push(o.waitForConfirms()),v["default"].all(a)}).then(function(e){o(e)})["catch"](function(e){s(e)})})}},{key:"disconnect",value:function(){var e=this;return new p["default"](function(t,n){void 0===e._amqpConnection?n("Not Connected"):e._amqpConnection.close().then(function(){e._amqpConnection=void 0,e._amqpChannels={},e.emit("disconnect"),t(!0)})["catch"](function(e){n(e)})})}},{key:"connect",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=(0,f["default"])(this._connectionOpts,t);return new p["default"](function(t,r){e.getEndpointConfigs().then(function(i){var o=i.connection;if(void 0===e._amqpConnection){var s="";return e._tls?(s=e._tlsProtocol+"://"+(o.deviceId||o.client)+":"+(o.secret+"@"+o.host+":")+(o.protocols.amqp.tlsPort+"/"+o.vhost.replace("/","%2f")),n=(0,f["default"])(n,e._tlsOpts)):s=e._protocol+"://"+(o.deviceId||o.client)+":"+(o.secret+"@"+o.host+":")+(o.protocols.amqp.port+"/"+o.vhost.replace("/","%2f")),y["default"].connect(s,n).then(function(n){n.on("error",function(t){e.emit("error",t),r(t)}),n.on("close",function(t){e.emit("close",t),e._amqpConnection=void 0}),n.on("blocked",function(t){e.emit("blocked",t),console.warn(t)}),n.on("unblocked",function(t){e.emit("unblocked",t),console.warn(t)}),e._amqpConnection=n,e.emit("connect"),t(e._amqpConnection)})["catch"](function(e){r(e)})}t(e._amqpConnection)})["catch"](function(e){r(e)})})}},{key:"isConnected",value:function(){return void 0!==this._amqpConnection}},{key:"_createChannel",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e=""+e+(n.withConfirm===!0?"WithConfirm":""),new p["default"](function(r,i){t._amqpChannels[e]?r(t._amqpChannels[e]):t.connect().then(function(e){return n.withConfirm===!0?e.createConfirmChannel():e.createChannel()}).then(function(n){t._amqpChannels[e]=n,r(n)})["catch"](function(e){i(e)})})}},{key:"_closeChannel",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e=""+e+(n.withConfirm===!0?"WithConfirm":""),new p["default"](function(n,r){var i=t._amqpChannels[e];void 0===i?r("Invalid Channel Object"):i.close().then(function(){t._amqpChannels[e]=void 0,n(!0)})["catch"](function(e){r(e)})})}},{key:"_routingKeyFor",value:function(e){return this.deviceId()+"."+e}},{key:"_autoAck",value:function(e){if(e)switch((0,u["default"])(E[this._protocol].ackTypes,e)||console.error("Wrong acknowledge type"),e){case"auto":return!0;default:return!1}return!0}}]),n}(b["default"]);t["default"]=x}).call(t,n(3).Buffer)},function(e,t,n){(function(e,r){/*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh * @license MIT */ -"use strict";function i(){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(t){return!1}}function o(){return e.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(t,n){if(o()=o())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o().toString(16)+" bytes");return 0|e}function g(t){return+t!=t&&(t=0),e.alloc(+t)}function y(t,n){if(e.isBuffer(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!=typeof t&&(t=""+t);var r=t.length;if(0===r)return 0;for(var i=!1;;)switch(n){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return W(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return G(t).length;default:if(i)return W(t).length;n=(""+n).toLowerCase(),i=!0}}function m(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if(n>>>=0,t>>>=0,n<=t)return"";for(e||(e="utf8");;)switch(e){case"hex":return A(this,t,n);case"utf8":case"utf-8":return j(this,t,n);case"ascii":return B(this,t,n);case"latin1":case"binary":return O(this,t,n);case"base64":return T(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return R(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function b(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function w(t,n,r,i,o){if(0===t.length)return-1;if("string"==typeof r?(i=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=o?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(o)return-1;r=t.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof n&&(n=e.from(n,i)),e.isBuffer(n))return 0===n.length?-1:_(t,n,r,i,o);if("number"==typeof n)return n=255&n,e.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(t,n,r):Uint8Array.prototype.lastIndexOf.call(t,n,r):_(t,[n],r,i,o);throw new TypeError("val must be string, number or Buffer")}function _(e,t,n,r,i){function o(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}var s=1,a=e.length,u=t.length;if(void 0!==r&&(r=String(r).toLowerCase(),"ucs2"===r||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;s=2,a/=2,u/=2,n/=2}var c;if(i){var l=-1;for(c=n;ca&&(n=a-u),c=n;c>=0;c--){for(var f=!0,h=0;hi&&(r=i)):r=i;var o=t.length;if(o%2!==0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var s=0;s239?4:o>223?3:o>191?2:1;if(i+a<=n){var u,c,l,f;switch(a){case 1:o<128&&(s=o);break;case 2:u=e[i+1],128===(192&u)&&(f=(31&o)<<6|63&u,f>127&&(s=f));break;case 3:u=e[i+1],c=e[i+2],128===(192&u)&&128===(192&c)&&(f=(15&o)<<12|(63&u)<<6|63&c,f>2047&&(f<55296||f>57343)&&(s=f));break;case 4:u=e[i+1],c=e[i+2],l=e[i+3],128===(192&u)&&128===(192&c)&&128===(192&l)&&(f=(15&o)<<18|(63&u)<<12|(63&c)<<6|63&l,f>65535&&f<1114112&&(s=f))}}null===s?(s=65533,a=1):s>65535&&(s-=65536,r.push(s>>>10&1023|55296),s=56320|1023&s),r.push(s),i+=a}return U(r)}function U(e){var t=e.length;if(t<=ee)return String.fromCharCode.apply(String,e);for(var n="",r=0;rr)&&(n=r);for(var i="",o=t;on)throw new RangeError("Trying to access beyond buffer length")}function L(t,n,r,i,o,s){if(!e.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(n>o||nt.length)throw new RangeError("Index out of range")}function F(e,t,n,r){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-n,2);i>>8*(r?i:1-i)}function P(e,t,n,r){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-n,4);i>>8*(r?i:3-i)&255}function N(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function D(e,t,n,r,i){return i||N(e,t,n,4,3.4028234663852886e38,-3.4028234663852886e38),J.write(e,t,n,r,23,4),n+4}function q(e,t,n,r,i){return i||N(e,t,n,8,1.7976931348623157e308,-1.7976931348623157e308),J.write(e,t,n,r,52,8),n+8}function z(e){if(e=H(e).replace(te,""),e.length<2)return"";for(;e.length%4!==0;)e+="=";return e}function H(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function Q(e){return e<16?"0"+e.toString(16):e.toString(16)}function W(e,t){t=t||1/0;for(var n,r=e.length,i=null,o=[],s=0;s55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(s+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=(i-55296<<10|n-56320)+65536}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function K(e){for(var t=[],n=0;n>8,i=n%256,o.push(i),o.push(r);return o}function G(e){return X.toByteArray(z(e))}function Y(e,t,n,r){for(var i=0;i=t.length||i>=e.length);++i)t[i+n]=e[i];return i}function $(e){return e!==e}var X=n(4),J=n(5),Z=n(6);t.Buffer=e,t.SlowBuffer=g,t.INSPECT_MAX_BYTES=50,e.TYPED_ARRAY_SUPPORT=void 0!==r.TYPED_ARRAY_SUPPORT?r.TYPED_ARRAY_SUPPORT:i(),t.kMaxLength=o(),e.poolSize=8192,e._augment=function(t){return t.__proto__=e.prototype,t},e.from=function(e,t,n){return a(null,e,t,n)},e.TYPED_ARRAY_SUPPORT&&(e.prototype.__proto__=Uint8Array.prototype,e.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&e[Symbol.species]===e&&Object.defineProperty(e,Symbol.species,{value:null,configurable:!0})),e.alloc=function(e,t,n){return c(null,e,t,n)},e.allocUnsafe=function(e){return l(null,e)},e.allocUnsafeSlow=function(e){return l(null,e)},e.isBuffer=function(e){return!(null==e||!e._isBuffer)},e.compare=function(t,n){if(!e.isBuffer(t)||!e.isBuffer(n))throw new TypeError("Arguments must be Buffers");if(t===n)return 0;for(var r=t.length,i=n.length,o=0,s=Math.min(r,i);o0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),""},e.prototype.compare=function(t,n,r,i,o){if(!e.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===n&&(n=0),void 0===r&&(r=t?t.length:0),void 0===i&&(i=0),void 0===o&&(o=this.length),n<0||r>t.length||i<0||o>this.length)throw new RangeError("out of range index");if(i>=o&&n>=r)return 0;if(i>=o)return-1;if(n>=r)return 1;if(n>>>=0,r>>>=0,i>>>=0,o>>>=0,this===t)return 0;for(var s=o-i,a=r-n,u=Math.min(s,a),c=this.slice(i,o),l=t.slice(n,r),f=0;fi)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return E(this,e,t,n);case"utf8":case"utf-8":return x(this,e,t,n);case"ascii":return k(this,e,t,n);case"latin1":case"binary":return I(this,e,t,n);case"base64":return S(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return C(this,e,t,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},e.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var ee=4096;e.prototype.slice=function(t,n){var r=this.length;t=~~t,n=void 0===n?r:~~n,t<0?(t+=r,t<0&&(t=0)):t>r&&(t=r),n<0?(n+=r,n<0&&(n=0)):n>r&&(n=r),n0&&(i*=256);)r+=this[e+--t]*i;return r},e.prototype.readUInt8=function(e,t){return t||M(e,1,this.length),this[e]},e.prototype.readUInt16LE=function(e,t){return t||M(e,2,this.length),this[e]|this[e+1]<<8},e.prototype.readUInt16BE=function(e,t){return t||M(e,2,this.length),this[e]<<8|this[e+1]},e.prototype.readUInt32LE=function(e,t){return t||M(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},e.prototype.readUInt32BE=function(e,t){return t||M(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},e.prototype.readIntLE=function(e,t,n){e=0|e,t=0|t,n||M(e,t,this.length);for(var r=this[e],i=1,o=0;++o=i&&(r-=Math.pow(2,8*t)),r},e.prototype.readIntBE=function(e,t,n){e=0|e,t=0|t,n||M(e,t,this.length);for(var r=t,i=1,o=this[e+--r];r>0&&(i*=256);)o+=this[e+--r]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*t)),o},e.prototype.readInt8=function(e,t){return t||M(e,1,this.length),128&this[e]?(255-this[e]+1)*-1:this[e]},e.prototype.readInt16LE=function(e,t){t||M(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},e.prototype.readInt16BE=function(e,t){t||M(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},e.prototype.readInt32LE=function(e,t){return t||M(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},e.prototype.readInt32BE=function(e,t){return t||M(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},e.prototype.readFloatLE=function(e,t){return t||M(e,4,this.length),J.read(this,e,!0,23,4)},e.prototype.readFloatBE=function(e,t){return t||M(e,4,this.length),J.read(this,e,!1,23,4)},e.prototype.readDoubleLE=function(e,t){return t||M(e,8,this.length),J.read(this,e,!0,52,8)},e.prototype.readDoubleBE=function(e,t){return t||M(e,8,this.length),J.read(this,e,!1,52,8)},e.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t=0|t,n=0|n,!r){var i=Math.pow(2,8*n)-1;L(this,e,t,n,i,0)}var o=1,s=0;for(this[t]=255&e;++s=0&&(s*=256);)this[t+o]=e/s&255;return t+n},e.prototype.writeUInt8=function(t,n,r){return t=+t,n=0|n,r||L(this,t,n,1,255,0),e.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[n]=255&t,n+1},e.prototype.writeUInt16LE=function(t,n,r){return t=+t,n=0|n,r||L(this,t,n,2,65535,0),e.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8):F(this,t,n,!0),n+2},e.prototype.writeUInt16BE=function(t,n,r){return t=+t,n=0|n,r||L(this,t,n,2,65535,0),e.TYPED_ARRAY_SUPPORT?(this[n]=t>>>8,this[n+1]=255&t):F(this,t,n,!1),n+2},e.prototype.writeUInt32LE=function(t,n,r){return t=+t,n=0|n,r||L(this,t,n,4,4294967295,0),e.TYPED_ARRAY_SUPPORT?(this[n+3]=t>>>24,this[n+2]=t>>>16,this[n+1]=t>>>8,this[n]=255&t):P(this,t,n,!0),n+4},e.prototype.writeUInt32BE=function(t,n,r){return t=+t,n=0|n,r||L(this,t,n,4,4294967295,0),e.TYPED_ARRAY_SUPPORT?(this[n]=t>>>24,this[n+1]=t>>>16,this[n+2]=t>>>8,this[n+3]=255&t):P(this,t,n,!1),n+4},e.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t=0|t,!r){var i=Math.pow(2,8*n-1);L(this,e,t,n,i-1,-i)}var o=0,s=1,a=0;for(this[t]=255&e;++o>0)-a&255;return t+n},e.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t=0|t,!r){var i=Math.pow(2,8*n-1);L(this,e,t,n,i-1,-i)}var o=n-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+n},e.prototype.writeInt8=function(t,n,r){return t=+t,n=0|n,r||L(this,t,n,1,127,-128),e.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[n]=255&t,n+1},e.prototype.writeInt16LE=function(t,n,r){return t=+t,n=0|n,r||L(this,t,n,2,32767,-32768),e.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8):F(this,t,n,!0),n+2},e.prototype.writeInt16BE=function(t,n,r){return t=+t,n=0|n,r||L(this,t,n,2,32767,-32768),e.TYPED_ARRAY_SUPPORT?(this[n]=t>>>8,this[n+1]=255&t):F(this,t,n,!1),n+2},e.prototype.writeInt32LE=function(t,n,r){return t=+t,n=0|n,r||L(this,t,n,4,2147483647,-2147483648),e.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8,this[n+2]=t>>>16,this[n+3]=t>>>24):P(this,t,n,!0),n+4},e.prototype.writeInt32BE=function(t,n,r){return t=+t,n=0|n,r||L(this,t,n,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),e.TYPED_ARRAY_SUPPORT?(this[n]=t>>>24,this[n+1]=t>>>16,this[n+2]=t>>>8,this[n+3]=255&t):P(this,t,n,!1),n+4},e.prototype.writeFloatLE=function(e,t,n){return D(this,e,t,!0,n)},e.prototype.writeFloatBE=function(e,t,n){return D(this,e,t,!1,n)},e.prototype.writeDoubleLE=function(e,t,n){return q(this,e,t,!0,n)},e.prototype.writeDoubleBE=function(e,t,n){return q(this,e,t,!1,n)},e.prototype.copy=function(t,n,r,i){if(r||(r=0),i||0===i||(i=this.length),n>=t.length&&(n=t.length),n||(n=0),i>0&&i=this.length)throw new RangeError("sourceStart out of bounds");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),t.length-n=0;--o)t[o+n]=this[o+r];else if(s<1e3||!e.TYPED_ARRAY_SUPPORT)for(o=0;o>>=0,r=void 0===r?this.length:r>>>0,t||(t=0);var s;if("number"==typeof t)for(s=n;s0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");n===-1&&(n=t);var r=n===t?0:4-n%4;return[n,r]}function r(e){var t=n(e),r=t[0],i=t[1];return 3*(r+i)/4-i}function i(e,t,n){return 3*(t+n)/4-n}function o(e){for(var t,r=n(e),o=r[0],s=r[1],a=new f(i(e,o,s)),u=0,c=s>0?o-4:o,h=0;h>16&255,a[u++]=t>>8&255,a[u++]=255&t;return 2===s&&(t=l[e.charCodeAt(h)]<<2|l[e.charCodeAt(h+1)]>>4,a[u++]=255&t),1===s&&(t=l[e.charCodeAt(h)]<<10|l[e.charCodeAt(h+1)]<<4|l[e.charCodeAt(h+2)]>>2,a[u++]=t>>8&255,a[u++]=255&t),a}function s(e){return c[e>>18&63]+c[e>>12&63]+c[e>>6&63]+c[63&e]}function a(e,t,n){for(var r,i=[],o=t;ou?u:s+o));return 1===r?(t=e[n-1],i.push(c[t>>2]+c[t<<4&63]+"==")):2===r&&(t=(e[n-2]<<8)+e[n-1],i.push(c[t>>10]+c[t>>4&63]+c[t<<2&63]+"=")),i.join("")}t.byteLength=r,t.toByteArray=o,t.fromByteArray=u;for(var c=[],l=[],f="undefined"!=typeof Uint8Array?Uint8Array:Array,h="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",p=0,d=h.length;p>1,l=-7,f=n?i-1:0,h=n?-1:1,p=e[t+f];for(f+=h,o=p&(1<<-l)-1,p>>=-l,l+=a;l>0;o=256*o+e[t+f],f+=h,l-=8);for(s=o&(1<<-l)-1,o>>=-l,l+=r;l>0;s=256*s+e[t+f],f+=h,l-=8);if(0===o)o=1-c;else{if(o===u)return s?NaN:(p?-1:1)*(1/0);s+=Math.pow(2,r),o-=c}return(p?-1:1)*s*Math.pow(2,o-r)},t.write=function(e,t,n,r,i,o){var s,a,u,c=8*o-i-1,l=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:o-1,d=r?1:-1,v=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,s=l):(s=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-s))<1&&(s--,u*=2),t+=s+f>=1?h/u:h*Math.pow(2,1-f),t*u>=2&&(s++,u/=2),s+f>=l?(a=0,s=l):s+f>=1?(a=(t*u-1)*Math.pow(2,i),s+=f):(a=t*Math.pow(2,f-1)*Math.pow(2,i),s=0));i>=8;e[n+p]=255&a,p+=d,a/=256,i-=8);for(s=s<0;e[n+p]=255&s,p+=d,s/=256,c-=8);e[n+p-d]|=128*v}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){function r(e,t,n,r){e=o(e)?e:u(e),n=n&&!r?a(n):0;var l=e.length;return n<0&&(n=c(l+n,0)),s(e)?n<=l&&e.indexOf(t,n)>-1:!!l&&i(e,t,n)>-1}var i=n(8),o=n(10),s=n(16),a=n(19),u=n(22),c=Math.max;e.exports=r},function(e,t,n){function r(e,t,n){if(t!==t)return i(e,n);for(var r=n-1,o=e.length;++r-1&&e%1==0&&e<=r}var r=9007199254740991;e.exports=n},function(e,t,n){function r(e){return"string"==typeof e||!i(e)&&o(e)&&u.call(e)==s}var i=n(17),o=n(18),s="[object String]",a=Object.prototype,u=a.toString;e.exports=r},function(e,t){var n=Array.isArray;e.exports=n},function(e,t){function n(e){return!!e&&"object"==typeof e}e.exports=n},function(e,t,n){function r(e){if(!e)return 0===e?e:0;if(e=i(e),e===o||e===-o){var t=e<0?-1:1;return t*s}var n=e%1;return e===e?n?e-n:e:0}var i=n(20),o=1/0,s=1.7976931348623157e308;e.exports=r},function(e,t,n){function r(e){if("number"==typeof e)return e;if(s(e))return a;if(o(e)){var t=i(e.valueOf)?e.valueOf():e;e=o(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(u,"");var n=l.test(e);return n||f.test(e)?h(e.slice(2),n?2:8):c.test(e)?a:+e}var i=n(13),o=n(14),s=n(21),a=NaN,u=/^\s+|\s+$/g,c=/^[-+]0x[0-9a-f]+$/i,l=/^0b[01]+$/i,f=/^0o[0-7]+$/i,h=parseInt;e.exports=r},function(e,t,n){function r(e){return"symbol"==typeof e||i(e)&&a.call(e)==o}var i=n(18),o="[object Symbol]",s=Object.prototype,a=s.toString;e.exports=r},function(e,t,n){function r(e){return e?i(e,o(e)):[]}var i=n(23),o=n(25);e.exports=r},function(e,t,n){function r(e,t){return i(t,function(t){return e[t]})}var i=n(24);e.exports=r},function(e,t){function n(e,t){for(var n=-1,r=e.length,i=Array(r);++n-1&&e%1==0&&e0;){var t=e.shift();if("function"==typeof t){var n=e.shift(),r=e.shift();t.call(n,r)}else t._settlePromises()}},i.prototype._drainQueues=function(){this._drainQueue(this._normalQueue),this._reset(),this._haveDrainedQueues=!0,this._drainQueue(this._lateQueue)},i.prototype._queueTick=function(){this._isTickUsed||(this._isTickUsed=!0,this._schedule(this.drainQueues))},i.prototype._reset=function(){this._isTickUsed=!1},n.exports=i,n.exports.firstLineError=u},{"./queue":26,"./schedule":29,"./util":36}],3:[function(e,t,n){"use strict";t.exports=function(e,t,n,r){var i=!1,o=function(e,t){this._reject(t)},s=function(e,t){t.promiseRejectionQueued=!0,t.bindingPromise._then(o,o,null,this,e)},a=function(e,t){0===(50397184&this._bitField)&&this._resolveCallback(t.target)},u=function(e,t){t.promiseRejectionQueued||this._reject(e)};e.prototype.bind=function(o){i||(i=!0,e.prototype._propagateFrom=r.propagateFromFunction(),e.prototype._boundValue=r.boundValueFunction());var c=n(o),l=new e(t);l._propagateFrom(this,1);var f=this._target();if(l._setBoundTo(c),c instanceof e){var h={promiseRejectionQueued:!1,promise:l,target:f,bindingPromise:c};f._then(t,s,void 0,l,h),c._then(a,u,void 0,l,h),l._setOnCancel(c)}else l._resolveCallback(f);return l},e.prototype._setBoundTo=function(e){void 0!==e?(this._bitField=2097152|this._bitField,this._boundTo=e):this._bitField=this._bitField&-2097153},e.prototype._isBound=function(){return 2097152===(2097152&this._bitField)},e.bind=function(t,n){return e.resolve(n).bind(t)}}},{}],4:[function(e,t,n){"use strict";function r(){try{Promise===o&&(Promise=i)}catch(e){}return o}var i;"undefined"!=typeof Promise&&(i=Promise);var o=e("./promise")();o.noConflict=r,t.exports=o},{"./promise":22}],5:[function(e,t,n){"use strict";var r=Object.create;if(r){var i=r(null),o=r(null);i[" size"]=o[" size"]=0}t.exports=function(t){function n(e,n){var r;if(null!=e&&(r=e[n]),"function"!=typeof r){var i="Object "+a.classString(e)+" has no method '"+a.toString(n)+"'";throw new t.TypeError(i)}return r}function r(e){var t=this.pop(),r=n(e,t);return r.apply(e,this)}function i(e){return e[this]}function o(e){var t=+this;return t<0&&(t=Math.max(0,t+e.length)),e[t]}var s,a=e("./util"),u=a.canEvaluate;a.isIdentifier;t.prototype.call=function(e){var t=[].slice.call(arguments,1);return t.push(e),this._then(r,void 0,void 0,t,void 0)},t.prototype.get=function(e){var t,n="number"==typeof e;if(n)t=o;else if(u){var r=s(e);t=null!==r?r:i}else t=i;return this._then(t,void 0,void 0,e,void 0)}}},{"./util":36}],6:[function(e,t,n){"use strict";t.exports=function(t,n,r,i){var o=e("./util"),s=o.tryCatch,a=o.errorObj,u=t._async;t.prototype["break"]=t.prototype.cancel=function(){if(!i.cancellation())return this._warn("cancellation is disabled");for(var e=this,t=e;e.isCancellable();){if(!e._cancelBy(t)){t._isFollowing()?t._followee().cancel():t._cancelBranched();break}var n=e._cancellationParent;if(null==n||!n.isCancellable()){e._isFollowing()?e._followee().cancel():e._cancelBranched();break}e._isFollowing()&&e._followee().cancel(),t=e,e=n}},t.prototype._branchHasCancelled=function(){this._branchesRemainingToCancel--},t.prototype._enoughBranchesHaveCancelled=function(){return void 0===this._branchesRemainingToCancel||this._branchesRemainingToCancel<=0},t.prototype._cancelBy=function(e){return e===this?(this._branchesRemainingToCancel=0,this._invokeOnCancel(),!0):(this._branchHasCancelled(),!!this._enoughBranchesHaveCancelled()&&(this._invokeOnCancel(),!0))},t.prototype._cancelBranched=function(){this._enoughBranchesHaveCancelled()&&this._cancel()},t.prototype._cancel=function(){this.isCancellable()&&(this._setCancelled(),u.invoke(this._cancelPromises,this,void 0))},t.prototype._cancelPromises=function(){this._length()>0&&this._settlePromises()},t.prototype._unsetOnCancel=function(){this._onCancelField=void 0},t.prototype.isCancellable=function(){return this.isPending()&&!this.isCancelled()},t.prototype._doInvokeOnCancel=function(e,t){if(o.isArray(e))for(var n=0;n=0)return o[e]}var i=!1,o=[];return e.prototype._promiseCreated=function(){},e.prototype._pushContext=function(){},e.prototype._popContext=function(){return null},e._peekContext=e.prototype._peekContext=function(){},t.prototype._pushContext=function(){void 0!==this._trace&&(this._trace._promiseCreated=null,o.push(this._trace))},t.prototype._popContext=function(){if(void 0!==this._trace){var e=o.pop(),t=e._promiseCreated;return e._promiseCreated=null,t}return null},t.CapturedTrace=null,t.create=n,t.deactivateLongStackTraces=function(){},t.activateLongStackTraces=function(){var n=e.prototype._pushContext,o=e.prototype._popContext,s=e._peekContext,a=e.prototype._peekContext,u=e.prototype._promiseCreated;t.deactivateLongStackTraces=function(){e.prototype._pushContext=n,e.prototype._popContext=o,e._peekContext=s,e.prototype._peekContext=a,e.prototype._promiseCreated=u,i=!1},i=!0,e.prototype._pushContext=t.prototype._pushContext,e.prototype._popContext=t.prototype._popContext,e._peekContext=e.prototype._peekContext=r,e.prototype._promiseCreated=function(){var e=this._peekContext();e&&null==e._promiseCreated&&(e._promiseCreated=this)}},t}},{}],9:[function(e,n,r){"use strict";n.exports=function(n,r){function i(e,t){return{promise:t}}function o(){return!1}function s(e,t,n){var r=this;try{e(t,n,function(e){if("function"!=typeof e)throw new TypeError("onCancel must be a function, got: "+N.toString(e));r._attachCancellationCallback(e)})}catch(i){return i}}function a(e){if(!this.isCancellable())return this;var t=this._onCancel();void 0!==t?N.isArray(t)?t.push(e):this._setOnCancel([t,e]):this._setOnCancel(e)}function u(){return this._onCancelField}function c(e){this._onCancelField=e}function l(){this._cancellationParent=void 0,this._onCancelField=void 0}function f(e,t){if(0!==(1&t)){this._cancellationParent=e;var n=e._branchesRemainingToCancel;void 0===n&&(n=0),e._branchesRemainingToCancel=n+1}0!==(2&t)&&e._isBound()&&this._setBoundTo(e._boundTo)}function h(e,t){0!==(2&t)&&e._isBound()&&this._setBoundTo(e._boundTo)}function p(){var e=this._boundTo;return void 0!==e&&e instanceof n?e.isFulfilled()?e.value():void 0:e}function d(){this._trace=new O(this._peekContext())}function v(e,t){if(D(e)){var n=this._trace;if(void 0!==n&&t&&(n=n._parent),void 0!==n)n.attachExtraTrace(e);else if(!e.__stackCleaned__){var r=k(e);N.notEnumerableProp(e,"stack",r.message+"\n"+r.stack.join("\n")),N.notEnumerableProp(e,"__stackCleaned__",!0)}}}function g(e,t,n,r,i){if(void 0===e&&null!==t&&G){if(void 0!==i&&i._returnedNonUndefined())return;if(0===(65535&r._bitField))return;n&&(n+=" ");var o="a promise was created in a "+n+"handler but was not returned from it";r._warn(o,!0,t)}}function y(e,t){var n=e+" is deprecated and will be removed in a future version.";return t&&(n+=" Use "+t+" instead."),m(n)}function m(e,t,r){if(ie.warnings){var i,o=new P(e);if(t)r._attachExtraTrace(o);else if(ie.longStackTraces&&(i=n._peekContext()))i.attachExtraTrace(o);else{var s=k(o);o.stack=s.message+"\n"+s.stack.join("\n")}Z("warning",o)||I(o,"",!0)}}function b(e,t){for(var n=0;n=0;--a)if(r[a]===o){s=a;break}for(var a=s;a>=0;--a){var u=r[a];if(t[i]!==u)break;t.pop(),i--}t=r}}function E(e){for(var t=[],n=0;n0&&(t=t.slice(n)),t}function k(e){var t=e.stack,n=e.toString();return t="string"==typeof t&&t.length>0?x(e):[" (No stack trace)"],{message:n,stack:E(t)}}function I(e,t,n){if("undefined"!=typeof console){var r;if(N.isObject(e)){var i=e.stack;r=t+H(i,e)}else r=t+String(e);"function"==typeof M?M(r,n):"function"!=typeof console.log&&"object"!=typeof console.log||console.log(r)}}function S(e,t,n,r){var i=!1;try{"function"==typeof t&&(i=!0,"rejectionHandled"===e?t(r):t(n,r))}catch(o){F.throwLater(o)}"unhandledRejection"===e?Z(e,n,r)||i||I(n,"Unhandled rejection "):Z(e,r)}function C(e){var t;if("function"==typeof e)t="[function "+(e.name||"anonymous")+"]";else{t=e&&"function"==typeof e.toString?e.toString():N.toString(e);var n=/\[object [a-zA-Z0-9$_]+\]/;if(n.test(t))try{var r=JSON.stringify(e);t=r}catch(i){}0===t.length&&(t="(empty array)")}return"(<"+T(t)+">, no stack trace)"}function T(e){var t=41;return e.length=a||(te=function(e){if(q.test(e))return!0;var t=U(e);return!!(t&&t.fileName===n&&s<=t.line&&t.line<=a)})}}function O(e){this._parent=e,this._promisesCreated=0;var t=this._length=1+(void 0===e?0:e._length);re(this,O),t>32&&this.uncycle()}var A,R,M,L=n._getDomain,F=n._async,P=e("./errors").Warning,N=e("./util"),D=N.canAttachTrace,q=/[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/,z=null,H=null,Q=!1,W=!(0==N.env("BLUEBIRD_DEBUG")),K=!(0==N.env("BLUEBIRD_WARNINGS")||!W&&!N.env("BLUEBIRD_WARNINGS")),V=!(0==N.env("BLUEBIRD_LONG_STACK_TRACES")||!W&&!N.env("BLUEBIRD_LONG_STACK_TRACES")),G=0!=N.env("BLUEBIRD_W_FORGOTTEN_RETURN")&&(K||!!N.env("BLUEBIRD_W_FORGOTTEN_RETURN"));n.prototype.suppressUnhandledRejections=function(){var e=this._target();e._bitField=e._bitField&-1048577|524288},n.prototype._ensurePossibleRejectionHandled=function(){0===(524288&this._bitField)&&(this._setRejectionIsUnhandled(),F.invokeLater(this._notifyUnhandledRejection,this,void 0))},n.prototype._notifyUnhandledRejectionIsHandled=function(){S("rejectionHandled",A,void 0,this)},n.prototype._setReturnedNonUndefined=function(){this._bitField=268435456|this._bitField},n.prototype._returnedNonUndefined=function(){return 0!==(268435456&this._bitField)},n.prototype._notifyUnhandledRejection=function(){if(this._isRejectionUnhandled()){var e=this._settledValue();this._setUnhandledRejectionIsNotified(),S("unhandledRejection",R,e,this)}},n.prototype._setUnhandledRejectionIsNotified=function(){this._bitField=262144|this._bitField},n.prototype._unsetUnhandledRejectionIsNotified=function(){this._bitField=this._bitField&-262145},n.prototype._isUnhandledRejectionNotified=function(){return(262144&this._bitField)>0},n.prototype._setRejectionIsUnhandled=function(){this._bitField=1048576|this._bitField},n.prototype._unsetRejectionIsUnhandled=function(){this._bitField=this._bitField&-1048577,this._isUnhandledRejectionNotified()&&(this._unsetUnhandledRejectionIsNotified(),this._notifyUnhandledRejectionIsHandled())},n.prototype._isRejectionUnhandled=function(){return(1048576&this._bitField)>0},n.prototype._warn=function(e,t,n){return m(e,t,n||this)},n.onPossiblyUnhandledRejection=function(e){var t=L();R="function"==typeof e?null===t?e:t.bind(e):void 0},n.onUnhandledRejectionHandled=function(e){var t=L();A="function"==typeof e?null===t?e:t.bind(e):void 0};var Y=function(){};n.longStackTraces=function(){if(F.haveItemsQueued()&&!ie.longStackTraces)throw new Error("cannot enable long stack traces after promises have been created\n\n See http://goo.gl/MqrFmX\n");if(!ie.longStackTraces&&j()){var e=n.prototype._captureStackTrace,t=n.prototype._attachExtraTrace;ie.longStackTraces=!0,Y=function(){if(F.haveItemsQueued()&&!ie.longStackTraces)throw new Error("cannot enable long stack traces after promises have been created\n\n See http://goo.gl/MqrFmX\n");n.prototype._captureStackTrace=e,n.prototype._attachExtraTrace=t,r.deactivateLongStackTraces(),F.enableTrampoline(),ie.longStackTraces=!1},n.prototype._captureStackTrace=d,n.prototype._attachExtraTrace=v,r.activateLongStackTraces(),F.disableTrampolineIfNecessary()}},n.hasLongStackTraces=function(){return ie.longStackTraces&&j()};var $=function(){try{var e=document.createEvent("CustomEvent");return e.initCustomEvent("testingtheevent",!1,!0,{}),N.global.dispatchEvent(e),function(e,t){var n=document.createEvent("CustomEvent");return n.initCustomEvent(e.toLowerCase(),!1,!0,t),!N.global.dispatchEvent(n)}}catch(t){}return function(){return!1}}(),X=function(){return N.isNode?function(){return t.emit.apply(t,arguments)}:N.global?function(e){var t="on"+e.toLowerCase(),n=N.global[t];return!!n&&(n.apply(N.global,[].slice.call(arguments,1)),!0)}:function(){return!1}}(),J={promiseCreated:i,promiseFulfilled:i,promiseRejected:i,promiseResolved:i,promiseCancelled:i,promiseChained:function(e,t,n){return{promise:t,child:n}},warning:function(e,t){return{warning:t}},unhandledRejection:function(e,t,n){return{reason:t,promise:n}},rejectionHandled:i},Z=function(e){var t=!1;try{t=X.apply(null,arguments)}catch(n){F.throwLater(n),t=!0}var r=!1;try{r=$(e,J[e].apply(null,arguments))}catch(n){F.throwLater(n),r=!0}return r||t};n.config=function(e){if(e=Object(e),"longStackTraces"in e&&(e.longStackTraces?n.longStackTraces():!e.longStackTraces&&n.hasLongStackTraces()&&Y()),"warnings"in e){var t=e.warnings;ie.warnings=!!t,G=ie.warnings,N.isObject(t)&&"wForgottenReturn"in t&&(G=!!t.wForgottenReturn)}if("cancellation"in e&&e.cancellation&&!ie.cancellation){if(F.haveItemsQueued())throw new Error("cannot enable cancellation after promises are in use");n.prototype._clearCancellationData=l,n.prototype._propagateFrom=f,n.prototype._onCancel=u,n.prototype._setOnCancel=c,n.prototype._attachCancellationCallback=a,n.prototype._execute=s,ee=f,ie.cancellation=!0}"monitoring"in e&&(e.monitoring&&!ie.monitoring?(ie.monitoring=!0,n.prototype._fireEvent=Z):!e.monitoring&&ie.monitoring&&(ie.monitoring=!1,n.prototype._fireEvent=o))},n.prototype._fireEvent=o,n.prototype._execute=function(e,t,n){try{e(t,n)}catch(r){return r}},n.prototype._onCancel=function(){},n.prototype._setOnCancel=function(e){},n.prototype._attachCancellationCallback=function(e){},n.prototype._captureStackTrace=function(){},n.prototype._attachExtraTrace=function(){},n.prototype._clearCancellationData=function(){},n.prototype._propagateFrom=function(e,t){};var ee=h,te=function(){return!1},ne=/[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/;N.inherits(O,Error),r.CapturedTrace=O,O.prototype.uncycle=function(){var e=this._length;if(!(e<2)){for(var t=[],n={},r=0,i=this;void 0!==i;++r)t.push(i),i=i._parent;e=this._length=r;for(var r=e-1;r>=0;--r){var o=t[r].stack;void 0===n[o]&&(n[o]=r)}for(var r=0;r0&&(t[a-1]._parent=void 0,t[a-1]._length=1),t[r]._parent=void 0,t[r]._length=1;var u=r>0?t[r-1]:this;a=0;--l)t[l]._length=c,c++;return}}}},O.prototype.attachExtraTrace=function(e){if(!e.__stackCleaned__){this.uncycle();for(var t=k(e),n=t.message,r=[t.stack],i=this;void 0!==i;)r.push(E(i.stack.split("\n"))),i=i._parent;_(r),w(r),N.notEnumerableProp(e,"stack",b(n,r)),N.notEnumerableProp(e,"__stackCleaned__",!0)}};var re=function(){var e=/^\s*at\s*/,t=function(e,t){return"string"==typeof e?e:void 0!==t.name&&void 0!==t.message?t.toString():C(t)};if("number"==typeof Error.stackTraceLimit&&"function"==typeof Error.captureStackTrace){Error.stackTraceLimit+=6,z=e,H=t;var n=Error.captureStackTrace;return te=function(e){return q.test(e)},function(e,t){Error.stackTraceLimit+=6,n(e,t),Error.stackTraceLimit-=6}}var r=new Error;if("string"==typeof r.stack&&r.stack.split("\n")[0].indexOf("stackDetection@")>=0)return z=/@/,H=t,Q=!0,function(e){e.stack=(new Error).stack};var i;try{throw new Error}catch(o){i="stack"in o}return"stack"in r||!i||"number"!=typeof Error.stackTraceLimit?(H=function(e,t){return"string"==typeof e?e:"object"!=typeof t&&"function"!=typeof t||void 0===t.name||void 0===t.message?C(t):t.toString()},null):(z=e,H=t,function(e){Error.stackTraceLimit+=6;try{throw new Error}catch(t){e.stack=t.stack}Error.stackTraceLimit-=6})}([]);"undefined"!=typeof console&&"undefined"!=typeof console.warn&&(M=function(e){console.warn(e)},N.isNode&&t.stderr.isTTY?M=function(e,t){var n=t?"":"";console.warn(n+e+"\n")}:N.isNode||"string"!=typeof(new Error).stack||(M=function(e,t){console.warn("%c"+e,t?"color: darkorange":"color: red")}));var ie={warnings:K,longStackTraces:!1,cancellation:!1,monitoring:!1};return V&&n.longStackTraces(),{longStackTraces:function(){return ie.longStackTraces},warnings:function(){return ie.warnings},cancellation:function(){return ie.cancellation},monitoring:function(){return ie.monitoring},propagateFromFunction:function(){return ee},boundValueFunction:function(){return p},checkForgottenReturns:g,setBounds:B,warn:m,deprecated:y,CapturedTrace:O,fireDomEvent:$,fireGlobalEvent:X}}},{"./errors":12,"./util":36}],10:[function(e,t,n){"use strict";t.exports=function(e){function t(){return this.value}function n(){throw this.reason}e.prototype["return"]=e.prototype.thenReturn=function(n){return n instanceof e&&n.suppressUnhandledRejections(),this._then(t,void 0,void 0,{value:n},void 0)},e.prototype["throw"]=e.prototype.thenThrow=function(e){return this._then(n,void 0,void 0,{reason:e},void 0)},e.prototype.catchThrow=function(e){if(arguments.length<=1)return this._then(void 0,n,void 0,{reason:e},void 0);var t=arguments[1],r=function(){throw t};return this.caught(e,r)},e.prototype.catchReturn=function(n){if(arguments.length<=1)return n instanceof e&&n.suppressUnhandledRejections(),this._then(void 0,t,void 0,{value:n},void 0);var r=arguments[1];r instanceof e&&r.suppressUnhandledRejections();var i=function(){return r};return this.caught(n,i)}}},{}],11:[function(e,t,n){"use strict";t.exports=function(e,t){function n(){return o(this)}function r(e,n){return i(e,n,t,t)}var i=e.reduce,o=e.all;e.prototype.each=function(e){return this.mapSeries(e)._then(n,void 0,void 0,this,void 0)},e.prototype.mapSeries=function(e){return i(this,e,t,t)},e.each=function(e,t){return r(e,t)._then(n,void 0,void 0,e,void 0)},e.mapSeries=r}},{}],12:[function(e,t,n){"use strict";function r(e,t){function n(r){return this instanceof n?(f(this,"message","string"==typeof r?r:t),f(this,"name",e),void(Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):Error.call(this))):new n(r)}return l(n,Error),n}function i(e){return this instanceof i?(f(this,"name","OperationalError"),f(this,"message",e),this.cause=e,this.isOperational=!0,void(e instanceof Error?(f(this,"message",e.message),f(this,"stack",e.stack)):Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor))):new i(e)}var o,s,a=e("./es5"),u=a.freeze,c=e("./util"),l=c.inherits,f=c.notEnumerableProp,h=r("Warning","warning"),p=r("CancellationError","cancellation error"),d=r("TimeoutError","timeout error"),v=r("AggregateError","aggregate error");try{o=TypeError,s=RangeError}catch(g){o=r("TypeError","type error"),s=r("RangeError","range error")}for(var y="join pop push shift unshift slice filter forEach some every map indexOf lastIndexOf reduce reduceRight sort reverse".split(" "),m=0;m1?e.cancelPromise._reject(t):e.cancelPromise._cancel(),e.cancelPromise=null,!0)}function s(){return u.call(this,this.promise._target()._settledValue())}function a(e){if(!o(this,e))return f.e=e,f}function u(e){var r=this.promise,u=this.handler;if(!this.called){this.called=!0;var c=this.isFinallyHandler()?u.call(r._boundValue()):u.call(r._boundValue(),e);if(void 0!==c){r._setReturnedNonUndefined();var h=n(c,r);if(h instanceof t){if(null!=this.cancelPromise){if(h.isCancelled()){var p=new l("late cancellation observer");return r._attachExtraTrace(p),f.e=p,f}h.isPending()&&h._attachCancellationCallback(new i(this))}return h._then(s,a,void 0,this,void 0)}}}return r.isRejected()?(o(this),f.e=e,f):(o(this),e)}var c=e("./util"),l=t.CancellationError,f=c.errorObj;return r.prototype.isFinallyHandler=function(){return 0===this.type},i.prototype._resultCancelled=function(){o(this.finallyHandler)},t.prototype._passThrough=function(e,t,n,i){return"function"!=typeof e?this.then():this._then(n,i,void 0,new r(this,t,e),void 0)},t.prototype.lastly=t.prototype["finally"]=function(e){return this._passThrough(e,0,u,u)},t.prototype.tap=function(e){return this._passThrough(e,1,u)},r}},{"./util":36}],16:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o,s){function a(e,n,r){for(var o=0;o0&&"function"==typeof arguments[t]){e=arguments[t];var r}var i=[].slice.call(arguments);e&&i.pop();var r=new n(i).promise();return void 0!==e?r.spread(e):r}}},{"./util":36}],18:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o,s){function a(e,t,n,r){this.constructor$(e),this._promise._captureStackTrace();var i=c();this._callback=null===i?t:i.bind(t),this._preservedValues=r===o?new Array(this.length()):null,this._limit=n,this._inFlight=0,this._queue=n>=1?[]:p,this._init$(void 0,-2)}function u(e,t,n,i){if("function"!=typeof t)return r("expecting a function but got "+l.classString(t));var o="object"==typeof n&&null!==n?n.concurrency:0;return o="number"==typeof o&&isFinite(o)&&o>=1?o:0,new a(e,t,o,i).promise(); -}var c=t._getDomain,l=e("./util"),f=l.tryCatch,h=l.errorObj,p=[];l.inherits(a,n),a.prototype._init=function(){},a.prototype._promiseFulfilled=function(e,n){var r=this._values,o=this.length(),a=this._preservedValues,u=this._limit;if(n<0){if(n=n*-1-1,r[n]=e,u>=1&&(this._inFlight--,this._drainQueue(),this._isResolved()))return!0}else{if(u>=1&&this._inFlight>=u)return r[n]=e,this._queue.push(n),!1;null!==a&&(a[n]=e);var c=this._promise,l=this._callback,p=c._boundValue();c._pushContext();var d=f(l).call(p,e,n,o),v=c._popContext();if(s.checkForgottenReturns(d,v,null!==a?"Promise.filter":"Promise.map",c),d===h)return this._reject(d.e),!0;var g=i(d,this._promise);if(g instanceof t){g=g._target();var y=g._bitField;if(0===(50397184&y))return u>=1&&this._inFlight++,r[n]=g,g._proxy(this,(n+1)*-1),!1;if(0===(33554432&y))return 0!==(16777216&y)?(this._reject(g._reason()),!0):(this._cancel(),!0);d=g._value()}r[n]=d}var m=++this._totalResolved;return m>=o&&(null!==a?this._filter(r,a):this._resolve(r),!0)},a.prototype._drainQueue=function(){for(var e=this._queue,t=this._limit,n=this._values;e.length>0&&this._inFlight1){o.deprecated("calling Promise.try with more than 1 argument");var c=arguments[1],l=arguments[2];u=s.isArray(c)?a(e).apply(l,c):a(e).call(l,c)}else u=a(e)();var f=r._popContext();return o.checkForgottenReturns(u,f,"Promise.try",r),r._resolveFromSyncValue(u),r},t.prototype._resolveFromSyncValue=function(e){e===s.errorObj?this._rejectCallback(e.e,!1):this._resolveCallback(e,!0)}}},{"./util":36}],20:[function(e,t,n){"use strict";function r(e){return e instanceof Error&&l.getPrototypeOf(e)===Error.prototype}function i(e){var t;if(r(e)){t=new c(e),t.name=e.name,t.message=e.message,t.stack=e.stack;for(var n=l.keys(e),i=0;i1){var n,r=new Array(t-1),i=0;for(n=0;n0&&"function"!=typeof e&&"function"!=typeof t){var n=".then() only accepts functions but was passed: "+p.classString(e);arguments.length>1&&(n+=", "+p.classString(t)),this._warn(n)}return this._then(e,t,void 0,void 0,void 0)},i.prototype.done=function(e,t){var n=this._then(e,t,void 0,void 0,void 0);n._setIsFinal()},i.prototype.spread=function(e){return"function"!=typeof e?f("expecting a function but got "+p.classString(e)):this.all()._then(e,void 0,void 0,_,void 0)},i.prototype.toJSON=function(){var e={isFulfilled:!1,isRejected:!1,fulfillmentValue:void 0,rejectionReason:void 0};return this.isFulfilled()?(e.fulfillmentValue=this.value(),e.isFulfilled=!0):this.isRejected()&&(e.rejectionReason=this.reason(),e.isRejected=!0),e},i.prototype.all=function(){return arguments.length>0&&this._warn(".all() was passed arguments but it does not take any"),new k(this).promise()},i.prototype.error=function(e){return this.caught(p.originatesFromRejection,e)},i.is=function(e){return e instanceof i},i.fromNode=i.fromCallback=function(e){var t=new i(w);t._captureStackTrace();var n=arguments.length>1&&!!Object(arguments[1]).multiArgs,r=O(e)(U(t,n));return r===B&&t._rejectCallback(r.e,!0),t._isFateSealed()||t._setAsyncGuaranteed(),t},i.all=function(e){return new k(e).promise()},i.cast=function(e){var t=x(e);return t instanceof i||(t=new i(w),t._captureStackTrace(),t._setFulfilled(),t._rejectionHandler0=e),t},i.resolve=i.fulfilled=i.cast,i.reject=i.rejected=function(e){var t=new i(w);return t._captureStackTrace(),t._rejectCallback(e,!0),t},i.setScheduler=function(e){if("function"!=typeof e)throw new m("expecting a function but got "+p.classString(e));return g.setScheduler(e)},i.prototype._then=function(e,t,n,r,o){var s=void 0!==o,a=s?o:new i(w),c=this._target(),l=c._bitField;s||(a._propagateFrom(this,3),a._captureStackTrace(),void 0===r&&0!==(2097152&this._bitField)&&(r=0!==(50397184&l)?this._boundValue():c===this?void 0:this._boundTo),this._fireEvent("promiseChained",this,a));var f=u();if(0!==(50397184&l)){var h,p,d=c._settlePromiseCtx;0!==(33554432&l)?(p=c._rejectionHandler0,h=e):0!==(16777216&l)?(p=c._fulfillmentHandler0,h=t,c._unsetRejectionIsUnhandled()):(d=c._settlePromiseLateCancellationObserver,p=new b("late cancellation observer"),c._attachExtraTrace(p),h=t),g.invoke(d,c,{handler:null===f?h:"function"==typeof h&&f.bind(h),promise:a,receiver:r,value:p})}else c._addCallbacks(e,t,a,r,f);return a},i.prototype._length=function(){return 65535&this._bitField},i.prototype._isFateSealed=function(){return 0!==(117506048&this._bitField)},i.prototype._isFollowing=function(){return 67108864===(67108864&this._bitField)},i.prototype._setLength=function(e){this._bitField=this._bitField&-65536|65535&e},i.prototype._setFulfilled=function(){this._bitField=33554432|this._bitField,this._fireEvent("promiseFulfilled",this)},i.prototype._setRejected=function(){this._bitField=16777216|this._bitField,this._fireEvent("promiseRejected",this)},i.prototype._setFollowing=function(){this._bitField=67108864|this._bitField,this._fireEvent("promiseResolved",this)},i.prototype._setIsFinal=function(){this._bitField=4194304|this._bitField},i.prototype._isFinal=function(){return(4194304&this._bitField)>0},i.prototype._unsetCancelled=function(){this._bitField=this._bitField&-65537},i.prototype._setCancelled=function(){this._bitField=65536|this._bitField,this._fireEvent("promiseCancelled",this)},i.prototype._setAsyncGuaranteed=function(){g.hasCustomScheduler()||(this._bitField=134217728|this._bitField)},i.prototype._receiverAt=function(e){var t=0===e?this._receiver0:this[4*e-4+3];if(t!==h)return void 0===t&&this._isBound()?this._boundValue():t},i.prototype._promiseAt=function(e){return this[4*e-4+2]},i.prototype._fulfillmentHandlerAt=function(e){return this[4*e-4+0]},i.prototype._rejectionHandlerAt=function(e){return this[4*e-4+1]},i.prototype._boundValue=function(){},i.prototype._migrateCallback0=function(e){var t=(e._bitField,e._fulfillmentHandler0),n=e._rejectionHandler0,r=e._promise0,i=e._receiverAt(0);void 0===i&&(i=h),this._addCallbacks(t,n,r,i,null)},i.prototype._migrateCallbackAt=function(e,t){var n=e._fulfillmentHandlerAt(t),r=e._rejectionHandlerAt(t),i=e._promiseAt(t),o=e._receiverAt(t);void 0===o&&(o=h),this._addCallbacks(n,r,i,o,null)},i.prototype._addCallbacks=function(e,t,n,r,i){var o=this._length();if(o>=65531&&(o=0,this._setLength(0)),0===o)this._promise0=n,this._receiver0=r,"function"==typeof e&&(this._fulfillmentHandler0=null===i?e:i.bind(e)),"function"==typeof t&&(this._rejectionHandler0=null===i?t:i.bind(t));else{var s=4*o-4;this[s+2]=n,this[s+3]=r,"function"==typeof e&&(this[s+0]=null===i?e:i.bind(e)),"function"==typeof t&&(this[s+1]=null===i?t:i.bind(t))}return this._setLength(o+1),o},i.prototype._proxy=function(e,t){this._addCallbacks(void 0,void 0,t,e,null)},i.prototype._resolveCallback=function(e,t){if(0===(117506048&this._bitField)){if(e===this)return this._rejectCallback(c(),!1);var n=x(e,this);if(!(n instanceof i))return this._fulfill(e);t&&this._propagateFrom(n,2);var r=n._target();if(r===this)return void this._reject(c());var o=r._bitField;if(0===(50397184&o)){var s=this._length();s>0&&r._migrateCallback0(this);for(var a=1;a>>16)){if(e===this){var n=c();return this._attachExtraTrace(n),this._reject(n)}this._setFulfilled(),this._rejectionHandler0=e,(65535&t)>0&&(0!==(134217728&t)?this._settlePromises():g.settlePromises(this))}},i.prototype._reject=function(e){var t=this._bitField;if(!((117506048&t)>>>16))return this._setRejected(),this._fulfillmentHandler0=e,this._isFinal()?g.fatalError(e,p.isNode):void((65535&t)>0?g.settlePromises(this):this._ensurePossibleRejectionHandled())},i.prototype._fulfillPromises=function(e,t){for(var n=1;n0){if(0!==(16842752&e)){var n=this._fulfillmentHandler0;this._settlePromise0(this._rejectionHandler0,n,e),this._rejectPromises(t,n)}else{var r=this._rejectionHandler0;this._settlePromise0(this._fulfillmentHandler0,r,e),this._fulfillPromises(t,r)}this._setLength(0)}this._clearCancellationData()},i.prototype._settledValue=function(){var e=this._bitField;return 0!==(33554432&e)?this._rejectionHandler0:0!==(16777216&e)?this._fulfillmentHandler0:void 0},i.defer=i.pending=function(){C.deprecated("Promise.defer","new Promise");var e=new i(w);return{promise:e,resolve:o,reject:s}},p.notEnumerableProp(i,"_makeSelfResolutionError",c),e("./method")(i,w,x,f,C),e("./bind")(i,w,x,C),e("./cancel")(i,k,f,C),e("./direct_resolve")(i),e("./synchronous_inspection")(i),e("./join")(i,k,x,w,C),i.Promise=i,e("./map.js")(i,k,f,x,w,C),e("./call_get.js")(i),e("./using.js")(i,f,x,S,w,C),e("./timers.js")(i,w,C),e("./generators.js")(i,f,w,x,n,C),e("./nodeify.js")(i),e("./promisify.js")(i,w),e("./props.js")(i,k,x,f),e("./race.js")(i,w,x,f),e("./reduce.js")(i,k,f,x,w,C),e("./settle.js")(i,k,C),e("./some.js")(i,k,f),e("./filter.js")(i,w),e("./each.js")(i,w),e("./any.js")(i),p.toFastProperties(i),p.toFastProperties(i.prototype),a({a:1}),a({b:2}),a({c:3}),a(1),a(function(){}),a(void 0),a(!1),a(new i(w)),C.setBounds(v.firstLineError,p.lastLineError),i}},{"./any.js":1,"./async":2,"./bind":3,"./call_get.js":5,"./cancel":6,"./catch_filter":7,"./context":8,"./debuggability":9,"./direct_resolve":10,"./each.js":11,"./errors":12,"./es5":13,"./filter.js":14,"./finally":15,"./generators.js":16,"./join":17,"./map.js":18,"./method":19,"./nodeback":20,"./nodeify.js":21,"./promise_array":23,"./promisify.js":24,"./props.js":25,"./race.js":27,"./reduce.js":28,"./settle.js":30,"./some.js":31,"./synchronous_inspection":32,"./thenables":33,"./timers.js":34,"./using.js":35,"./util":36}],23:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o){function s(e){switch(e){case-2:return[];case-3:return{}}}function a(e){var r=this._promise=new t(n);e instanceof t&&r._propagateFrom(e,3),r._setOnCancel(this),this._values=e,this._length=0,this._totalResolved=0,this._init(void 0,-2)}var u=e("./util");u.isArray;return u.inherits(a,o),a.prototype.length=function(){return this._length},a.prototype.promise=function(){return this._promise},a.prototype._init=function c(e,n){var o=r(this._values,this._promise);if(o instanceof t){o=o._target();var a=o._bitField;if(this._values=o,0===(50397184&a))return this._promise._setAsyncGuaranteed(),o._then(c,this._reject,void 0,this,n);if(0===(33554432&a))return 0!==(16777216&a)?this._reject(o._reason()):this._cancel();o=o._value()}if(o=u.asArray(o),null===o){var l=i("expecting an array or an iterable object but got "+u.classString(o)).reason();return void this._promise._rejectCallback(l,!1)}return 0===o.length?void(n===-5?this._resolveEmptyArray():this._resolve(s(n))):void this._iterate(o)},a.prototype._iterate=function(e){var n=this.getActualLength(e.length);this._length=n,this._values=this.shouldCopyValues()?new Array(n):this._values;for(var i=this._promise,o=!1,s=null,a=0;a=this._length&&(this._resolve(this._values),!0)},a.prototype._promiseCancelled=function(){return this._cancel(),!0},a.prototype._promiseRejected=function(e){return this._totalResolved++,this._reject(e),!0},a.prototype._resultCancelled=function(){if(!this._isResolved()){var e=this._values;if(this._cancel(),e instanceof t)e.cancel();else for(var n=0;n=this._length){var r;if(this._isMap)r=h(this._values);else{r={};for(var i=this.length(),o=0,s=this.length();o>1},t.prototype.props=function(){return s(this)},t.props=function(e){return s(e)}}},{"./es5":13,"./util":36}],26:[function(e,t,n){"use strict";function r(e,t,n,r,i){for(var o=0;o=this._length&&(this._resolve(this._values),!0)},i.prototype._promiseFulfilled=function(e,t){var n=new o;return n._bitField=33554432,n._settledValueField=e,this._promiseResolved(t,n)},i.prototype._promiseRejected=function(e,t){var n=new o;return n._bitField=16777216,n._settledValueField=e,this._promiseResolved(t,n)},t.settle=function(e){return r.deprecated(".settle()",".reflect()"),new i(e).promise()},t.prototype.settle=function(){return t.settle(this)}}},{"./util":36}],31:[function(e,t,n){"use strict";t.exports=function(t,n,r){function i(e){this.constructor$(e),this._howMany=0,this._unwrap=!1,this._initialized=!1}function o(e,t){if((0|t)!==t||t<0)return r("expecting a positive integer\n\n See http://goo.gl/MqrFmX\n");var n=new i(e),o=n.promise();return n.setHowMany(t),n.init(),o}var s=e("./util"),a=e("./errors").RangeError,u=e("./errors").AggregateError,c=s.isArray,l={};s.inherits(i,n),i.prototype._init=function(){if(this._initialized){if(0===this._howMany)return void this._resolve([]);this._init$(void 0,-5);var e=c(this._values);!this._isResolved()&&e&&this._howMany>this._canPossiblyFulfill()&&this._reject(this._getRangeError(this.length()))}},i.prototype.init=function(){this._initialized=!0,this._init()},i.prototype.setUnwrap=function(){this._unwrap=!0},i.prototype.howMany=function(){return this._howMany},i.prototype.setHowMany=function(e){this._howMany=e},i.prototype._promiseFulfilled=function(e){return this._addFulfilled(e),this._fulfilled()===this.howMany()&&(this._values.length=this.howMany(),1===this.howMany()&&this._unwrap?this._resolve(this._values[0]):this._resolve(this._values),!0)},i.prototype._promiseRejected=function(e){return this._addRejected(e),this._checkOutcome()},i.prototype._promiseCancelled=function(){return this._values instanceof t||null==this._values?this._cancel():(this._addRejected(l),this._checkOutcome())},i.prototype._checkOutcome=function(){if(this.howMany()>this._canPossiblyFulfill()){for(var e=new u,t=this.length();t0?this._reject(e):this._cancel(),!0}return!1},i.prototype._fulfilled=function(){return this._totalResolved},i.prototype._rejected=function(){return this._values.length-this.length()},i.prototype._addRejected=function(e){this._values.push(e)},i.prototype._addFulfilled=function(e){this._values[this._totalResolved++]=e},i.prototype._canPossiblyFulfill=function(){return this.length()-this._rejected()},i.prototype._getRangeError=function(e){var t="Input array must contain at least "+this._howMany+" items but contains only "+e+" items";return new a(t)},i.prototype._resolveEmptyArray=function(){this._reject(this._getRangeError(0))},t.some=function(e,t){return o(e,t); -},t.prototype.some=function(e){return o(this,e)},t._SomePromiseArray=i}},{"./errors":12,"./util":36}],32:[function(e,t,n){"use strict";t.exports=function(e){function t(e){void 0!==e?(e=e._target(),this._bitField=e._bitField,this._settledValueField=e._isFateSealed()?e._settledValue():void 0):(this._bitField=0,this._settledValueField=void 0)}t.prototype._settledValue=function(){return this._settledValueField};var n=t.prototype.value=function(){if(!this.isFulfilled())throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\n\n See http://goo.gl/MqrFmX\n");return this._settledValue()},r=t.prototype.error=t.prototype.reason=function(){if(!this.isRejected())throw new TypeError("cannot get rejection reason of a non-rejected promise\n\n See http://goo.gl/MqrFmX\n");return this._settledValue()},i=t.prototype.isFulfilled=function(){return 0!==(33554432&this._bitField)},o=t.prototype.isRejected=function(){return 0!==(16777216&this._bitField)},s=t.prototype.isPending=function(){return 0===(50397184&this._bitField)},a=t.prototype.isResolved=function(){return 0!==(50331648&this._bitField)};t.prototype.isCancelled=e.prototype._isCancelled=function(){return 65536===(65536&this._bitField)},e.prototype.isCancelled=function(){return this._target()._isCancelled()},e.prototype.isPending=function(){return s.call(this._target())},e.prototype.isRejected=function(){return o.call(this._target())},e.prototype.isFulfilled=function(){return i.call(this._target())},e.prototype.isResolved=function(){return a.call(this._target())},e.prototype.value=function(){return n.call(this._target())},e.prototype.reason=function(){var e=this._target();return e._unsetRejectionIsUnhandled(),r.call(e)},e.prototype._value=function(){return this._settledValue()},e.prototype._reason=function(){return this._unsetRejectionIsUnhandled(),this._settledValue()},e.PromiseInspection=t}},{}],33:[function(e,t,n){"use strict";t.exports=function(t,n){function r(e,r){if(l(e)){if(e instanceof t)return e;var i=o(e);if(i===c){r&&r._pushContext();var u=t.reject(i.e);return r&&r._popContext(),u}if("function"==typeof i){if(s(e)){var u=new t(n);return e._then(u._fulfill,u._reject,void 0,u,null),u}return a(e,i,r)}}return e}function i(e){return e.then}function o(e){try{return i(e)}catch(t){return c.e=t,c}}function s(e){return f.call(e,"_promise0")}function a(e,r,i){function o(e){a&&(a._resolveCallback(e),a=null)}function s(e){a&&(a._rejectCallback(e,f,!0),a=null)}var a=new t(n),l=a;i&&i._pushContext(),a._captureStackTrace(),i&&i._popContext();var f=!0,h=u.tryCatch(r).call(e,o,s);return f=!1,a&&h===c&&(a._rejectCallback(h.e,!0,!0),a=null),l}var u=e("./util"),c=u.errorObj,l=u.isObject,f={}.hasOwnProperty;return r}},{"./util":36}],34:[function(e,t,n){"use strict";t.exports=function(t,n,r){function i(e){this.handle=e}function o(e){return clearTimeout(this.handle),e}function s(e){throw clearTimeout(this.handle),e}var a=e("./util"),u=t.TimeoutError;i.prototype._resultCancelled=function(){clearTimeout(this.handle)};var c=function(e){return l(+this).thenReturn(e)},l=t.delay=function(e,o){var s,a;return void 0!==o?(s=t.resolve(o)._then(c,null,null,e,void 0),r.cancellation()&&o instanceof t&&s._setOnCancel(o)):(s=new t(n),a=setTimeout(function(){s._fulfill()},+e),r.cancellation()&&s._setOnCancel(new i(a))),s._setAsyncGuaranteed(),s};t.prototype.delay=function(e){return l(e,this)};var f=function(e,t,n){var r;r="string"!=typeof t?t instanceof Error?t:new u("operation timed out"):new u(t),a.markAsOriginatingFromRejection(r),e._attachExtraTrace(r),e._reject(r),null!=n&&n.cancel()};t.prototype.timeout=function(e,t){e=+e;var n,a,u=new i(setTimeout(function(){n.isPending()&&f(n,t,a)},e));return r.cancellation()?(a=this.then(),n=a._then(o,s,void 0,u,void 0),n._setOnCancel(u)):n=this._then(o,s,void 0,u,void 0),n}}},{"./util":36}],35:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o,s){function a(e){setTimeout(function(){throw e},0)}function u(e){var t=r(e);return t!==e&&"function"==typeof e._isDisposable&&"function"==typeof e._getDisposer&&e._isDisposable()&&t._setDisposable(e._getDisposer()),t}function c(e,n){function i(){if(s>=c)return l._fulfill();var o=u(e[s++]);if(o instanceof t&&o._isDisposable()){try{o=r(o._getDisposer().tryDispose(n),e.promise)}catch(f){return a(f)}if(o instanceof t)return o._then(i,a,null,null,null)}i()}var s=0,c=e.length,l=new t(o);return i(),l}function l(e,t,n){this._data=e,this._promise=t,this._context=n}function f(e,t,n){this.constructor$(e,t,n)}function h(e){return l.isDisposer(e)?(this.resources[this.index]._setDisposable(e),e.promise()):e}function p(e){this.length=e,this.promise=null,this[e-1]=null}var d=e("./util"),v=e("./errors").TypeError,g=e("./util").inherits,y=d.errorObj,m=d.tryCatch;l.prototype.data=function(){return this._data},l.prototype.promise=function(){return this._promise},l.prototype.resource=function(){return this.promise().isFulfilled()?this.promise().value():null},l.prototype.tryDispose=function(e){var t=this.resource(),n=this._context;void 0!==n&&n._pushContext();var r=null!==t?this.doDispose(t,e):null;return void 0!==n&&n._popContext(),this._promise._unsetDisposable(),this._data=null,r},l.isDisposer=function(e){return null!=e&&"function"==typeof e.resource&&"function"==typeof e.tryDispose},g(f,l),f.prototype.doDispose=function(e,t){var n=this.data();return n.call(e,e,t)},p.prototype._resultCancelled=function(){for(var e=this.length,n=0;n0},t.prototype._getDisposer=function(){return this._disposer},t.prototype._unsetDisposable=function(){this._bitField=this._bitField&-131073,this._disposer=void 0},t.prototype.disposer=function(e){if("function"==typeof e)return new f(e,this,i());throw new v}}},{"./errors":12,"./util":36}],36:[function(e,r,i){"use strict";function o(){try{var e=U;return U=null,e.apply(this,arguments)}catch(t){return j.e=t,j}}function s(e){return U=e,o}function a(e){return null==e||e===!0||e===!1||"string"==typeof e||"number"==typeof e}function u(e){return"function"==typeof e||"object"==typeof e&&null!==e}function c(e){return a(e)?new Error(m(e)):e}function l(e,t){var n,r=e.length,i=new Array(r+1);for(n=0;n1,r=t.length>0&&!(1===t.length&&"constructor"===t[0]),i=R.test(e+"")&&C.names(e).length>0;if(n||r||i)return!0}return!1}catch(o){return!1}}function v(e){function t(){}t.prototype=e;for(var n=8;n--;)new t;return e}function g(e){return M.test(e)}function y(e,t,n){for(var r=new Array(e),i=0;i10||e[0]>0}(),D.isNode&&D.toFastProperties(t);try{throw new Error}catch(q){D.lastLineError=q}r.exports=D},{"./es5":13}]},{},[4])(4)}),"undefined"!=typeof window&&null!==window?window.P=window.Promise:"undefined"!=typeof self&&null!==self&&(self.P=self.Promise)}).call(t,n(38),function(){return this}(),n(39).setImmediate)},function(e,t){function n(){throw new Error("setTimeout has not been defined")}function r(){throw new Error("clearTimeout has not been defined")}function i(e){if(l===setTimeout)return setTimeout(e,0);if((l===n||!l)&&setTimeout)return l=setTimeout,setTimeout(e,0);try{return l(e,0)}catch(t){try{return l.call(null,e,0)}catch(t){return l.call(this,e,0)}}}function o(e){if(f===clearTimeout)return clearTimeout(e);if((f===r||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function s(){v&&p&&(v=!1,p.length?d=p.concat(d):g=-1,d.length&&a())}function a(){if(!v){var e=i(s);v=!0;for(var t=d.length;t;){for(p=d,d=[];++g1)for(var n=1;n=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var n=c++,r=!(arguments.length<2)&&a.call(arguments,1);return u[n]=!0,o(function(){u[n]&&(r?e.apply(null,r):e.call(null),t.clearImmediate(n))}),n},t.clearImmediate="function"==typeof r?r:function(e){delete u[e]}}).call(t,n(39).setImmediate,n(39).clearImmediate)},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(e){function t(e,t,n,r){var i=k.resolve(e);return arguments.length<2?i:i.then(t,n,r)}function r(e){return new k(e)}function i(e){return function(){for(var t=0,n=arguments.length,r=new Array(n);t>>0,c=u,l=[],f=0;f0){a.become(i),e._visitRemaining(t,f,i);break}i.visit(a,n,r)}else--c;return 0===c&&a.reject(new RangeError("any(): array must not be empty")),s}function i(t,n){function r(e){this.resolved||(l.push(e),0===--p&&(f=null,this.resolve(l)))}function i(e){this.resolved||(f.push(e),0===--o&&(l=null,this.reject(f)))}var o,s,a,u=e._defer(),c=u._handler,l=[],f=[],h=t.length>>>0,p=0;for(a=0;ap?c.reject(new RangeError("some(): array must contain at least "+n+" item(s), but had "+p)):0===p&&c.resolve(l),a=0;a2?g.call(e,h(t),arguments[2]):g.call(e,h(t))}function f(e,t){return arguments.length>2?y.call(e,h(t),arguments[2]):y.call(e,h(t))}function h(e){return function(t,n,r){return p(e,void 0,[t,n,r])}}var p=r(e),d=e.resolve,v=e.all,g=Array.prototype.reduce,y=Array.prototype.reduceRight,m=Array.prototype.slice;return e.any=n,e.some=i,e.settle=u,e.map=o,e.filter=s,e.reduce=l,e.reduceRight=f,e.prototype.spread=function(e){return this.then(v).then(function(t){return e.apply(this,t)})},e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(){function e(){return{state:"pending"}}function t(e){return{state:"rejected",reason:e}}function n(e){return{state:"fulfilled",value:e}}function r(r){var i=r.state();return 0===i?e():i>0?n(r.value):t(r.value)}return{pending:e,fulfilled:n,rejected:t,inspect:r}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(){function e(e,n){function r(t,r,o){var s=e._defer(),a=o.length,u=new Array(a);return i({f:t,thisArg:r,args:o,params:u,i:a-1,call:n},s._handler),s}function i(t,r){if(t.i<0)return n(t.f,t.thisArg,t.params,r);var i=e._handler(t.args[t.i]);i.fold(o,t,void 0,r)}function o(e,t,n){e.params[e.i]=t,e.i-=1,i(e,n)}return arguments.length<2&&(n=t),r}function t(e,t,n,r){try{r.resolve(e.apply(t,n))}catch(i){r.reject(i)}}return e.tryCatchResolve=t,e}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(){function e(){throw new TypeError("catch predicate must be a function")}function t(e,t){return n(t)?e instanceof t:t(e)}function n(e){return e===Error||null!=e&&e.prototype instanceof Error}function r(e){return("object"==typeof e||"function"==typeof e)&&null!==e}function i(e){return e}return function(n){function o(e,n){return function(r){return t(r,n)?e.call(this,r):c(r)}}function s(e,t,n,i){var o=e.call(t);return r(o)?a(o,n,i):n(i)}function a(e,t,n){return u(e).then(function(){return t(n)})}var u=n.resolve,c=n.reject,l=n.prototype["catch"];return n.prototype.done=function(e,t){this._handler.visit(this._handler.receiver,e,t)},n.prototype["catch"]=n.prototype.otherwise=function(t){return arguments.length<2?l.call(this,t):"function"!=typeof t?this.ensure(e):l.call(this,o(arguments[1],t))},n.prototype["finally"]=n.prototype.ensure=function(e){return"function"!=typeof e?this:this.then(function(t){return s(e,this,i,t)},function(t){return s(e,this,c,t)})},n.prototype["else"]=n.prototype.orElse=function(e){return this.then(void 0,function(){return e})},n.prototype["yield"]=function(e){return this.then(function(){return e})},n.prototype.tap=function(e){return this.then(e)["yield"](this)},n}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(){return function(e){return e.prototype.fold=function(t,n){var r=this._beget();return this._handler.fold(function(n,r,i){e._handler(n).fold(function(e,n,r){r.resolve(t.call(this,n,e))},r,this,i)},n,r._handler.receiver,r._handler),r},e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},[310,47],function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(){return function(e){function t(e,t,r,i){return n(function(t){return[t,e(t)]},t,r,i)}function n(e,t,i,o){function s(o,s){return r(i(o)).then(function(){return n(e,t,i,s)})}return r(o).then(function(n){return r(t(n)).then(function(t){return t?n:r(e(n)).spread(s)})})}var r=e.resolve;return e.iterate=t,e.unfold=n,e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(){return function(e){return e.prototype.progress=function(e){return this.then(void 0,void 0,e)},e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(){return function(e){return e.prototype["with"]=e.prototype.withThis=function(e){var t=this._beget(),n=t._handler;return n.receiver=e,this._handler.chain(n,e),t},e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(e){function t(e){throw e}function r(){}var i=n(42).setTimer,o=n(56);return function(e){function n(e){e.handled||(p.push(e),l("Potentially unhandled rejection ["+e.id+"] "+o.formatError(e.value)))}function s(e){var t=p.indexOf(e);t>=0&&(p.splice(t,1),f("Handled previous rejection ["+e.id+"] "+o.formatObject(e.value)))}function a(e,t){h.push(e,t),null===d&&(d=i(u,0))}function u(){for(d=null;h.length>0;)h.shift()(h.shift())}var c,l=r,f=r;"undefined"!=typeof console&&(c=console,l="undefined"!=typeof c.error?function(e){c.error(e)}:function(e){c.log(e)},f="undefined"!=typeof c.info?function(e){c.info(e)}:function(e){c.log(e)}),e.onPotentiallyUnhandledRejection=function(e){a(n,e)},e.onPotentiallyUnhandledRejectionHandled=function(e){a(s,e)},e.onFatalRejection=function(e){a(t,e.value)};var h=[],p=[],d=null;return e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(){function e(e){var n="object"==typeof e&&null!==e&&(e.stack||e.message)?e.stack||e.message:t(e);return e instanceof Error?n:n+" (WARNING: non-Error used)"}function t(e){var t=String(e);return"[object Object]"===t&&"undefined"!=typeof JSON&&(t=n(e,t)),t}function n(e,t){try{return JSON.stringify(e)}catch(n){return t}}return{formatError:e,formatObject:t,tryStringify:n}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},[311,58,59,42],function(e,t,n){var r;(function(i){/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(o){"use strict";r=function(){return function(e){function t(e,t){this._handler=e===w?t:n(e)}function n(e){function t(e){i.resolve(e)}function n(e){i.reject(e)}function r(e){i.notify(e)}var i=new E;try{e(t,n,r)}catch(o){n(o)}return i}function r(e){return M(e)?e:new t(w,new x(y(e)))}function o(e){return new t(w,new x(new S(e)))}function s(){return ee}function a(){return new t(w,new E)}function u(e,t){var n=new E(e.receiver,e.join().context);return new t(w,n)}function c(e){return f(W,null,e)}function l(e,t){return f(D,e,t)}function f(e,n,r){function i(t,i,s){s.resolved||h(r,o,t,e(n,i,t),s)}function o(e,t,n){l[e]=t,0===--c&&n.become(new I(l))}for(var s,a="function"==typeof n?i:o,u=new E,c=r.length>>>0,l=new Array(c),f=0;f0?t(n,o.value,i):(i.become(o),p(e,n+1,o))}else t(n,r,i)}function p(e,t,n){for(var r=t;r0||"function"!=typeof t&&i<0)return new this.constructor(w,r);var o=this._beget(),s=o._handler;return r.chain(s,r.receiver,e,t,n),o},t.prototype["catch"]=function(e){return this.then(void 0,e)},t.prototype._beget=function(){return u(this._handler,this.constructor)},t.all=c,t.race=v,t._traverse=l,t._visitRemaining=p,w.prototype.when=w.prototype.become=w.prototype.notify=w.prototype.fail=w.prototype._unreport=w.prototype._report=K,w.prototype._state=0,w.prototype.state=function(){return this._state},w.prototype.join=function(){for(var e=this;void 0!==e.handler;)e=e.handler;return e},w.prototype.chain=function(e,t,n,r,i){this.when({resolver:e,receiver:t,fulfilled:n,rejected:r,progress:i})},w.prototype.visit=function(e,t,n,r){this.chain(X,e,t,n,r)},w.prototype.fold=function(e,t,n,r){this.when(new R(e,t,n,r))},Q(w,_),_.prototype.become=function(e){e.fail()};var X=new _;Q(w,E),E.prototype._state=0,E.prototype.resolve=function(e){this.become(y(e))},E.prototype.reject=function(e){this.resolved||this.become(new S(e))},E.prototype.join=function(){if(!this.resolved)return this;for(var e=this;void 0!==e.handler;)if(e=e.handler,e===this)return this.handler=j();return e},E.prototype.run=function(){var e=this.consumers,t=this.handler;this.handler=this.handler.join(),this.consumers=void 0;for(var n=0;n",'"',"`"," ","\r","\n","\t"],d=["{","}","|","\\","^","`"].concat(p),v=["'"].concat(d),g=["%","/","?",";","#"].concat(v),y=["/","?","#"],m=255,b=/^[+a-z0-9A-Z_-]{0,63}$/,w=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,_={javascript:!0,"javascript:":!0},E={javascript:!0,"javascript:":!0},x={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},k=n(65);r.prototype.parse=function(e,t,n){if(!c.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var r=e.indexOf("?"),i=r!==-1&&r127?"x":R[L];if(!M.match(b)){var P=O.slice(0,C),N=O.slice(C+1),D=R.match(w);D&&(P.push(D[1]),N.unshift(D[2])),N.length&&(a="/"+N.join(".")+a),this.hostname=P.join(".");break}}}this.hostname.length>m?this.hostname="":this.hostname=this.hostname.toLowerCase(),B||(this.hostname=u.toASCII(this.hostname));var q=this.port?":"+this.port:"",z=this.hostname||"";this.host=z+q,this.href+=this.host,B&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==a[0]&&(a="/"+a))}if(!_[d])for(var C=0,A=v.length;C0)&&n.host.split("@");I&&(n.auth=I.shift(),n.host=n.hostname=I.shift())}return n.search=e.search,n.query=e.query,c.isNull(n.pathname)&&c.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.href=n.format(),n}if(!_.length)return n.pathname=null,n.search?n.path="/"+n.search:n.path=null,n.href=n.format(),n;for(var S=_.slice(-1)[0],C=(n.host||e.host||_.length>1)&&("."===S||".."===S)||""===S,T=0,j=_.length;j>=0;j--)S=_[j],"."===S?_.splice(j,1):".."===S?(_.splice(j,1),T++):T&&(_.splice(j,1),T--);if(!b&&!w)for(;T--;T)_.unshift("..");!b||""===_[0]||_[0]&&"/"===_[0].charAt(0)||_.unshift(""),C&&"/"!==_.join("/").substr(-1)&&_.push("");var U=""===_[0]||_[0]&&"/"===_[0].charAt(0);if(k){n.hostname=n.host=U?"":_.length?_.shift():"";var I=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@");I&&(n.auth=I.shift(),n.host=n.hostname=I.shift())}return b=b||n.host&&_.length,b&&!U&&_.unshift(""),_.length?n.pathname=_.join("/"):(n.pathname=null,n.path=null),c.isNull(n.pathname)&&c.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.auth=e.auth||n.auth,n.slashes=n.slashes||e.slashes,n.href=n.format(),n},r.prototype.parseHost=function(){var e=this.host,t=f.exec(e);t&&(t=t[0],":"!==t&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}},function(e,t,n){var r;(function(e,i){!function(o){function s(e){throw RangeError(O[e])}function a(e,t){for(var n=e.length,r=[];n--;)r[n]=t(e[n]);return r}function u(e,t){var n=e.split("@"),r="";n.length>1&&(r=n[0]+"@",e=n[1]),e=e.replace(B,".");var i=e.split("."),o=a(i,t).join(".");return r+o}function c(e){for(var t,n,r=[],i=0,o=e.length;i=55296&&t<=56319&&i65535&&(e-=65536,t+=M(e>>>10&1023|55296),e=56320|1023&e),t+=M(e)}).join("")}function f(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:_}function h(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function p(e,t,n){var r=0;for(e=n?R(e/I):e>>1,e+=R(e/t);e>A*x>>1;r+=_)e=R(e/A);return R(r+(A+1)*e/(e+k))}function d(e){var t,n,r,i,o,a,u,c,h,d,v=[],g=e.length,y=0,m=C,b=S;for(n=e.lastIndexOf(T),n<0&&(n=0),r=0;r=128&&s("not-basic"),v.push(e.charCodeAt(r));for(i=n>0?n+1:0;i=g&&s("invalid-input"),c=f(e.charCodeAt(i++)),(c>=_||c>R((w-y)/a))&&s("overflow"),y+=c*a,h=u<=b?E:u>=b+x?x:u-b,!(cR(w/d)&&s("overflow"),a*=d;t=v.length+1,b=p(y-o,t,0==o),R(y/t)>w-m&&s("overflow"),m+=R(y/t),y%=t,v.splice(y++,0,m)}return l(v)}function v(e){var t,n,r,i,o,a,u,l,f,d,v,g,y,m,b,k=[];for(e=c(e),g=e.length,t=C,n=0,o=S,a=0;a=t&&vR((w-n)/y)&&s("overflow"),n+=(u-t)*y,t=u,a=0;aw&&s("overflow"),v==t){for(l=n,f=_;d=f<=o?E:f>=o+x?x:f-o,!(l= 0x80 (not a basic code point)","invalid-input":"Invalid input"},A=_-E,R=Math.floor,M=String.fromCharCode;b={version:"1.3.2",ucs2:{decode:c,encode:l},decode:d,encode:v,toASCII:y,toUnicode:g},r=function(){return b}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(this)}).call(t,n(36)(e),function(){return this}())},function(e,t){"use strict";e.exports={isString:function(e){return"string"==typeof e},isObject:function(e){return"object"==typeof e&&null!==e},isNull:function(e){return null===e},isNullOrUndefined:function(e){return null==e}}},function(e,t,n){"use strict";t.decode=t.parse=n(66),t.encode=t.stringify=n(67)},function(e,t){"use strict";function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}e.exports=function(e,t,r,i){t=t||"&",r=r||"=";var o={};if("string"!=typeof e||0===e.length)return o;var s=/\+/g;e=e.split(t);var a=1e3;i&&"number"==typeof i.maxKeys&&(a=i.maxKeys);var u=e.length;a>0&&u>a&&(u=a);for(var c=0;c=0?(l=d.substr(0,v),f=d.substr(v+1)):(l=d,f=""),h=decodeURIComponent(l),p=decodeURIComponent(f),n(o,h)?Array.isArray(o[h])?o[h].push(p):o[h]=[o[h],p]:o[h]=p}return o}},function(e,t){"use strict";var n=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};e.exports=function(e,t,r,i){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"==typeof e?Object.keys(e).map(function(i){var o=encodeURIComponent(n(i))+r;return Array.isArray(e[i])?e[i].map(function(e){return o+encodeURIComponent(n(e))}).join(t):o+encodeURIComponent(n(e[i]))}).join(t):i?encodeURIComponent(n(i))+r+encodeURIComponent(n(e)):""}},function(e,t,n){(function(t){"use strict";function r(e){g.call(this);var n=this.stream=u(e);this.muxer=new d(n),this.rest=new t(0),this.frameMax=f.FRAME_MIN_SIZE,this.sentSinceLastCheck=!1,this.recvSinceLastCheck=!1,this.expectSocketClose=!1,this.freeChannels=new _,this.channels=[{channel:{accept:o(this)},buffer:e}]}function i(e){var t=this.channels[e.channel];return t?t.channel.accept(e):void this.closeWithError(x("Frame on unknown channel %d",e.channel),f.CHANNEL_ERROR,new Error(x("Frame on unknown channel: %s",w(e,!1))))}function o(e){return function(t){if(t===p);else if(t.id===l.ConnectionClose){e.sendMethod(0,l.ConnectionCloseOk,{});var n=x("Connection closed: %s",b(t)),r=S(n);if(c(t.fields)){var i=new Error(n);i.code=t.fields.replyCode,e.emit("error",i)}e.toClosed(r,n)}else t.id===l.ConnectionBlocked?e.emit("blocked",t.fields.reason):t.id===l.ConnectionUnblocked?e.emit("unblocked"):e.closeWithError(x("Unexpected frame on channel 0"),f.UNEXPECTED_FRAME,new Error(x("Unexpected frame on channel 0: %s",w(t,!1))))}}function s(e,t){return function(){throw new I(e,t)}}function a(e,t,n){e.sendMethod=e.sendContent=e.sendMessage=s(t,n)}function u(e){if(e instanceof v)return e;var t=new v;return t.wrap(e),t._write=function(t,n,r){return e.write(t,n,r)},t}function c(e){switch(e.replyCode){case l.constants.CONNECTION_FORCED:case l.constants.REPLY_SUCCESS:return!1;default:return!0}}var l=n(69),f=l.constants,h=n(76),p=h.HEARTBEAT,d=n(87).Mux,v=n(88).Duplex||n(104),g=n(89).EventEmitter,y=n(110).Heart,m=n(111).methodName,b=n(111).closeMessage,w=n(111).inspect,_=n(112).BitSet,E=n(84).inherits,x=n(84).format,k=n(88).PassThrough||n(113),I=n(116).IllegalOperationError,S=n(116).stackCapture,C=1024,T=2048;E(r,g);var j=r.prototype;j.sendProtocolHeader=function(){this.sendBytes(h.PROTOCOL_HEADER)},j.open=function(e,t){function n(e){d.step(function(t,n){null!==t?o(t):0!==n.channel?o(new Error(x("Frame on channel != 0 during handshake: %s",w(n,!1)))):e(n)})}function r(e,t){n(function(n){n.id===e?t(n):o(new Error(x("Expected %s; got %s",m(e),w(n,!1))))})}function o(e){v(e)}function s(e){try{d.sendMethod(0,e,g)}catch(t){o(t)}}function a(e,t){return 0===e||0===t?Math.max(e,t):Math.min(e,t)}function u(t){var r=t.fields.mechanisms.toString().split(" ");return r.indexOf(e.mechanism)<0?void o(new Error(x("SASL mechanism %s is not provided by the server",e.mechanism))):(s(l.ConnectionStartOk),void n(c))}function c(t){switch(t.id){case l.ConnectionSecure:o(new Error("Wasn't expecting to have to go through secure"));break;case l.ConnectionClose:o(new Error(x("Handshake terminated by server: %s",b(t))));break;case l.ConnectionTune:var n=t.fields;g.frameMax=a(n.frameMax,e.frameMax),g.channelMax=a(n.channelMax,e.channelMax),g.heartbeat=a(n.heartbeat,e.heartbeat),s(l.ConnectionTuneOk),s(l.ConnectionOpen),r(l.ConnectionOpenOk,f);break;default:o(new Error(x("Expected connection.secure, connection.close, or connection.tune during handshake; got %s",w(t,!1))))}}function f(e){d.channelMax=g.channelMax||65535,d.frameMax=g.frameMax||4294967295,d.heartbeat=g.heartbeat,d.heartbeater=d.startHeartbeater(),d.accept=i,p(e)}function h(e){o(e||new Error("Socket closed abruptly during opening handshake"))}function p(e){d.stream.removeListener("end",h),d.stream.removeListener("error",h),d.stream.on("error",d.onSocketError.bind(d)),d.stream.on("end",d.onSocketError.bind(d,new Error("Unexpected close"))),d.on("frameError",d.onSocketError.bind(d)),d.acceptLoop(),v(null,e)}var d=this,v=t||function(){},g=Object.create(e);this.stream.on("end",h),this.stream.on("error",h),this.sendProtocolHeader(),r(l.ConnectionStart,u)},j.close=function(e){var t=e&&function(){e(null)};this.closeBecause("Cheers, thanks",f.REPLY_SUCCESS,t)},j.closeBecause=function(e,t,n){this.sendMethod(0,l.ConnectionClose,{replyText:e,replyCode:t,methodId:0,classId:0});var r=S("closeBecause called: "+e);this.toClosing(r,n)},j.closeWithError=function(e,t,n){this.emit("error",n),this.closeBecause(e,t)},j.onSocketError=function(e){if(!this.expectSocketClose){this.expectSocketClose=!0,this.emit("error",e);var t=S("Socket error");this.toClosed(t,e.toString())}},j.toClosing=function(e,t){var n=this.sendMethod.bind(this);this.accept=function(e){if(e.id===l.ConnectionCloseOk){t&&t();var r=S("ConnectionCloseOk received");this.toClosed(r,"Closed by client")}else e.id===l.ConnectionClose&&n(0,l.ConnectionCloseOk,{})},a(this,"Connection closing",e)},j._closeChannels=function(e){for(var t=1;tthis.channelMax)throw new Error("No channels left to allocate");this.freeChannels.set(n);var r=t&&t.highWaterMark||C,i=new k({objectMode:!0,highWaterMark:r});return this.channels[n]={channel:e,buffer:i},i.on("drain",function(){e.onBufferDrain()}),this.muxer.pipeFrom(i),n},j.releaseChannel=function(e){this.freeChannels.clear(e);var t=this.channels[e].buffer;this.muxer.unpipeFrom(t),this.channels[e]=null},j.acceptLoop=function(){function e(){try{for(var e;e=t.recvFrame();)t.accept(e)}catch(n){t.emit("frameError",n)}}var t=this;t.stream.on("readable",e),e()},j.step=function(e){function t(){var r;try{r=n.recvFrame()}catch(i){return void e(i,null)}r?e(null,r):n.stream.once("readable",t)}var n=this;t()},j.checkSend=function(){var e=this.sentSinceLastCheck;return this.sentSinceLastCheck=!1,e},j.checkRecv=function(){var e=this.recvSinceLastCheck;return this.recvSinceLastCheck=!1,e},j.sendBytes=function(e){this.sentSinceLastCheck=!0,this.stream.write(e)},j.sendHeartbeat=function(){return this.sendBytes(h.HEARTBEAT_BUF)};var U=l.encodeMethod,B=l.encodeProperties;j.sendMethod=function(e,t,n){var r=U(t,e,n);this.sentSinceLastCheck=!0;var i=this.channels[e].buffer;return i.write(r)},j.sendMessage=function(e,n,r,i,o,s){if(!t.isBuffer(s))throw new TypeError("content is not a buffer");var a=U(n,e,r),u=B(i,e,s.length,o),c=this.channels[e].buffer;this.sentSinceLastCheck=!0;var l=a.length+u.length,f=s.length>0?s.length+O:0,h=l+f;if(h0&&A(e,s).copy(p,d),c.write(p)}if(ln.length?n.slice(s):n.slice(s,a),c=A(e,u);r=i.write(c)}return this.sentSinceLastCheck=!0,r};var R=h.parseFrame,M=h.decodeFrame;j.recvFrame=function(){var e=R(this.rest,this.frameMax);if(e)return this.rest=e.rest,M(e);var n=this.stream.read();return null!==n&&(this.recvSinceLastCheck=!0,this.rest=t.concat([this.rest,n]),this.recvFrame())},e.exports.Connection=r}).call(t,n(3).Buffer)},function(e,t,n){(function(t){/** @preserve This file is generated by the script +"use strict";function i(){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(t){return!1}}function o(){return e.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(t,n){if(o()=o())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o().toString(16)+" bytes");return 0|e}function g(t){return+t!=t&&(t=0),e.alloc(+t)}function y(t,n){if(e.isBuffer(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!=typeof t&&(t=""+t);var r=t.length;if(0===r)return 0;for(var i=!1;;)switch(n){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return W(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return G(t).length;default:if(i)return W(t).length;n=(""+n).toLowerCase(),i=!0}}function m(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if(n>>>=0,t>>>=0,n<=t)return"";for(e||(e="utf8");;)switch(e){case"hex":return A(this,t,n);case"utf8":case"utf-8":return B(this,t,n);case"ascii":return O(this,t,n);case"latin1":case"binary":return j(this,t,n);case"base64":return T(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return R(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function b(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function _(t,n,r,i,o){if(0===t.length)return-1;if("string"==typeof r?(i=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=o?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(o)return-1;r=t.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof n&&(n=e.from(n,i)),e.isBuffer(n))return 0===n.length?-1:w(t,n,r,i,o);if("number"==typeof n)return n=255&n,e.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(t,n,r):Uint8Array.prototype.lastIndexOf.call(t,n,r):w(t,[n],r,i,o);throw new TypeError("val must be string, number or Buffer")}function w(e,t,n,r,i){function o(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}var s=1,a=e.length,u=t.length;if(void 0!==r&&(r=String(r).toLowerCase(),"ucs2"===r||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;s=2,a/=2,u/=2,n/=2}var c;if(i){var l=-1;for(c=n;ca&&(n=a-u),c=n;c>=0;c--){for(var f=!0,h=0;hi&&(r=i)):r=i;var o=t.length;if(o%2!==0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var s=0;s239?4:o>223?3:o>191?2:1;if(i+a<=n){var u,c,l,f;switch(a){case 1:o<128&&(s=o);break;case 2:u=e[i+1],128===(192&u)&&(f=(31&o)<<6|63&u,f>127&&(s=f));break;case 3:u=e[i+1],c=e[i+2],128===(192&u)&&128===(192&c)&&(f=(15&o)<<12|(63&u)<<6|63&c,f>2047&&(f<55296||f>57343)&&(s=f));break;case 4:u=e[i+1],c=e[i+2],l=e[i+3],128===(192&u)&&128===(192&c)&&128===(192&l)&&(f=(15&o)<<18|(63&u)<<12|(63&c)<<6|63&l,f>65535&&f<1114112&&(s=f))}}null===s?(s=65533,a=1):s>65535&&(s-=65536,r.push(s>>>10&1023|55296),s=56320|1023&s),r.push(s),i+=a}return U(r)}function U(e){var t=e.length;if(t<=ee)return String.fromCharCode.apply(String,e);for(var n="",r=0;rr)&&(n=r);for(var i="",o=t;on)throw new RangeError("Trying to access beyond buffer length")}function P(t,n,r,i,o,s){if(!e.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(n>o||nt.length)throw new RangeError("Index out of range")}function L(e,t,n,r){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-n,2);i>>8*(r?i:1-i)}function M(e,t,n,r){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-n,4);i>>8*(r?i:3-i)&255}function N(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function D(e,t,n,r,i){return i||N(e,t,n,4,3.4028234663852886e38,-3.4028234663852886e38),J.write(e,t,n,r,23,4),n+4}function q(e,t,n,r,i){return i||N(e,t,n,8,1.7976931348623157e308,-1.7976931348623157e308),J.write(e,t,n,r,52,8),n+8}function z(e){if(e=H(e).replace(te,""),e.length<2)return"";for(;e.length%4!==0;)e+="=";return e}function H(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function Q(e){return e<16?"0"+e.toString(16):e.toString(16)}function W(e,t){t=t||1/0;for(var n,r=e.length,i=null,o=[],s=0;s55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(s+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=(i-55296<<10|n-56320)+65536}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function K(e){for(var t=[],n=0;n>8,i=n%256,o.push(i),o.push(r);return o}function G(e){return X.toByteArray(z(e))}function Y(e,t,n,r){for(var i=0;i=t.length||i>=e.length);++i)t[i+n]=e[i];return i}function $(e){return e!==e}var X=n(4),J=n(5),Z=n(6);t.Buffer=e,t.SlowBuffer=g,t.INSPECT_MAX_BYTES=50,e.TYPED_ARRAY_SUPPORT=void 0!==r.TYPED_ARRAY_SUPPORT?r.TYPED_ARRAY_SUPPORT:i(),t.kMaxLength=o(),e.poolSize=8192,e._augment=function(t){return t.__proto__=e.prototype,t},e.from=function(e,t,n){return a(null,e,t,n)},e.TYPED_ARRAY_SUPPORT&&(e.prototype.__proto__=Uint8Array.prototype,e.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&e[Symbol.species]===e&&Object.defineProperty(e,Symbol.species,{value:null,configurable:!0})),e.alloc=function(e,t,n){return c(null,e,t,n)},e.allocUnsafe=function(e){return l(null,e)},e.allocUnsafeSlow=function(e){return l(null,e)},e.isBuffer=function(e){return!(null==e||!e._isBuffer)},e.compare=function(t,n){if(!e.isBuffer(t)||!e.isBuffer(n))throw new TypeError("Arguments must be Buffers");if(t===n)return 0;for(var r=t.length,i=n.length,o=0,s=Math.min(r,i);o0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),""},e.prototype.compare=function(t,n,r,i,o){if(!e.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===n&&(n=0),void 0===r&&(r=t?t.length:0),void 0===i&&(i=0),void 0===o&&(o=this.length),n<0||r>t.length||i<0||o>this.length)throw new RangeError("out of range index");if(i>=o&&n>=r)return 0;if(i>=o)return-1;if(n>=r)return 1;if(n>>>=0,r>>>=0,i>>>=0,o>>>=0,this===t)return 0;for(var s=o-i,a=r-n,u=Math.min(s,a),c=this.slice(i,o),l=t.slice(n,r),f=0;fi)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return E(this,e,t,n);case"utf8":case"utf-8":return x(this,e,t,n);case"ascii":return k(this,e,t,n);case"latin1":case"binary":return I(this,e,t,n);case"base64":return C(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return S(this,e,t,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},e.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var ee=4096;e.prototype.slice=function(t,n){var r=this.length;t=~~t,n=void 0===n?r:~~n,t<0?(t+=r,t<0&&(t=0)):t>r&&(t=r),n<0?(n+=r,n<0&&(n=0)):n>r&&(n=r),n0&&(i*=256);)r+=this[e+--t]*i;return r},e.prototype.readUInt8=function(e,t){return t||F(e,1,this.length),this[e]},e.prototype.readUInt16LE=function(e,t){return t||F(e,2,this.length),this[e]|this[e+1]<<8},e.prototype.readUInt16BE=function(e,t){return t||F(e,2,this.length),this[e]<<8|this[e+1]},e.prototype.readUInt32LE=function(e,t){return t||F(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},e.prototype.readUInt32BE=function(e,t){return t||F(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},e.prototype.readIntLE=function(e,t,n){e=0|e,t=0|t,n||F(e,t,this.length);for(var r=this[e],i=1,o=0;++o=i&&(r-=Math.pow(2,8*t)),r},e.prototype.readIntBE=function(e,t,n){e=0|e,t=0|t,n||F(e,t,this.length);for(var r=t,i=1,o=this[e+--r];r>0&&(i*=256);)o+=this[e+--r]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*t)),o},e.prototype.readInt8=function(e,t){return t||F(e,1,this.length),128&this[e]?(255-this[e]+1)*-1:this[e]},e.prototype.readInt16LE=function(e,t){t||F(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},e.prototype.readInt16BE=function(e,t){t||F(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},e.prototype.readInt32LE=function(e,t){return t||F(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},e.prototype.readInt32BE=function(e,t){return t||F(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},e.prototype.readFloatLE=function(e,t){return t||F(e,4,this.length),J.read(this,e,!0,23,4)},e.prototype.readFloatBE=function(e,t){return t||F(e,4,this.length),J.read(this,e,!1,23,4)},e.prototype.readDoubleLE=function(e,t){return t||F(e,8,this.length),J.read(this,e,!0,52,8)},e.prototype.readDoubleBE=function(e,t){return t||F(e,8,this.length),J.read(this,e,!1,52,8)},e.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t=0|t,n=0|n,!r){var i=Math.pow(2,8*n)-1;P(this,e,t,n,i,0)}var o=1,s=0;for(this[t]=255&e;++s=0&&(s*=256);)this[t+o]=e/s&255;return t+n},e.prototype.writeUInt8=function(t,n,r){return t=+t,n=0|n,r||P(this,t,n,1,255,0),e.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[n]=255&t,n+1},e.prototype.writeUInt16LE=function(t,n,r){return t=+t,n=0|n,r||P(this,t,n,2,65535,0),e.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8):L(this,t,n,!0),n+2},e.prototype.writeUInt16BE=function(t,n,r){return t=+t,n=0|n,r||P(this,t,n,2,65535,0),e.TYPED_ARRAY_SUPPORT?(this[n]=t>>>8,this[n+1]=255&t):L(this,t,n,!1),n+2},e.prototype.writeUInt32LE=function(t,n,r){return t=+t,n=0|n,r||P(this,t,n,4,4294967295,0),e.TYPED_ARRAY_SUPPORT?(this[n+3]=t>>>24,this[n+2]=t>>>16,this[n+1]=t>>>8,this[n]=255&t):M(this,t,n,!0),n+4},e.prototype.writeUInt32BE=function(t,n,r){return t=+t,n=0|n,r||P(this,t,n,4,4294967295,0),e.TYPED_ARRAY_SUPPORT?(this[n]=t>>>24,this[n+1]=t>>>16,this[n+2]=t>>>8,this[n+3]=255&t):M(this,t,n,!1),n+4},e.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t=0|t,!r){var i=Math.pow(2,8*n-1);P(this,e,t,n,i-1,-i)}var o=0,s=1,a=0;for(this[t]=255&e;++o>0)-a&255;return t+n},e.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t=0|t,!r){var i=Math.pow(2,8*n-1);P(this,e,t,n,i-1,-i)}var o=n-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+n},e.prototype.writeInt8=function(t,n,r){return t=+t,n=0|n,r||P(this,t,n,1,127,-128),e.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[n]=255&t,n+1},e.prototype.writeInt16LE=function(t,n,r){return t=+t,n=0|n,r||P(this,t,n,2,32767,-32768),e.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8):L(this,t,n,!0),n+2},e.prototype.writeInt16BE=function(t,n,r){return t=+t,n=0|n,r||P(this,t,n,2,32767,-32768),e.TYPED_ARRAY_SUPPORT?(this[n]=t>>>8,this[n+1]=255&t):L(this,t,n,!1),n+2},e.prototype.writeInt32LE=function(t,n,r){return t=+t,n=0|n,r||P(this,t,n,4,2147483647,-2147483648),e.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8,this[n+2]=t>>>16,this[n+3]=t>>>24):M(this,t,n,!0),n+4},e.prototype.writeInt32BE=function(t,n,r){return t=+t,n=0|n,r||P(this,t,n,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),e.TYPED_ARRAY_SUPPORT?(this[n]=t>>>24,this[n+1]=t>>>16,this[n+2]=t>>>8,this[n+3]=255&t):M(this,t,n,!1),n+4},e.prototype.writeFloatLE=function(e,t,n){return D(this,e,t,!0,n)},e.prototype.writeFloatBE=function(e,t,n){return D(this,e,t,!1,n)},e.prototype.writeDoubleLE=function(e,t,n){return q(this,e,t,!0,n)},e.prototype.writeDoubleBE=function(e,t,n){return q(this,e,t,!1,n)},e.prototype.copy=function(t,n,r,i){if(r||(r=0),i||0===i||(i=this.length),n>=t.length&&(n=t.length),n||(n=0),i>0&&i=this.length)throw new RangeError("sourceStart out of bounds");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),t.length-n=0;--o)t[o+n]=this[o+r];else if(s<1e3||!e.TYPED_ARRAY_SUPPORT)for(o=0;o>>=0,r=void 0===r?this.length:r>>>0,t||(t=0);var s;if("number"==typeof t)for(s=n;s0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");n===-1&&(n=t);var r=n===t?0:4-n%4;return[n,r]}function r(e){var t=n(e),r=t[0],i=t[1];return 3*(r+i)/4-i}function i(e,t,n){return 3*(t+n)/4-n}function o(e){for(var t,r=n(e),o=r[0],s=r[1],a=new f(i(e,o,s)),u=0,c=s>0?o-4:o,h=0;h>16&255,a[u++]=t>>8&255,a[u++]=255&t;return 2===s&&(t=l[e.charCodeAt(h)]<<2|l[e.charCodeAt(h+1)]>>4,a[u++]=255&t),1===s&&(t=l[e.charCodeAt(h)]<<10|l[e.charCodeAt(h+1)]<<4|l[e.charCodeAt(h+2)]>>2,a[u++]=t>>8&255,a[u++]=255&t),a}function s(e){return c[e>>18&63]+c[e>>12&63]+c[e>>6&63]+c[63&e]}function a(e,t,n){for(var r,i=[],o=t;ou?u:s+o));return 1===r?(t=e[n-1],i.push(c[t>>2]+c[t<<4&63]+"==")):2===r&&(t=(e[n-2]<<8)+e[n-1],i.push(c[t>>10]+c[t>>4&63]+c[t<<2&63]+"=")),i.join("")}t.byteLength=r,t.toByteArray=o,t.fromByteArray=u;for(var c=[],l=[],f="undefined"!=typeof Uint8Array?Uint8Array:Array,h="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",p=0,d=h.length;p>1,l=-7,f=n?i-1:0,h=n?-1:1,p=e[t+f];for(f+=h,o=p&(1<<-l)-1,p>>=-l,l+=a;l>0;o=256*o+e[t+f],f+=h,l-=8);for(s=o&(1<<-l)-1,o>>=-l,l+=r;l>0;s=256*s+e[t+f],f+=h,l-=8);if(0===o)o=1-c;else{if(o===u)return s?NaN:(p?-1:1)*(1/0);s+=Math.pow(2,r),o-=c}return(p?-1:1)*s*Math.pow(2,o-r)},t.write=function(e,t,n,r,i,o){var s,a,u,c=8*o-i-1,l=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:o-1,d=r?1:-1,v=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,s=l):(s=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-s))<1&&(s--,u*=2),t+=s+f>=1?h/u:h*Math.pow(2,1-f),t*u>=2&&(s++,u/=2),s+f>=l?(a=0,s=l):s+f>=1?(a=(t*u-1)*Math.pow(2,i),s+=f):(a=t*Math.pow(2,f-1)*Math.pow(2,i),s=0));i>=8;e[n+p]=255&a,p+=d,a/=256,i-=8);for(s=s<0;e[n+p]=255&s,p+=d,s/=256,c-=8);e[n+p-d]|=128*v}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){function r(e,t,n,r){e=o(e)?e:u(e),n=n&&!r?a(n):0;var l=e.length;return n<0&&(n=c(l+n,0)),s(e)?n<=l&&e.indexOf(t,n)>-1:!!l&&i(e,t,n)>-1}var i=n(8),o=n(12),s=n(22),a=n(25),u=n(29),c=Math.max;e.exports=r},function(e,t,n){function r(e,t,n){return t===t?s(e,t,n):i(e,o,n)}var i=n(9),o=n(10),s=n(11);e.exports=r},function(e,t){function n(e,t,n,r){for(var i=e.length,o=n+(r?1:-1);r?o--:++o-1&&e%1==0&&e<=r}var r=9007199254740991;e.exports=n},function(e,t,n){function r(e){return"string"==typeof e||!o(e)&&s(e)&&i(e)==a}var i=n(14),o=n(23),s=n(24),a="[object String]";e.exports=r},function(e,t){var n=Array.isArray;e.exports=n},function(e,t){function n(e){return null!=e&&"object"==typeof e}e.exports=n},function(e,t,n){function r(e){var t=i(e),n=t%1;return t===t?n?t-n:t:0}var i=n(26);e.exports=r},function(e,t,n){function r(e){if(!e)return 0===e?e:0;if(e=i(e),e===o||e===-o){var t=e<0?-1:1;return t*s}return e===e?e:0}var i=n(27),o=1/0,s=1.7976931348623157e308;e.exports=r},function(e,t,n){function r(e){if("number"==typeof e)return e;if(o(e))return s;if(i(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=i(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(a,"");var n=c.test(e);return n||l.test(e)?f(e.slice(2),n?2:8):u.test(e)?s:+e}var i=n(20),o=n(28),s=NaN,a=/^\s+|\s+$/g,u=/^[-+]0x[0-9a-f]+$/i,c=/^0b[01]+$/i,l=/^0o[0-7]+$/i,f=parseInt;e.exports=r},function(e,t,n){function r(e){return"symbol"==typeof e||o(e)&&i(e)==s}var i=n(14),o=n(24),s="[object Symbol]";e.exports=r},function(e,t,n){function r(e){return null==e?[]:i(e,o(e))}var i=n(30),o=n(32);e.exports=r},function(e,t,n){function r(e,t){return i(t,function(t){return e[t]})}var i=n(31);e.exports=r},function(e,t){function n(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++n-1&&e%1==0&&e1){var n,r=new Array(t-1),i=0;for(n=0;n0&&"function"!=typeof e&&"function"!=typeof t){var n=".then() only accepts functions but was passed: "+d.classString(e);arguments.length>1&&(n+=", "+d.classString(t)),this._warn(n)}return this._then(e,t,void 0,void 0,void 0)},o.prototype.done=function(e,t){var n=this._then(e,t,void 0,void 0,void 0);n._setIsFinal()},o.prototype.spread=function(e){return"function"!=typeof e?h("expecting a function but got "+d.classString(e)):this.all()._then(e,void 0,void 0,E,void 0)},o.prototype.toJSON=function(){var e={isFulfilled:!1,isRejected:!1,fulfillmentValue:void 0,rejectionReason:void 0};return this.isFulfilled()?(e.fulfillmentValue=this.value(),e.isFulfilled=!0):this.isRejected()&&(e.rejectionReason=this.reason(),e.isRejected=!0),e},o.prototype.all=function(){return arguments.length>0&&this._warn(".all() was passed arguments but it does not take any"),new I(this).promise()},o.prototype.error=function(e){return this.caught(d.originatesFromRejection,e)},o.getNewLibraryCopy=e.exports,o.is=function(e){return e instanceof o},o.fromNode=o.fromCallback=function(e){var t=new o(w);t._captureStackTrace();var n=arguments.length>1&&!!Object(arguments[1]).multiArgs,r=A(e)(O(t,n));return r===j&&t._rejectCallback(r.e,!0),t._isFateSealed()||t._setAsyncGuaranteed(),t},o.all=function(e){return new I(e).promise()},o.cast=function(e){var t=k(e);return t instanceof o||(t=new o(w),t._captureStackTrace(),t._setFulfilled(),t._rejectionHandler0=e),t},o.resolve=o.fulfilled=o.cast,o.reject=o.rejected=function(e){var t=new o(w);return t._captureStackTrace(),t._rejectCallback(e,!0),t},o.setScheduler=function(e){if("function"!=typeof e)throw new b("expecting a function but got "+d.classString(e));return y.setScheduler(e)},o.prototype._then=function(e,t,n,r,i){var s=void 0!==i,a=s?i:new o(w),u=this._target(),l=u._bitField;s||(a._propagateFrom(this,3),a._captureStackTrace(),void 0===r&&0!==(2097152&this._bitField)&&(r=0!==(50397184&l)?this._boundValue():u===this?void 0:this._boundTo),this._fireEvent("promiseChained",this,a));var f=c();if(0!==(50397184&l)){var h,p,v=u._settlePromiseCtx;0!==(33554432&l)?(p=u._rejectionHandler0,h=e):0!==(16777216&l)?(p=u._fulfillmentHandler0,h=t,u._unsetRejectionIsUnhandled()):(v=u._settlePromiseLateCancellationObserver,p=new _("late cancellation observer"),u._attachExtraTrace(p),h=t),y.invoke(v,u,{handler:null===f?h:"function"==typeof h&&d.domainBind(f,h),promise:a,receiver:r,value:p})}else u._addCallbacks(e,t,a,r,f);return a},o.prototype._length=function(){return 65535&this._bitField},o.prototype._isFateSealed=function(){return 0!==(117506048&this._bitField)},o.prototype._isFollowing=function(){return 67108864===(67108864&this._bitField)},o.prototype._setLength=function(e){this._bitField=this._bitField&-65536|65535&e},o.prototype._setFulfilled=function(){this._bitField=33554432|this._bitField,this._fireEvent("promiseFulfilled",this)},o.prototype._setRejected=function(){this._bitField=16777216|this._bitField,this._fireEvent("promiseRejected",this)},o.prototype._setFollowing=function(){this._bitField=67108864|this._bitField,this._fireEvent("promiseResolved",this)},o.prototype._setIsFinal=function(){this._bitField=4194304|this._bitField},o.prototype._isFinal=function(){return(4194304&this._bitField)>0},o.prototype._unsetCancelled=function(){this._bitField=this._bitField&-65537},o.prototype._setCancelled=function(){this._bitField=65536|this._bitField,this._fireEvent("promiseCancelled",this)},o.prototype._setWillBeCancelled=function(){this._bitField=8388608|this._bitField},o.prototype._setAsyncGuaranteed=function(){y.hasCustomScheduler()||(this._bitField=134217728|this._bitField)},o.prototype._receiverAt=function(e){var t=0===e?this._receiver0:this[4*e-4+3];if(t!==p)return void 0===t&&this._isBound()?this._boundValue():t},o.prototype._promiseAt=function(e){return this[4*e-4+2]},o.prototype._fulfillmentHandlerAt=function(e){return this[4*e-4+0]},o.prototype._rejectionHandlerAt=function(e){return this[4*e-4+1]},o.prototype._boundValue=function(){},o.prototype._migrateCallback0=function(e){var t=(e._bitField,e._fulfillmentHandler0),n=e._rejectionHandler0,r=e._promise0,i=e._receiverAt(0);void 0===i&&(i=p),this._addCallbacks(t,n,r,i,null)},o.prototype._migrateCallbackAt=function(e,t){var n=e._fulfillmentHandlerAt(t),r=e._rejectionHandlerAt(t),i=e._promiseAt(t),o=e._receiverAt(t);void 0===o&&(o=p),this._addCallbacks(n,r,i,o,null)},o.prototype._addCallbacks=function(e,t,n,r,i){var o=this._length();if(o>=65531&&(o=0,this._setLength(0)),0===o)this._promise0=n,this._receiver0=r,"function"==typeof e&&(this._fulfillmentHandler0=null===i?e:d.domainBind(i,e)),"function"==typeof t&&(this._rejectionHandler0=null===i?t:d.domainBind(i,t));else{var s=4*o-4;this[s+2]=n,this[s+3]=r,"function"==typeof e&&(this[s+0]=null===i?e:d.domainBind(i,e)),"function"==typeof t&&(this[s+1]=null===i?t:d.domainBind(i,t))}return this._setLength(o+1),o},o.prototype._proxy=function(e,t){this._addCallbacks(void 0,void 0,t,e,null)},o.prototype._resolveCallback=function(e,t){if(0===(117506048&this._bitField)){if(e===this)return this._rejectCallback(l(),!1);var n=k(e,this);if(!(n instanceof o))return this._fulfill(e);t&&this._propagateFrom(n,2);var r=n._target();if(r===this)return void this._reject(l());var i=r._bitField;if(0===(50397184&i)){var s=this._length();s>0&&r._migrateCallback0(this);for(var a=1;a>>16)){if(e===this){var n=l();return this._attachExtraTrace(n),this._reject(n)}this._setFulfilled(),this._rejectionHandler0=e,(65535&t)>0&&(0!==(134217728&t)?this._settlePromises():y.settlePromises(this))}},o.prototype._reject=function(e){var t=this._bitField;if(!((117506048&t)>>>16))return this._setRejected(),this._fulfillmentHandler0=e,this._isFinal()?y.fatalError(e,d.isNode):void((65535&t)>0?y.settlePromises(this):this._ensurePossibleRejectionHandled())},o.prototype._fulfillPromises=function(e,t){for(var n=1;n0){if(0!==(16842752&e)){var n=this._fulfillmentHandler0;this._settlePromise0(this._rejectionHandler0,n,e),this._rejectPromises(t,n)}else{var r=this._rejectionHandler0;this._settlePromise0(this._fulfillmentHandler0,r,e),this._fulfillPromises(t,r)}this._setLength(0)}this._clearCancellationData()},o.prototype._settledValue=function(){var e=this._bitField;return 0!==(33554432&e)?this._rejectionHandler0:0!==(16777216&e)?this._fulfillmentHandler0:void 0},o.defer=o.pending=function(){T.deprecated("Promise.defer","new Promise");var e=new o(w);return{promise:e,resolve:s,reject:a}},d.notEnumerableProp(o,"_makeSelfResolutionError",l),n(67)(o,w,k,h,T),n(68)(o,w,k,T),n(69)(o,I,h,T),n(70)(o),n(71)(o),n(72)(o,I,k,w,y,c),o.Promise=o,o.version="3.5.1",n(73)(o,I,h,k,w,T),n(74)(o),n(75)(o,h,k,S,w,T),n(76)(o,w,T),n(77)(o,h,w,k,r,T),n(78)(o),n(79)(o,w),n(80)(o,I,k,h),n(81)(o,w,k,h),n(82)(o,I,h,k,w,T),n(83)(o,I,T),n(84)(o,I,h),n(85)(o,w),n(86)(o,w),n(87)(o),d.toFastProperties(o),d.toFastProperties(o.prototype),u({a:1}),u({b:2}),u({c:3}),u(1),u(function(){}),u(void 0),u(!1),u(new o(w)),T.setBounds(g.firstLineError,d.lastLineError),o}}).call(t,n(52))},function(e,t){function n(){throw new Error("setTimeout has not been defined")}function r(){throw new Error("clearTimeout has not been defined")}function i(e){if(l===setTimeout)return setTimeout(e,0);if((l===n||!l)&&setTimeout)return l=setTimeout,setTimeout(e,0);try{return l(e,0)}catch(t){try{return l.call(null,e,0)}catch(t){return l.call(this,e,0)}}}function o(e){if(f===clearTimeout)return clearTimeout(e);if((f===r||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function s(){v&&p&&(v=!1,p.length?d=p.concat(d):g=-1,d.length&&a())}function a(){if(!v){var e=i(s);v=!0;for(var t=d.length;t;){for(p=d,d=[];++g1)for(var n=1;n1,r=t.length>0&&!(1===t.length&&"constructor"===t[0]),i=R.test(e+"")&&S.names(e).length>0;if(n||r||i)return!0}return!1}catch(o){return!1}}function d(e){function t(){}t.prototype=e;for(var n=8;n--;)new t;return e}function v(e){return F.test(e)}function g(e,t,n){for(var r=new Array(e),i=0;i10||e[0]>0}(),q.isNode&&q.toFastProperties(r);try{throw new Error}catch(z){q.lastLineError=z}e.exports=q}).call(t,function(){return this}(),n(52))},function(e,t){var n=function(){"use strict";return void 0===this}();if(n)e.exports={freeze:Object.freeze,defineProperty:Object.defineProperty,getDescriptor:Object.getOwnPropertyDescriptor,keys:Object.keys,names:Object.getOwnPropertyNames,getPrototypeOf:Object.getPrototypeOf,isArray:Array.isArray,isES5:n,propertyIsWritable:function(e,t){var n=Object.getOwnPropertyDescriptor(e,t);return!(n&&!n.writable&&!n.set)}};else{var r={}.hasOwnProperty,i={}.toString,o={}.constructor.prototype,s=function(e){var t=[];for(var n in e)r.call(e,n)&&t.push(n);return t},a=function(e,t){return{value:e[t]}},u=function(e,t,n){return e[t]=n.value,e},c=function(e){return e},l=function(e){try{return Object(e).constructor.prototype}catch(t){return o}},f=function(e){try{return"[object Array]"===i.call(e)}catch(t){return!1}};e.exports={isArray:f,keys:s,names:s,defineProperty:u,getDescriptor:a,freeze:c,getPrototypeOf:l,isES5:n,propertyIsWritable:function(){return!0}}}},function(e,t,n){(function(t){"use strict";function r(){this._customScheduler=!1,this._isTickUsed=!1,this._lateQueue=new l(16),this._normalQueue=new l(16),this._haveDrainedQueues=!1,this._trampolineEnabled=!0;var e=this;this.drainQueues=function(){e._drainQueues()},this._schedule=c}function i(e,t,n){this._lateQueue.push(e,t,n),this._queueTick()}function o(e,t,n){this._normalQueue.push(e,t,n),this._queueTick()}function s(e){this._normalQueue._pushOne(e),this._queueTick()}var a;try{throw new Error}catch(u){a=u}var c=n(56),l=n(58),f=n(53);r.prototype.setScheduler=function(e){var t=this._schedule;return this._schedule=e,this._customScheduler=!0,t},r.prototype.hasCustomScheduler=function(){return this._customScheduler},r.prototype.enableTrampoline=function(){this._trampolineEnabled=!0},r.prototype.disableTrampolineIfNecessary=function(){f.hasDevTools&&(this._trampolineEnabled=!1)},r.prototype.haveItemsQueued=function(){return this._isTickUsed||this._haveDrainedQueues},r.prototype.fatalError=function(e,n){n?(t.stderr.write("Fatal "+(e instanceof Error?e.stack:e)+"\n"),t.exit(2)):this.throwLater(e)},r.prototype.throwLater=function(e,t){if(1===arguments.length&&(t=e,e=function(){throw t}),"undefined"!=typeof setTimeout)setTimeout(function(){e(t)},0);else try{this._schedule(function(){e(t)})}catch(n){throw new Error("No async scheduler available\n\n See http://goo.gl/MqrFmX\n")}},f.hasDevTools?(r.prototype.invokeLater=function(e,t,n){this._trampolineEnabled?i.call(this,e,t,n):this._schedule(function(){setTimeout(function(){e.call(t,n)},100)})},r.prototype.invoke=function(e,t,n){this._trampolineEnabled?o.call(this,e,t,n):this._schedule(function(){e.call(t,n)})},r.prototype.settlePromises=function(e){this._trampolineEnabled?s.call(this,e):this._schedule(function(){e._settlePromises()})}):(r.prototype.invokeLater=i,r.prototype.invoke=o,r.prototype.settlePromises=s),r.prototype._drainQueue=function(e){for(;e.length()>0;){var t=e.shift();if("function"==typeof t){var n=e.shift(),r=e.shift();t.call(n,r)}else t._settlePromises()}},r.prototype._drainQueues=function(){this._drainQueue(this._normalQueue),this._reset(),this._haveDrainedQueues=!0,this._drainQueue(this._lateQueue)},r.prototype._queueTick=function(){this._isTickUsed||(this._isTickUsed=!0,this._schedule(this.drainQueues))},r.prototype._reset=function(){this._isTickUsed=!1},e.exports=r,e.exports.firstLineError=a}).call(t,n(52))},function(e,t,n){(function(t,r,i){"use strict";var o,s=n(53),a=function(){throw new Error("No async scheduler available\n\n See http://goo.gl/MqrFmX\n")},u=s.getNativePromise();if(s.isNode&&"undefined"==typeof MutationObserver){var c=t.setImmediate,l=r.nextTick;o=s.isRecentNode?function(e){c.call(t,e)}:function(e){l.call(r,e)}}else if("function"==typeof u&&"function"==typeof u.resolve){var f=u.resolve();o=function(e){f.then(e)}}else o="undefined"==typeof MutationObserver||"undefined"!=typeof window&&window.navigator&&(window.navigator.standalone||window.cordova)?"undefined"!=typeof i?function(e){i(e)}:"undefined"!=typeof setTimeout?function(e){setTimeout(e,0)}:a:function(){var e=document.createElement("div"),t={attributes:!0},n=!1,r=document.createElement("div"),i=new MutationObserver(function(){e.classList.toggle("foo"),n=!1});i.observe(r,t);var o=function(){n||(n=!0,r.classList.toggle("foo"))};return function(n){var r=new MutationObserver(function(){r.disconnect(),n()});r.observe(e,t),o()}}();e.exports=o}).call(t,function(){return this}(),n(52),n(57).setImmediate)},function(e,t,n){(function(e,r){function i(e,t){this._id=e,this._clearFn=t}var o=n(52).nextTick,s=Function.prototype.apply,a=Array.prototype.slice,u={},c=0;t.setTimeout=function(){return new i(s.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new i(s.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var n=c++,r=!(arguments.length<2)&&a.call(arguments,1);return u[n]=!0,o(function(){u[n]&&(r?e.apply(null,r):e.call(null),t.clearImmediate(n))}),n},t.clearImmediate="function"==typeof r?r:function(e){delete u[e]}}).call(t,n(57).setImmediate,n(57).clearImmediate)},function(e,t){"use strict";function n(e,t,n,r,i){for(var o=0;o=this._length&&(this._resolve(this._values),!0)},a.prototype._promiseCancelled=function(){return this._cancel(),!0},a.prototype._promiseRejected=function(e){return this._totalResolved++,this._reject(e),!0},a.prototype._resultCancelled=function(){if(!this._isResolved()){var t=this._values;if(this._cancel(),t instanceof e)t.cancel();else for(var n=0;n=0)return o[e]}var i=!1,o=[];return e.prototype._promiseCreated=function(){},e.prototype._pushContext=function(){},e.prototype._popContext=function(){return null},e._peekContext=e.prototype._peekContext=function(){},t.prototype._pushContext=function(){void 0!==this._trace&&(this._trace._promiseCreated=null,o.push(this._trace))},t.prototype._popContext=function(){if(void 0!==this._trace){var e=o.pop(),t=e._promiseCreated;return e._promiseCreated=null,t}return null},t.CapturedTrace=null,t.create=n,t.deactivateLongStackTraces=function(){},t.activateLongStackTraces=function(){var n=e.prototype._pushContext,o=e.prototype._popContext,s=e._peekContext,a=e.prototype._peekContext,u=e.prototype._promiseCreated;t.deactivateLongStackTraces=function(){e.prototype._pushContext=n,e.prototype._popContext=o,e._peekContext=s,e.prototype._peekContext=a,e.prototype._promiseCreated=u,i=!1},i=!0,e.prototype._pushContext=t.prototype._pushContext,e.prototype._popContext=t.prototype._popContext,e._peekContext=e.prototype._peekContext=r,e.prototype._promiseCreated=function(){var e=this._peekContext();e&&null==e._promiseCreated&&(e._promiseCreated=this)}},t}},function(e,t,n){(function(t){"use strict";e.exports=function(e,r){function i(e,t){return{promise:t}}function o(){return!1}function s(e,t,n){var r=this;try{e(t,n,function(e){if("function"!=typeof e)throw new TypeError("onCancel must be a function, got: "+N.toString(e));r._attachCancellationCallback(e)})}catch(i){return i}}function a(e){if(!this._isCancellable())return this;var t=this._onCancel();void 0!==t?N.isArray(t)?t.push(e):this._setOnCancel([t,e]):this._setOnCancel(e)}function u(){return this._onCancelField}function c(e){this._onCancelField=e}function l(){this._cancellationParent=void 0,this._onCancelField=void 0}function f(e,t){if(0!==(1&t)){this._cancellationParent=e;var n=e._branchesRemainingToCancel;void 0===n&&(n=0),e._branchesRemainingToCancel=n+1}0!==(2&t)&&e._isBound()&&this._setBoundTo(e._boundTo)}function h(e,t){0!==(2&t)&&e._isBound()&&this._setBoundTo(e._boundTo)}function p(){var t=this._boundTo;return void 0!==t&&t instanceof e?t.isFulfilled()?t.value():void 0:t}function d(){this._trace=new j(this._peekContext())}function v(e,t){if(D(e)){var n=this._trace;if(void 0!==n&&t&&(n=n._parent),void 0!==n)n.attachExtraTrace(e);else if(!e.__stackCleaned__){var r=k(e);N.notEnumerableProp(e,"stack",r.message+"\n"+r.stack.join("\n")),N.notEnumerableProp(e,"__stackCleaned__",!0)}}}function g(e,t,n,r,i){if(void 0===e&&null!==t&&$){if(void 0!==i&&i._returnedNonUndefined())return;if(0===(65535&r._bitField))return;n&&(n+=" ");var o="",s="";if(t._trace){for(var a=t._trace.stack.split("\n"),u=E(a),c=u.length-1;c>=0;--c){var l=u[c];if(!z.test(l)){var f=l.match(H);f&&(o="at "+f[1]+":"+f[2]+":"+f[3]+" ");break}}if(u.length>0)for(var h=u[0],c=0;c0&&(s="\n"+a[c-1]);break}}var p="a promise was created in a "+n+"handler "+o+"but was not returned from it, see http://goo.gl/rRqMUw"+s;r._warn(p,!0,t)}}function y(e,t){var n=e+" is deprecated and will be removed in a future version.";return t&&(n+=" Use "+t+" instead."),m(n)}function m(t,n,r){if(se.warnings){ +var i,o=new M(t);if(n)r._attachExtraTrace(o);else if(se.longStackTraces&&(i=e._peekContext()))i.attachExtraTrace(o);else{var s=k(o);o.stack=s.message+"\n"+s.stack.join("\n")}te("warning",o)||I(o,"",!0)}}function b(e,t){for(var n=0;n=0;--a)if(r[a]===o){s=a;break}for(var a=s;a>=0;--a){var u=r[a];if(t[i]!==u)break;t.pop(),i--}t=r}}function E(e){for(var t=[],n=0;n0&&"SyntaxError"!=e.name&&(t=t.slice(n)),t}function k(e){var t=e.stack,n=e.toString();return t="string"==typeof t&&t.length>0?x(e):[" (No stack trace)"],{message:n,stack:"SyntaxError"==e.name?t:E(t)}}function I(e,t,n){if("undefined"!=typeof console){var r;if(N.isObject(e)){var i=e.stack;r=t+W(i,e)}else r=t+String(e);"function"==typeof F?F(r,n):"function"!=typeof console.log&&"object"!=typeof console.log||console.log(r)}}function C(e,t,n,r){var i=!1;try{"function"==typeof t&&(i=!0,"rejectionHandled"===e?t(r):t(n,r))}catch(o){L.throwLater(o)}"unhandledRejection"===e?te(e,n,r)||i||I(n,"Unhandled rejection "):te(e,r)}function S(e){var t;if("function"==typeof e)t="[function "+(e.name||"anonymous")+"]";else{t=e&&"function"==typeof e.toString?e.toString():N.toString(e);var n=/\[object [a-zA-Z0-9$_]+\]/;if(n.test(t))try{var r=JSON.stringify(e);t=r}catch(i){}0===t.length&&(t="(empty array)")}return"(<"+T(t)+">, no stack trace)"}function T(e){var t=41;return e.length=a||(re=function(e){if(q.test(e))return!0;var t=U(e);return!!(t&&t.fileName===n&&s<=t.line&&t.line<=a)})}}function j(e){this._parent=e,this._promisesCreated=0;var t=this._length=1+(void 0===e?0:e._length);oe(this,j),t>32&&this.uncycle()}var A,R,F,P=e._getDomain,L=e._async,M=n(59).Warning,N=n(53),D=N.canAttachTrace,q=/[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/,z=/\((?:timers\.js):\d+:\d+\)/,H=/[\/<\(](.+?):(\d+):(\d+)\)?\s*$/,Q=null,W=null,K=!1,V=!(0==N.env("BLUEBIRD_DEBUG")||!N.env("BLUEBIRD_DEBUG")&&"development"!==N.env("NODE_ENV")),G=!(0==N.env("BLUEBIRD_WARNINGS")||!V&&!N.env("BLUEBIRD_WARNINGS")),Y=!(0==N.env("BLUEBIRD_LONG_STACK_TRACES")||!V&&!N.env("BLUEBIRD_LONG_STACK_TRACES")),$=0!=N.env("BLUEBIRD_W_FORGOTTEN_RETURN")&&(G||!!N.env("BLUEBIRD_W_FORGOTTEN_RETURN"));e.prototype.suppressUnhandledRejections=function(){var e=this._target();e._bitField=e._bitField&-1048577|524288},e.prototype._ensurePossibleRejectionHandled=function(){if(0===(524288&this._bitField)){this._setRejectionIsUnhandled();var e=this;setTimeout(function(){e._notifyUnhandledRejection()},1)}},e.prototype._notifyUnhandledRejectionIsHandled=function(){C("rejectionHandled",A,void 0,this)},e.prototype._setReturnedNonUndefined=function(){this._bitField=268435456|this._bitField},e.prototype._returnedNonUndefined=function(){return 0!==(268435456&this._bitField)},e.prototype._notifyUnhandledRejection=function(){if(this._isRejectionUnhandled()){var e=this._settledValue();this._setUnhandledRejectionIsNotified(),C("unhandledRejection",R,e,this)}},e.prototype._setUnhandledRejectionIsNotified=function(){this._bitField=262144|this._bitField},e.prototype._unsetUnhandledRejectionIsNotified=function(){this._bitField=this._bitField&-262145},e.prototype._isUnhandledRejectionNotified=function(){return(262144&this._bitField)>0},e.prototype._setRejectionIsUnhandled=function(){this._bitField=1048576|this._bitField},e.prototype._unsetRejectionIsUnhandled=function(){this._bitField=this._bitField&-1048577,this._isUnhandledRejectionNotified()&&(this._unsetUnhandledRejectionIsNotified(),this._notifyUnhandledRejectionIsHandled())},e.prototype._isRejectionUnhandled=function(){return(1048576&this._bitField)>0},e.prototype._warn=function(e,t,n){return m(e,t,n||this)},e.onPossiblyUnhandledRejection=function(e){var t=P();R="function"==typeof e?null===t?e:N.domainBind(t,e):void 0},e.onUnhandledRejectionHandled=function(e){var t=P();A="function"==typeof e?null===t?e:N.domainBind(t,e):void 0};var X=function(){};e.longStackTraces=function(){if(L.haveItemsQueued()&&!se.longStackTraces)throw new Error("cannot enable long stack traces after promises have been created\n\n See http://goo.gl/MqrFmX\n");if(!se.longStackTraces&&B()){var t=e.prototype._captureStackTrace,n=e.prototype._attachExtraTrace;se.longStackTraces=!0,X=function(){if(L.haveItemsQueued()&&!se.longStackTraces)throw new Error("cannot enable long stack traces after promises have been created\n\n See http://goo.gl/MqrFmX\n");e.prototype._captureStackTrace=t,e.prototype._attachExtraTrace=n,r.deactivateLongStackTraces(),L.enableTrampoline(),se.longStackTraces=!1},e.prototype._captureStackTrace=d,e.prototype._attachExtraTrace=v,r.activateLongStackTraces(),L.disableTrampolineIfNecessary()}},e.hasLongStackTraces=function(){return se.longStackTraces&&B()};var J=function(){try{if("function"==typeof CustomEvent){var e=new CustomEvent("CustomEvent");return N.global.dispatchEvent(e),function(e,t){var n=new CustomEvent(e.toLowerCase(),{detail:t,cancelable:!0});return!N.global.dispatchEvent(n)}}if("function"==typeof Event){var e=new Event("CustomEvent");return N.global.dispatchEvent(e),function(e,t){var n=new Event(e.toLowerCase(),{cancelable:!0});return n.detail=t,!N.global.dispatchEvent(n)}}var e=document.createEvent("CustomEvent");return e.initCustomEvent("testingtheevent",!1,!0,{}),N.global.dispatchEvent(e),function(e,t){var n=document.createEvent("CustomEvent");return n.initCustomEvent(e.toLowerCase(),!1,!0,t),!N.global.dispatchEvent(n)}}catch(t){}return function(){return!1}}(),Z=function(){return N.isNode?function(){return t.emit.apply(t,arguments)}:N.global?function(e){var t="on"+e.toLowerCase(),n=N.global[t];return!!n&&(n.apply(N.global,[].slice.call(arguments,1)),!0)}:function(){return!1}}(),ee={promiseCreated:i,promiseFulfilled:i,promiseRejected:i,promiseResolved:i,promiseCancelled:i,promiseChained:function(e,t,n){return{promise:t,child:n}},warning:function(e,t){return{warning:t}},unhandledRejection:function(e,t,n){return{reason:t,promise:n}},rejectionHandled:i},te=function(e){var t=!1;try{t=Z.apply(null,arguments)}catch(n){L.throwLater(n),t=!0}var r=!1;try{r=J(e,ee[e].apply(null,arguments))}catch(n){L.throwLater(n),r=!0}return r||t};e.config=function(t){if(t=Object(t),"longStackTraces"in t&&(t.longStackTraces?e.longStackTraces():!t.longStackTraces&&e.hasLongStackTraces()&&X()),"warnings"in t){var n=t.warnings;se.warnings=!!n,$=se.warnings,N.isObject(n)&&"wForgottenReturn"in n&&($=!!n.wForgottenReturn)}if("cancellation"in t&&t.cancellation&&!se.cancellation){if(L.haveItemsQueued())throw new Error("cannot enable cancellation after promises are in use");e.prototype._clearCancellationData=l,e.prototype._propagateFrom=f,e.prototype._onCancel=u,e.prototype._setOnCancel=c,e.prototype._attachCancellationCallback=a,e.prototype._execute=s,ne=f,se.cancellation=!0}return"monitoring"in t&&(t.monitoring&&!se.monitoring?(se.monitoring=!0,e.prototype._fireEvent=te):!t.monitoring&&se.monitoring&&(se.monitoring=!1,e.prototype._fireEvent=o)),e},e.prototype._fireEvent=o,e.prototype._execute=function(e,t,n){try{e(t,n)}catch(r){return r}},e.prototype._onCancel=function(){},e.prototype._setOnCancel=function(e){},e.prototype._attachCancellationCallback=function(e){},e.prototype._captureStackTrace=function(){},e.prototype._attachExtraTrace=function(){},e.prototype._clearCancellationData=function(){},e.prototype._propagateFrom=function(e,t){};var ne=h,re=function(){return!1},ie=/[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/;N.inherits(j,Error),r.CapturedTrace=j,j.prototype.uncycle=function(){var e=this._length;if(!(e<2)){for(var t=[],n={},r=0,i=this;void 0!==i;++r)t.push(i),i=i._parent;e=this._length=r;for(var r=e-1;r>=0;--r){var o=t[r].stack;void 0===n[o]&&(n[o]=r)}for(var r=0;r0&&(t[a-1]._parent=void 0,t[a-1]._length=1),t[r]._parent=void 0,t[r]._length=1;var u=r>0?t[r-1]:this;a=0;--l)t[l]._length=c,c++;return}}}},j.prototype.attachExtraTrace=function(e){if(!e.__stackCleaned__){this.uncycle();for(var t=k(e),n=t.message,r=[t.stack],i=this;void 0!==i;)r.push(E(i.stack.split("\n"))),i=i._parent;w(r),_(r),N.notEnumerableProp(e,"stack",b(n,r)),N.notEnumerableProp(e,"__stackCleaned__",!0)}};var oe=function(){var e=/^\s*at\s*/,t=function(e,t){return"string"==typeof e?e:void 0!==t.name&&void 0!==t.message?t.toString():S(t)};if("number"==typeof Error.stackTraceLimit&&"function"==typeof Error.captureStackTrace){Error.stackTraceLimit+=6,Q=e,W=t;var n=Error.captureStackTrace;return re=function(e){return q.test(e)},function(e,t){Error.stackTraceLimit+=6,n(e,t),Error.stackTraceLimit-=6}}var r=new Error;if("string"==typeof r.stack&&r.stack.split("\n")[0].indexOf("stackDetection@")>=0)return Q=/@/,W=t,K=!0,function(e){e.stack=(new Error).stack};var i;try{throw new Error}catch(o){i="stack"in o}return"stack"in r||!i||"number"!=typeof Error.stackTraceLimit?(W=function(e,t){return"string"==typeof e?e:"object"!=typeof t&&"function"!=typeof t||void 0===t.name||void 0===t.message?S(t):t.toString()},null):(Q=e,W=t,function(e){Error.stackTraceLimit+=6;try{throw new Error}catch(t){e.stack=t.stack}Error.stackTraceLimit-=6})}([]);"undefined"!=typeof console&&"undefined"!=typeof console.warn&&(F=function(e){console.warn(e)},N.isNode&&t.stderr.isTTY?F=function(e,t){var n=t?"":"";console.warn(n+e+"\n")}:N.isNode||"string"!=typeof(new Error).stack||(F=function(e,t){console.warn("%c"+e,t?"color: darkorange":"color: red")}));var se={warnings:G,longStackTraces:!1,cancellation:!1,monitoring:!1};return Y&&e.longStackTraces(),{longStackTraces:function(){return se.longStackTraces},warnings:function(){return se.warnings},cancellation:function(){return se.cancellation},monitoring:function(){return se.monitoring},propagateFromFunction:function(){return ne},boundValueFunction:function(){return p},checkForgottenReturns:g,setBounds:O,warn:m,deprecated:y,CapturedTrace:j,fireDomEvent:J,fireGlobalEvent:Z}}}).call(t,n(52))},function(e,t,n){"use strict";e.exports=function(e,t,r){function i(e,t,n){this.promise=e,this.type=t,this.handler=n,this.called=!1,this.cancelPromise=null}function o(e){this.finallyHandler=e}function s(e,t){return null!=e.cancelPromise&&(arguments.length>1?e.cancelPromise._reject(t):e.cancelPromise._cancel(),e.cancelPromise=null,!0)}function a(){return c.call(this,this.promise._target()._settledValue())}function u(e){if(!s(this,e))return h.e=e,h}function c(n){var i=this.promise,c=this.handler;if(!this.called){this.called=!0;var l=this.isFinallyHandler()?c.call(i._boundValue()):c.call(i._boundValue(),n);if(l===r)return l;if(void 0!==l){i._setReturnedNonUndefined();var p=t(l,i);if(p instanceof e){if(null!=this.cancelPromise){if(p._isCancelled()){var d=new f("late cancellation observer");return i._attachExtraTrace(d),h.e=d,h}p.isPending()&&p._attachCancellationCallback(new o(this))}return p._then(a,u,void 0,this,void 0)}}}return i.isRejected()?(s(this),h.e=n,h):(s(this),n)}var l=n(53),f=e.CancellationError,h=l.errorObj,p=n(65)(r);return i.prototype.isFinallyHandler=function(){return 0===this.type},o.prototype._resultCancelled=function(){s(this.finallyHandler)},e.prototype._passThrough=function(e,t,n,r){return"function"!=typeof e?this.then():this._then(n,r,void 0,new i(this,t,e),void 0)},e.prototype.lastly=e.prototype["finally"]=function(e){return this._passThrough(e,0,c,c)},e.prototype.tap=function(e){return this._passThrough(e,1,c)},e.prototype.tapCatch=function(t){var n=arguments.length;if(1===n)return this._passThrough(t,1,void 0,c);var r,i=new Array(n-1),o=0;for(r=0;r1){o.deprecated("calling Promise.try with more than 1 argument");var c=arguments[1],l=arguments[2];u=s.isArray(c)?a(n).apply(l,c):a(n).call(l,c)}else u=a(n)();var f=r._popContext();return o.checkForgottenReturns(u,f,"Promise.try",r),r._resolveFromSyncValue(u),r},e.prototype._resolveFromSyncValue=function(e){e===s.errorObj?this._rejectCallback(e.e,!1):this._resolveCallback(e,!0)}}},function(e,t){"use strict";e.exports=function(e,t,n,r){var i=!1,o=function(e,t){this._reject(t)},s=function(e,t){t.promiseRejectionQueued=!0,t.bindingPromise._then(o,o,null,this,e)},a=function(e,t){0===(50397184&this._bitField)&&this._resolveCallback(t.target)},u=function(e,t){t.promiseRejectionQueued||this._reject(e)};e.prototype.bind=function(o){i||(i=!0,e.prototype._propagateFrom=r.propagateFromFunction(),e.prototype._boundValue=r.boundValueFunction());var c=n(o),l=new e(t);l._propagateFrom(this,1);var f=this._target();if(l._setBoundTo(c),c instanceof e){var h={promiseRejectionQueued:!1,promise:l,target:f,bindingPromise:c};f._then(t,s,void 0,l,h),c._then(a,u,void 0,l,h),l._setOnCancel(c)}else l._resolveCallback(f);return l},e.prototype._setBoundTo=function(e){void 0!==e?(this._bitField=2097152|this._bitField,this._boundTo=e):this._bitField=this._bitField&-2097153},e.prototype._isBound=function(){return 2097152===(2097152&this._bitField)},e.bind=function(t,n){return e.resolve(n).bind(t)}}},function(e,t,n){"use strict";e.exports=function(e,t,r,i){var o=n(53),s=o.tryCatch,a=o.errorObj,u=e._async;e.prototype["break"]=e.prototype.cancel=function(){if(!i.cancellation())return this._warn("cancellation is disabled");for(var e=this,t=e;e._isCancellable();){if(!e._cancelBy(t)){t._isFollowing()?t._followee().cancel():t._cancelBranched();break}var n=e._cancellationParent;if(null==n||!n._isCancellable()){e._isFollowing()?e._followee().cancel():e._cancelBranched();break}e._isFollowing()&&e._followee().cancel(),e._setWillBeCancelled(),t=e,e=n}},e.prototype._branchHasCancelled=function(){this._branchesRemainingToCancel--},e.prototype._enoughBranchesHaveCancelled=function(){return void 0===this._branchesRemainingToCancel||this._branchesRemainingToCancel<=0},e.prototype._cancelBy=function(e){return e===this?(this._branchesRemainingToCancel=0,this._invokeOnCancel(),!0):(this._branchHasCancelled(),!!this._enoughBranchesHaveCancelled()&&(this._invokeOnCancel(),!0))},e.prototype._cancelBranched=function(){this._enoughBranchesHaveCancelled()&&this._cancel()},e.prototype._cancel=function(){this._isCancellable()&&(this._setCancelled(),u.invoke(this._cancelPromises,this,void 0))},e.prototype._cancelPromises=function(){this._length()>0&&this._settlePromises()},e.prototype._unsetOnCancel=function(){this._onCancelField=void 0},e.prototype._isCancellable=function(){return this.isPending()&&!this._isCancelled()},e.prototype.isCancellable=function(){return this.isPending()&&!this.isCancelled()},e.prototype._doInvokeOnCancel=function(e,t){if(o.isArray(e))for(var n=0;n0&&"function"==typeof arguments[o]&&(n=arguments[o],o<=8&&c)){var l=new e(i);l._captureStackTrace();for(var f=v[o-1],h=new f(n),p=g,d=0;d=1?s:0,new a(t,n,s,o).promise()}var c=e._getDomain,l=n(53),f=l.tryCatch,h=l.errorObj,p=e._async;l.inherits(a,t),a.prototype._asyncInit=function(){this._init$(void 0,-2)},a.prototype._init=function(){},a.prototype._promiseFulfilled=function(t,n){var r=this._values,o=this.length(),a=this._preservedValues,u=this._limit;if(n<0){if(n=n*-1-1,r[n]=t,u>=1&&(this._inFlight--,this._drainQueue(),this._isResolved()))return!0}else{if(u>=1&&this._inFlight>=u)return r[n]=t,this._queue.push(n),!1;null!==a&&(a[n]=t);var c=this._promise,l=this._callback,p=c._boundValue();c._pushContext();var d=f(l).call(p,t,n,o),v=c._popContext();if(s.checkForgottenReturns(d,v,null!==a?"Promise.filter":"Promise.map",c),d===h)return this._reject(d.e),!0;var g=i(d,this._promise);if(g instanceof e){g=g._target();var y=g._bitField;if(0===(50397184&y))return u>=1&&this._inFlight++,r[n]=g,g._proxy(this,(n+1)*-1),!1;if(0===(33554432&y))return 0!==(16777216&y)?(this._reject(g._reason()),!0):(this._cancel(),!0);d=g._value()}r[n]=d}var m=++this._totalResolved;return m>=o&&(null!==a?this._filter(r,a):this._resolve(r),!0)},a.prototype._drainQueue=function(){for(var e=this._queue,t=this._limit,n=this._values;e.length>0&&this._inFlight512){for(var i=Object.keys(n),o=0;o<256;++o)delete n[i[o]];n[" size"]=i.length-256}}return r};u=function(e){return v(e,p,i)},c=function(e){return v(e,d,o)},e.prototype.call=function(e){for(var t=arguments.length,n=new Array(Math.max(t-1,0)),i=1;i=c)return l._fulfill();var o=u(t[s++]);if(o instanceof e&&o._isDisposable()){try{o=r(o._getDisposer().tryDispose(n),t.promise)}catch(f){return a(f)}if(o instanceof e)return o._then(i,a,null,null,null)}i()}var s=0,c=t.length,l=new e(o); +return i(),l}function l(e,t,n){this._data=e,this._promise=t,this._context=n}function f(e,t,n){this.constructor$(e,t,n)}function h(e){return l.isDisposer(e)?(this.resources[this.index]._setDisposable(e),e.promise()):e}function p(e){this.length=e,this.promise=null,this[e-1]=null}var d=n(53),v=n(59).TypeError,g=n(53).inherits,y=d.errorObj,m=d.tryCatch,b={};l.prototype.data=function(){return this._data},l.prototype.promise=function(){return this._promise},l.prototype.resource=function(){return this.promise().isFulfilled()?this.promise().value():b},l.prototype.tryDispose=function(e){var t=this.resource(),n=this._context;void 0!==n&&n._pushContext();var r=t!==b?this.doDispose(t,e):null;return void 0!==n&&n._popContext(),this._promise._unsetDisposable(),this._data=null,r},l.isDisposer=function(e){return null!=e&&"function"==typeof e.resource&&"function"==typeof e.tryDispose},g(f,l),f.prototype.doDispose=function(e,t){var n=this.data();return n.call(e,e,t)},p.prototype._resultCancelled=function(){for(var t=this.length,n=0;n0},e.prototype._getDisposer=function(){return this._disposer},e.prototype._unsetDisposable=function(){this._bitField=this._bitField&-131073,this._disposer=void 0},e.prototype.disposer=function(e){if("function"==typeof e)return new f(e,this,i());throw new v}}},function(e,t,n){"use strict";e.exports=function(e,t,r){function i(e){this.handle=e}function o(e){return clearTimeout(this.handle),e}function s(e){throw clearTimeout(this.handle),e}var a=n(53),u=e.TimeoutError;i.prototype._resultCancelled=function(){clearTimeout(this.handle)};var c=function(e){return l(+this).thenReturn(e)},l=e.delay=function(n,o){var s,a;return void 0!==o?(s=e.resolve(o)._then(c,null,null,n,void 0),r.cancellation()&&o instanceof e&&s._setOnCancel(o)):(s=new e(t),a=setTimeout(function(){s._fulfill()},+n),r.cancellation()&&s._setOnCancel(new i(a)),s._captureStackTrace()),s._setAsyncGuaranteed(),s};e.prototype.delay=function(e){return l(e,this)};var f=function(e,t,n){var r;r="string"!=typeof t?t instanceof Error?t:new u("operation timed out"):new u(t),a.markAsOriginatingFromRejection(r),e._attachExtraTrace(r),e._reject(r),null!=n&&n.cancel()};e.prototype.timeout=function(e,t){e=+e;var n,a,u=new i(setTimeout(function(){n.isPending()&&f(n,t,a)},e));return r.cancellation()?(a=this.then(),n=a._then(o,s,void 0,u,void 0),n._setOnCancel(u)):n=this._then(o,s,void 0,u,void 0),n}}},function(e,t,n){"use strict";e.exports=function(e,t,r,i,o,s){function a(t,n,r){for(var o=0;o=n;--r)t.push(r);for(var r=e+1;r<=3;++r)t.push(r);return t},C=function(e){return p.filledRange(e,"_arg","")},S=function(e){return p.filledRange(Math.max(e,3),"_arg","")},T=function(e){return"number"==typeof e.length?Math.max(Math.min(e.length,1024),0):0};f=function(n,r,i,o,s,a){function u(e){var t,n=C(e).join(", "),i=e>0?", ":"";return t=y?"ret = callback.call(this, {{args}}, nodeback); break;\n":void 0===r?"ret = callback({{args}}, nodeback); break;\n":"ret = callback.call(receiver, {{args}}, nodeback); break;\n",t.replace("{{args}}",n).replace(", ",i)}function c(){for(var e="",t=0;t=this._length){var r;if(this._isMap)r=h(this._values);else{r={};for(var i=this.length(),o=0,s=this.length();o>1},e.prototype.props=function(){return s(this)},e.props=function(e){return s(e)}}},function(e,t,n){"use strict";e.exports=function(e,t,r,i){function o(n,o){var u=r(n);if(u instanceof e)return a(u);if(n=s.asArray(n),null===n)return i("expecting an array or an iterable object but got "+s.classString(n));var c=new e(t);void 0!==o&&c._propagateFrom(o,3);for(var l=c._fulfill,f=c._reject,h=0,p=n.length;h=this._length&&(this._resolve(this._values),!0)},i.prototype._promiseFulfilled=function(e,t){var n=new o;return n._bitField=33554432,n._settledValueField=e,this._promiseResolved(t,n)},i.prototype._promiseRejected=function(e,t){var n=new o;return n._bitField=16777216,n._settledValueField=e,this._promiseResolved(t,n)},e.settle=function(e){return r.deprecated(".settle()",".reflect()"),new i(e).promise()},e.prototype.settle=function(){return e.settle(this)}}},function(e,t,n){"use strict";e.exports=function(e,t,r){function i(e){this.constructor$(e),this._howMany=0,this._unwrap=!1,this._initialized=!1}function o(e,t){if((0|t)!==t||t<0)return r("expecting a positive integer\n\n See http://goo.gl/MqrFmX\n");var n=new i(e),o=n.promise();return n.setHowMany(t),n.init(),o}var s=n(53),a=n(59).RangeError,u=n(59).AggregateError,c=s.isArray,l={};s.inherits(i,t),i.prototype._init=function(){if(this._initialized){if(0===this._howMany)return void this._resolve([]);this._init$(void 0,-5);var e=c(this._values);!this._isResolved()&&e&&this._howMany>this._canPossiblyFulfill()&&this._reject(this._getRangeError(this.length()))}},i.prototype.init=function(){this._initialized=!0,this._init()},i.prototype.setUnwrap=function(){this._unwrap=!0},i.prototype.howMany=function(){return this._howMany},i.prototype.setHowMany=function(e){this._howMany=e},i.prototype._promiseFulfilled=function(e){return this._addFulfilled(e),this._fulfilled()===this.howMany()&&(this._values.length=this.howMany(),1===this.howMany()&&this._unwrap?this._resolve(this._values[0]):this._resolve(this._values),!0)},i.prototype._promiseRejected=function(e){return this._addRejected(e),this._checkOutcome()},i.prototype._promiseCancelled=function(){return this._values instanceof e||null==this._values?this._cancel():(this._addRejected(l),this._checkOutcome())},i.prototype._checkOutcome=function(){if(this.howMany()>this._canPossiblyFulfill()){for(var e=new u,t=this.length();t0?this._reject(e):this._cancel(),!0}return!1},i.prototype._fulfilled=function(){return this._totalResolved},i.prototype._rejected=function(){return this._values.length-this.length()},i.prototype._addRejected=function(e){this._values.push(e)},i.prototype._addFulfilled=function(e){this._values[this._totalResolved++]=e},i.prototype._canPossiblyFulfill=function(){return this.length()-this._rejected()},i.prototype._getRangeError=function(e){var t="Input array must contain at least "+this._howMany+" items but contains only "+e+" items";return new a(t)},i.prototype._resolveEmptyArray=function(){this._reject(this._getRangeError(0))},e.some=function(e,t){return o(e,t)},e.prototype.some=function(e){return o(this,e)},e._SomePromiseArray=i}},function(e,t){"use strict";e.exports=function(e,t){var n=e.map;e.prototype.filter=function(e,r){return n(this,e,r,t)},e.filter=function(e,r,i){return n(e,r,i,t)}}},function(e,t){"use strict";e.exports=function(e,t){function n(){return o(this)}function r(e,n){return i(e,n,t,t)}var i=e.reduce,o=e.all;e.prototype.each=function(e){return i(this,e,t,0)._then(n,void 0,void 0,this,void 0)},e.prototype.mapSeries=function(e){return i(this,e,t,t)},e.each=function(e,r){return i(e,r,t,0)._then(n,void 0,void 0,e,void 0)},e.mapSeries=r}},function(e,t){"use strict";e.exports=function(e){function t(e){var t=new n(e),r=t.promise();return t.setHowMany(1),t.setUnwrap(),t.init(),r}var n=e._SomePromiseArray;e.any=function(e){return t(e)},e.prototype.any=function(){return t(this)}}},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(e){function t(e,t,n,r){var i=k.resolve(e);return arguments.length<2?i:i.then(t,n,r)}function r(e){return new k(e)}function i(e){return function(){for(var t=0,n=arguments.length,r=new Array(n);t>>0,c=u,l=[],f=0;f0){a.become(i),e._visitRemaining(t,f,i);break}i.visit(a,n,r)}else--c;return 0===c&&a.reject(new RangeError("any(): array must not be empty")),s}function i(t,n){function r(e){this.resolved||(l.push(e),0===--p&&(f=null,this.resolve(l)))}function i(e){this.resolved||(f.push(e),0===--o&&(l=null,this.reject(f)))}var o,s,a,u=e._defer(),c=u._handler,l=[],f=[],h=t.length>>>0,p=0;for(a=0;ap?c.reject(new RangeError("some(): array must contain at least "+n+" item(s), but had "+p)):0===p&&c.resolve(l),a=0;a2?g.call(e,h(t),arguments[2]):g.call(e,h(t))}function f(e,t){return arguments.length>2?y.call(e,h(t),arguments[2]):y.call(e,h(t))}function h(e){return function(t,n,r){return p(e,void 0,[t,n,r])}}var p=r(e),d=e.resolve,v=e.all,g=Array.prototype.reduce,y=Array.prototype.reduceRight,m=Array.prototype.slice;return e.any=n,e.some=i,e.settle=u,e.map=o,e.filter=s,e.reduce=l,e.reduceRight=f,e.prototype.spread=function(e){return this.then(v).then(function(t){return e.apply(this,t)})},e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(){function e(){return{state:"pending"}}function t(e){return{state:"rejected",reason:e}}function n(e){return{state:"fulfilled",value:e}}function r(r){var i=r.state();return 0===i?e():i>0?n(r.value):t(r.value)}return{pending:e,fulfilled:n,rejected:t,inspect:r}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(){function e(e,n){function r(t,r,o){var s=e._defer(),a=o.length,u=new Array(a);return i({f:t,thisArg:r,args:o,params:u,i:a-1,call:n},s._handler),s}function i(t,r){if(t.i<0)return n(t.f,t.thisArg,t.params,r);var i=e._handler(t.args[t.i]);i.fold(o,t,void 0,r)}function o(e,t,n){e.params[e.i]=t,e.i-=1,i(e,n)}return arguments.length<2&&(n=t),r}function t(e,t,n,r){try{r.resolve(e.apply(t,n))}catch(i){r.reject(i)}}return e.tryCatchResolve=t,e}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(){function e(){throw new TypeError("catch predicate must be a function")}function t(e,t){return n(t)?e instanceof t:t(e)}function n(e){return e===Error||null!=e&&e.prototype instanceof Error}function r(e){return("object"==typeof e||"function"==typeof e)&&null!==e}function i(e){return e}return function(n){function o(e,n){return function(r){return t(r,n)?e.call(this,r):c(r)}}function s(e,t,n,i){var o=e.call(t);return r(o)?a(o,n,i):n(i)}function a(e,t,n){return u(e).then(function(){return t(n)})}var u=n.resolve,c=n.reject,l=n.prototype["catch"];return n.prototype.done=function(e,t){this._handler.visit(this._handler.receiver,e,t)},n.prototype["catch"]=n.prototype.otherwise=function(t){return arguments.length<2?l.call(this,t):"function"!=typeof t?this.ensure(e):l.call(this,o(arguments[1],t))},n.prototype["finally"]=n.prototype.ensure=function(e){return"function"!=typeof e?this:this.then(function(t){return s(e,this,i,t)},function(t){return s(e,this,c,t)})},n.prototype["else"]=n.prototype.orElse=function(e){return this.then(void 0,function(){return e})},n.prototype["yield"]=function(e){return this.then(function(){return e})},n.prototype.tap=function(e){return this.then(e)["yield"](this)},n}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(){return function(e){return e.prototype.fold=function(t,n){var r=this._beget();return this._handler.fold(function(n,r,i){e._handler(n).fold(function(e,n,r){r.resolve(t.call(this,n,e))},r,this,i)},n,r._handler.receiver,r._handler),r},e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(e){var t=n(95).inspect;return function(e){return e.prototype.inspect=function(){return t(e._handler(this))},e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(){return function(e){function t(e,t,r,i){return n(function(t){return[t,e(t)]},t,r,i)}function n(e,t,i,o){function s(o,s){return r(i(o)).then(function(){return n(e,t,i,s)})}return r(o).then(function(n){return r(t(n)).then(function(t){return t?n:r(e(n)).spread(s)})})}var r=e.resolve;return e.iterate=t,e.unfold=n,e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(){return function(e){return e.prototype.progress=function(e){return this.then(void 0,void 0,e)},e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(){return function(e){return e.prototype["with"]=e.prototype.withThis=function(e){var t=this._beget(),n=t._handler;return n.receiver=e,this._handler.chain(n,e),t},e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(e){function t(e){throw e}function r(){}var i=n(90).setTimer,o=n(104);return function(e){function n(e){e.handled||(p.push(e),l("Potentially unhandled rejection ["+e.id+"] "+o.formatError(e.value)))}function s(e){var t=p.indexOf(e);t>=0&&(p.splice(t,1),f("Handled previous rejection ["+e.id+"] "+o.formatObject(e.value)))}function a(e,t){h.push(e,t),null===d&&(d=i(u,0))}function u(){for(d=null;h.length>0;)h.shift()(h.shift())}var c,l=r,f=r;"undefined"!=typeof console&&(c=console,l="undefined"!=typeof c.error?function(e){c.error(e)}:function(e){c.log(e)},f="undefined"!=typeof c.info?function(e){c.info(e)}:function(e){c.log(e)}),e.onPotentiallyUnhandledRejection=function(e){a(n,e)},e.onPotentiallyUnhandledRejectionHandled=function(e){a(s,e)},e.onFatalRejection=function(e){a(t,e.value)};var h=[],p=[],d=null;return e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(){function e(e){var n="object"==typeof e&&null!==e&&(e.stack||e.message)?e.stack||e.message:t(e);return e instanceof Error?n:n+" (WARNING: non-Error used)"}function t(e){var t=String(e);return"[object Object]"===t&&"undefined"!=typeof JSON&&(t=n(e,t)),t}function n(e,t){try{return JSON.stringify(e)}catch(n){return t}}return{formatError:e,formatObject:t,tryStringify:n}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(i){"use strict";r=function(e){var t=n(106),r=n(107),i=n(90).asap;return t({scheduler:new r(i)})}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(92))},function(e,t,n){var r;(function(i){/** @license MIT License (c) copyright 2010-2014 original author or authors */ +!function(o){"use strict";r=function(){return function(e){function t(e,t){this._handler=e===_?t:n(e)}function n(e){function t(e){i.resolve(e)}function n(e){i.reject(e)}function r(e){i.notify(e)}var i=new E;try{e(t,n,r)}catch(o){n(o)}return i}function r(e){return F(e)?e:new t(_,new x(y(e)))}function o(e){return new t(_,new x(new C(e)))}function s(){return ne}function a(){return new t(_,new E)}function u(e,t){var n=new E(e.receiver,e.join().context);return new t(_,n)}function c(e){return f(W,null,e)}function l(e,t){return f(D,e,t)}function f(e,n,r){function i(t,i,s){s.resolved||h(r,o,t,e(n,i,t),s)}function o(e,t,n){l[e]=t,0===--c&&n.become(new I(l))}for(var s,a="function"==typeof n?i:o,u=new E,c=r.length>>>0,l=new Array(c),f=0;f0?t(n,o.value,i):(i.become(o),p(e,n+1,o))}else t(n,r,i)}function p(e,t,n){for(var r=t;r0||"function"!=typeof t&&i<0)return new this.constructor(_,r);var o=this._beget(),s=o._handler;return r.chain(s,r.receiver,e,t,n),o},t.prototype["catch"]=function(e){return this.then(void 0,e)},t.prototype._beget=function(){return u(this._handler,this.constructor)},t.all=c,t.race=v,t._traverse=l,t._visitRemaining=p,_.prototype.when=_.prototype.become=_.prototype.notify=_.prototype.fail=_.prototype._unreport=_.prototype._report=K,_.prototype._state=0,_.prototype.state=function(){return this._state},_.prototype.join=function(){for(var e=this;void 0!==e.handler;)e=e.handler;return e},_.prototype.chain=function(e,t,n,r,i){this.when({resolver:e,receiver:t,fulfilled:n,rejected:r,progress:i})},_.prototype.visit=function(e,t,n,r){this.chain(Z,e,t,n,r)},_.prototype.fold=function(e,t,n,r){this.when(new R(e,t,n,r))},Q(_,w),w.prototype.become=function(e){e.fail()};var Z=new w;Q(_,E),E.prototype._state=0,E.prototype.resolve=function(e){this.become(y(e))},E.prototype.reject=function(e){this.resolved||this.become(new C(e))},E.prototype.join=function(){if(!this.resolved)return this;for(var e=this;void 0!==e.handler;)if(e=e.handler,e===this)return this.handler=B();return e},E.prototype.run=function(){var e=this.consumers,t=this.handler;this.handler=this.handler.join(),this.consumers=void 0;for(var n=0;n",'"',"`"," ","\r","\n","\t"],d=["{","}","|","\\","^","`"].concat(p),v=["'"].concat(d),g=["%","/","?",";","#"].concat(v),y=["/","?","#"],m=255,b=/^[+a-z0-9A-Z_-]{0,63}$/,_=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,w={javascript:!0,"javascript:":!0},E={javascript:!0,"javascript:":!0},x={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},k=n(113);r.prototype.parse=function(e,t,n){if(!c.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var r=e.indexOf("?"),i=r!==-1&&r127?"x":R[P];if(!F.match(b)){var M=j.slice(0,S),N=j.slice(S+1),D=R.match(_);D&&(M.push(D[1]),N.unshift(D[2])),N.length&&(a="/"+N.join(".")+a),this.hostname=M.join(".");break}}}this.hostname.length>m?this.hostname="":this.hostname=this.hostname.toLowerCase(),O||(this.hostname=u.toASCII(this.hostname));var q=this.port?":"+this.port:"",z=this.hostname||"";this.host=z+q,this.href+=this.host,O&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==a[0]&&(a="/"+a))}if(!w[d])for(var S=0,A=v.length;S0)&&n.host.split("@");I&&(n.auth=I.shift(),n.host=n.hostname=I.shift())}return n.search=e.search,n.query=e.query,c.isNull(n.pathname)&&c.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.href=n.format(),n}if(!w.length)return n.pathname=null,n.search?n.path="/"+n.search:n.path=null,n.href=n.format(),n;for(var C=w.slice(-1)[0],S=(n.host||e.host||w.length>1)&&("."===C||".."===C)||""===C,T=0,B=w.length;B>=0;B--)C=w[B],"."===C?w.splice(B,1):".."===C?(w.splice(B,1),T++):T&&(w.splice(B,1),T--);if(!b&&!_)for(;T--;T)w.unshift("..");!b||""===w[0]||w[0]&&"/"===w[0].charAt(0)||w.unshift(""),S&&"/"!==w.join("/").substr(-1)&&w.push("");var U=""===w[0]||w[0]&&"/"===w[0].charAt(0);if(k){n.hostname=n.host=U?"":w.length?w.shift():"";var I=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@");I&&(n.auth=I.shift(),n.host=n.hostname=I.shift())}return b=b||n.host&&w.length,b&&!U&&w.unshift(""),w.length?n.pathname=w.join("/"):(n.pathname=null,n.path=null),c.isNull(n.pathname)&&c.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.auth=e.auth||n.auth,n.slashes=n.slashes||e.slashes,n.href=n.format(),n},r.prototype.parseHost=function(){var e=this.host,t=f.exec(e);t&&(t=t[0],":"!==t&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}},function(e,t,n){var r;(function(e,i){!function(o){function s(e){throw RangeError(j[e])}function a(e,t){for(var n=e.length,r=[];n--;)r[n]=t(e[n]);return r}function u(e,t){var n=e.split("@"),r="";n.length>1&&(r=n[0]+"@",e=n[1]),e=e.replace(O,".");var i=e.split("."),o=a(i,t).join(".");return r+o}function c(e){for(var t,n,r=[],i=0,o=e.length;i=55296&&t<=56319&&i65535&&(e-=65536,t+=F(e>>>10&1023|55296),e=56320|1023&e),t+=F(e)}).join("")}function f(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:w}function h(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function p(e,t,n){var r=0;for(e=n?R(e/I):e>>1,e+=R(e/t);e>A*x>>1;r+=w)e=R(e/A);return R(r+(A+1)*e/(e+k))}function d(e){var t,n,r,i,o,a,u,c,h,d,v=[],g=e.length,y=0,m=S,b=C;for(n=e.lastIndexOf(T),n<0&&(n=0),r=0;r=128&&s("not-basic"),v.push(e.charCodeAt(r));for(i=n>0?n+1:0;i=g&&s("invalid-input"),c=f(e.charCodeAt(i++)),(c>=w||c>R((_-y)/a))&&s("overflow"),y+=c*a,h=u<=b?E:u>=b+x?x:u-b,!(cR(_/d)&&s("overflow"),a*=d;t=v.length+1,b=p(y-o,t,0==o),R(y/t)>_-m&&s("overflow"),m+=R(y/t),y%=t,v.splice(y++,0,m)}return l(v)}function v(e){var t,n,r,i,o,a,u,l,f,d,v,g,y,m,b,k=[];for(e=c(e),g=e.length,t=S,n=0,o=C,a=0;a=t&&vR((_-n)/y)&&s("overflow"),n+=(u-t)*y,t=u,a=0;a_&&s("overflow"),v==t){for(l=n,f=w;d=f<=o?E:f>=o+x?x:f-o,!(l= 0x80 (not a basic code point)","invalid-input":"Invalid input"},A=w-E,R=Math.floor,F=String.fromCharCode;b={version:"1.3.2",ucs2:{decode:c,encode:l},decode:d,encode:v,toASCII:y,toUnicode:g},r=function(){return b}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(this)}).call(t,n(38)(e),function(){return this}())},function(e,t){"use strict";e.exports={isString:function(e){return"string"==typeof e},isObject:function(e){return"object"==typeof e&&null!==e},isNull:function(e){return null===e},isNullOrUndefined:function(e){return null==e}}},function(e,t,n){"use strict";t.decode=t.parse=n(114),t.encode=t.stringify=n(115)},function(e,t){"use strict";function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}e.exports=function(e,t,r,i){t=t||"&",r=r||"=";var o={};if("string"!=typeof e||0===e.length)return o;var s=/\+/g;e=e.split(t);var a=1e3;i&&"number"==typeof i.maxKeys&&(a=i.maxKeys);var u=e.length;a>0&&u>a&&(u=a);for(var c=0;c=0?(l=d.substr(0,v),f=d.substr(v+1)):(l=d,f=""),h=decodeURIComponent(l),p=decodeURIComponent(f),n(o,h)?Array.isArray(o[h])?o[h].push(p):o[h]=[o[h],p]:o[h]=p}return o}},function(e,t){"use strict";var n=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};e.exports=function(e,t,r,i){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"==typeof e?Object.keys(e).map(function(i){var o=encodeURIComponent(n(i))+r;return Array.isArray(e[i])?e[i].map(function(e){return o+encodeURIComponent(n(e))}).join(t):o+encodeURIComponent(n(e[i]))}).join(t):i?encodeURIComponent(n(i))+r+encodeURIComponent(n(e)):""}},function(e,t,n){"use strict";function r(e){y.call(this);var t=this.stream=u(e);this.muxer=new d(t),this.rest=v.alloc(0),this.frameMax=f.FRAME_MIN_SIZE,this.sentSinceLastCheck=!1,this.recvSinceLastCheck=!1,this.expectSocketClose=!1,this.freeChannels=new E,this.channels=[{channel:{accept:o(this)},buffer:e}]}function i(e){var t=this.channels[e.channel];return t?t.channel.accept(e):void this.closeWithError(k("Frame on unknown channel %d",e.channel),f.CHANNEL_ERROR,new Error(k("Frame on unknown channel: %s",w(e,!1))))}function o(e){return function(t){if(t===p);else if(t.id===l.ConnectionClose){e.sendMethod(0,l.ConnectionCloseOk,{});var n=k("Connection closed: %s",_(t)),r=S(n),i=new Error(n);i.code=t.fields.replyCode,c(i)&&e.emit("error",i),e.toClosed(r,i)}else t.id===l.ConnectionBlocked?e.emit("blocked",t.fields.reason):t.id===l.ConnectionUnblocked?e.emit("unblocked"):e.closeWithError(k("Unexpected frame on channel 0"),f.UNEXPECTED_FRAME,new Error(k("Unexpected frame on channel 0: %s",w(t,!1))))}}function s(e,t){return function(){throw new C(e,t)}}function a(e,t,n){e.sendMethod=e.sendContent=e.sendMessage=s(t,n)}function u(e){if(e instanceof g)return e;var t=new g;return t.wrap(e),t._write=function(t,n,r){return e.write(t,n,r)},t}function c(e){switch(e&&e.code){case l.constants.CONNECTION_FORCED:case l.constants.REPLY_SUCCESS:return!1;default:return!0}}var l=n(117),f=l.constants,h=n(125),p=h.HEARTBEAT,d=n(136).Mux,v=n(118).Buffer,g=n(137).Duplex||n(153),y=n(138).EventEmitter,m=n(159).Heart,b=n(160).methodName,_=n(160).closeMessage,w=n(160).inspect,E=n(161).BitSet,x=n(133).inherits,k=n(133).format,I=n(137).PassThrough||n(162),C=n(165).IllegalOperationError,S=n(165).stackCapture,T=1024,B=2048;x(r,y);var U=r.prototype;U.sendProtocolHeader=function(){this.sendBytes(h.PROTOCOL_HEADER)},U.open=function(e,t){function n(e){d.step(function(t,n){null!==t?o(t):0!==n.channel?o(new Error(k("Frame on channel != 0 during handshake: %s",w(n,!1)))):e(n)})}function r(e,t){n(function(n){n.id===e?t(n):o(new Error(k("Expected %s; got %s",b(e),w(n,!1))))})}function o(e){v(e)}function s(e){try{d.sendMethod(0,e,g)}catch(t){o(t)}}function a(e,t){return 0===e||0===t?Math.max(e,t):Math.min(e,t)}function u(t){var r=t.fields.mechanisms.toString().split(" ");return r.indexOf(e.mechanism)<0?void o(new Error(k("SASL mechanism %s is not provided by the server",e.mechanism))):(s(l.ConnectionStartOk),void n(c))}function c(t){switch(t.id){case l.ConnectionSecure:o(new Error("Wasn't expecting to have to go through secure"));break;case l.ConnectionClose:o(new Error(k("Handshake terminated by server: %s",_(t))));break;case l.ConnectionTune:var n=t.fields;g.frameMax=a(n.frameMax,e.frameMax),g.channelMax=a(n.channelMax,e.channelMax),g.heartbeat=a(n.heartbeat,e.heartbeat),s(l.ConnectionTuneOk),s(l.ConnectionOpen),r(l.ConnectionOpenOk,f);break;default:o(new Error(k("Expected connection.secure, connection.close, or connection.tune during handshake; got %s",w(t,!1))))}}function f(e){d.channelMax=g.channelMax||65535,d.frameMax=g.frameMax||4294967295,d.heartbeat=g.heartbeat,d.heartbeater=d.startHeartbeater(),d.accept=i,p(e)}function h(e){o(e||new Error("Socket closed abruptly during opening handshake"))}function p(e){d.stream.removeListener("end",h),d.stream.removeListener("error",h),d.stream.on("error",d.onSocketError.bind(d)),d.stream.on("end",d.onSocketError.bind(d,new Error("Unexpected close"))),d.on("frameError",d.onSocketError.bind(d)),d.acceptLoop(),v(null,e)}var d=this,v=t||function(){},g=Object.create(e);this.stream.on("end",h),this.stream.on("error",h),this.sendProtocolHeader(),r(l.ConnectionStart,u)},U.close=function(e){var t=e&&function(){e(null)};this.closeBecause("Cheers, thanks",f.REPLY_SUCCESS,t)},U.closeBecause=function(e,t,n){this.sendMethod(0,l.ConnectionClose,{replyText:e,replyCode:t,methodId:0,classId:0});var r=S("closeBecause called: "+e);this.toClosing(r,n)},U.closeWithError=function(e,t,n){this.emit("error",n),this.closeBecause(e,t)},U.onSocketError=function(e){if(!this.expectSocketClose){this.expectSocketClose=!0,this.emit("error",e);var t=S("Socket error");this.toClosed(t,e)}},U.toClosing=function(e,t){var n=this.sendMethod.bind(this);this.accept=function(e){if(e.id===l.ConnectionCloseOk){t&&t();var r=S("ConnectionCloseOk received");this.toClosed(r,void 0)}else e.id===l.ConnectionClose&&n(0,l.ConnectionCloseOk,{})},a(this,"Connection closing",e)},U._closeChannels=function(e){for(var t=1;tthis.channelMax)throw new Error("No channels left to allocate");this.freeChannels.set(n);var r=t&&t.highWaterMark||T,i=new I({objectMode:!0,highWaterMark:r});return this.channels[n]={channel:e,buffer:i},i.on("drain",function(){e.onBufferDrain()}),this.muxer.pipeFrom(i),n},U.releaseChannel=function(e){this.freeChannels.clear(e);var t=this.channels[e].buffer;this.muxer.unpipeFrom(t),this.channels[e]=null},U.acceptLoop=function(){function e(){try{for(var e;e=t.recvFrame();)t.accept(e)}catch(n){t.emit("frameError",n)}}var t=this;t.stream.on("readable",e),e()},U.step=function(e){function t(){var r;try{r=n.recvFrame()}catch(i){return void e(i,null)}r?e(null,r):n.stream.once("readable",t)}var n=this;t()},U.checkSend=function(){var e=this.sentSinceLastCheck;return this.sentSinceLastCheck=!1,e},U.checkRecv=function(){var e=this.recvSinceLastCheck;return this.recvSinceLastCheck=!1,e},U.sendBytes=function(e){this.sentSinceLastCheck=!0,this.stream.write(e)},U.sendHeartbeat=function(){return this.sendBytes(h.HEARTBEAT_BUF)};var O=l.encodeMethod,j=l.encodeProperties;U.sendMethod=function(e,t,n){var r=O(t,e,n);this.sentSinceLastCheck=!0;var i=this.channels[e].buffer;return i.write(r)},U.sendMessage=function(e,t,n,r,i,o){if(!v.isBuffer(o))throw new TypeError("content is not a buffer");var s=O(t,e,n),a=j(r,e,o.length,i),u=this.channels[e].buffer;this.sentSinceLastCheck=!0;var c=s.length+a.length,l=o.length>0?o.length+A:0,f=c+l;if(f0&&R(e,o).copy(h,p),u.write(h)}if(ct.length?t.slice(o):t.slice(o,s),u=R(e,a);n=r.write(u)}return this.sentSinceLastCheck=!0,n};var F=h.parseFrame,P=h.decodeFrame;U.recvFrame=function(){var e=F(this.rest,this.frameMax);if(e)return this.rest=e.rest,P(e);var t=this.stream.read();return null!==t&&(this.recvSinceLastCheck=!0,this.rest=v.concat([this.rest,t]),this.recvFrame())},e.exports.Connection=r,e.exports.isFatalError=c},function(e,t,n){(function(t){/** @preserve This file is generated by the script * ../bin/generate-defs.js, which is not in general included in a * distribution, but is available in the source repository e.g. at * https://github.com/squaremo/amqp.node/ */ -"use strict";function r(e){var t,n,r=0,i={versionMajor:void 0,versionMinor:void 0,serverProperties:void 0,mechanisms:void 0,locales:void 0};return t=e[r],r++,i.versionMajor=t,t=e[r],r++,i.versionMinor=t,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.serverProperties=t,n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.mechanisms=t,n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.locales=t,i}function i(e,n){var r,i=0,o=null,s=0,a=0;if(o=n.serverProperties,void 0===o)throw new Error("Missing value for mandatory field 'serverProperties'");if("object"!=typeof o)throw new TypeError("Field 'serverProperties' is the wrong type; must be an object");r=Ct(jt,o,a);var u=jt.slice(a,a+r);if(a+=r,s+=u.length,o=n.mechanisms,void 0===o)o=new t("PLAIN");else if(!t.isBuffer(o))throw new TypeError("Field 'mechanisms' is the wrong type; must be a Buffer");if(s+=o.length,o=n.locales,void 0===o)o=new t("en_US");else if(!t.isBuffer(o))throw new TypeError("Field 'locales' is the wrong type; must be a Buffer");s+=o.length;var c=new t(22+s);if(c[0]=1,c.writeUInt16BE(e,1),c.writeUInt32BE(655370,7),i=11,o=n.versionMajor,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'versionMajor' is the wrong type; must be a number (but not NaN)");if(c.writeUInt8(o,i),i++,o=n.versionMinor,void 0===o)o=9;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'versionMinor' is the wrong type; must be a number (but not NaN)");return c.writeUInt8(o,i),i++,i+=u.copy(c,i),o=n.mechanisms,void 0===o&&(o=new t("PLAIN")),r=o.length,c.writeUInt32BE(r,i),i+=4,o.copy(c,i),i+=r,o=n.locales,void 0===o&&(o=new t("en_US")),r=o.length,c.writeUInt32BE(r,i),i+=4,o.copy(c,i),i+=r,c[i]=206,c.writeUInt32BE(i-7,3),c}function o(e){var t,n,r=0,i={clientProperties:void 0,mechanism:void 0,response:void 0,locale:void 0};return n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.clientProperties=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.mechanism=t,n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.response=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.locale=t,i}function s(e,n){var r,i=0,o=null,s=0,a=0;if(o=n.clientProperties,void 0===o)throw new Error("Missing value for mandatory field 'clientProperties'");if("object"!=typeof o)throw new TypeError("Field 'clientProperties' is the wrong type; must be an object");r=Ct(jt,o,a);var u=jt.slice(a,a+r);if(a+=r,s+=u.length,o=n.mechanism,void 0===o)o="PLAIN";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'mechanism' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(s+=c,o=n.response,void 0===o)throw new Error("Missing value for mandatory field 'response'");if(!t.isBuffer(o))throw new TypeError("Field 'response' is the wrong type; must be a Buffer");if(s+=o.length,o=n.locale,void 0===o)o="en_US";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'locale' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");s+=l;var f=new t(18+s);return f[0]=1,f.writeUInt16BE(e,1),f.writeUInt32BE(655371,7),i=11,i+=u.copy(f,i),o=n.mechanism,void 0===o&&(o="PLAIN"),f[i]=c,i++,f.write(o,i,"utf8"),i+=c,o=n.response,void 0===o&&(o=new t((void 0))),r=o.length,f.writeUInt32BE(r,i),i+=4,o.copy(f,i),i+=r,o=n.locale,void 0===o&&(o="en_US"),f[i]=l,i++,f.write(o,i,"utf8"),i+=l,f[i]=206,f.writeUInt32BE(i-7,3),f}function a(e){var t,n,r=0,i={challenge:void 0};return n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.challenge=t,i}function u(e,n){var r,i=0,o=null,s=0;if(o=n.challenge,void 0===o)throw new Error("Missing value for mandatory field 'challenge'");if(!t.isBuffer(o))throw new TypeError("Field 'challenge' is the wrong type; must be a Buffer");s+=o.length;var a=new t(16+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(655380,7),i=11,o=n.challenge,void 0===o&&(o=new t((void 0))),r=o.length,a.writeUInt32BE(r,i),i+=4,o.copy(a,i),i+=r,a[i]=206,a.writeUInt32BE(i-7,3),a}function c(e){var t,n,r=0,i={response:void 0};return n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.response=t,i}function l(e,n){var r,i=0,o=null,s=0;if(o=n.response,void 0===o)throw new Error("Missing value for mandatory field 'response'");if(!t.isBuffer(o))throw new TypeError("Field 'response' is the wrong type; must be a Buffer");s+=o.length;var a=new t(16+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(655381,7),i=11,o=n.response,void 0===o&&(o=new t((void 0))),r=o.length,a.writeUInt32BE(r,i),i+=4,o.copy(a,i),i+=r,a[i]=206,a.writeUInt32BE(i-7,3),a}function f(e){var t,n=0,r={channelMax:void 0,frameMax:void 0,heartbeat:void 0};return t=e.readUInt16BE(n),n+=2,r.channelMax=t,t=e.readUInt32BE(n),n+=4,r.frameMax=t,t=e.readUInt16BE(n),n+=2,r.heartbeat=t,r}function h(e,n){var r=0,i=null,o=0,s=new t(20+o);if(s[0]=1,s.writeUInt16BE(e,1),s.writeUInt32BE(655390,7),r=11,i=n.channelMax,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'channelMax' is the wrong type; must be a number (but not NaN)");if(s.writeUInt16BE(i,r),r+=2,i=n.frameMax,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'frameMax' is the wrong type; must be a number (but not NaN)");if(s.writeUInt32BE(i,r),r+=4,i=n.heartbeat,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'heartbeat' is the wrong type; must be a number (but not NaN)");return s.writeUInt16BE(i,r),r+=2,s[r]=206,s.writeUInt32BE(r-7,3),s}function p(e){var t,n=0,r={channelMax:void 0,frameMax:void 0,heartbeat:void 0};return t=e.readUInt16BE(n),n+=2,r.channelMax=t,t=e.readUInt32BE(n),n+=4,r.frameMax=t,t=e.readUInt16BE(n),n+=2,r.heartbeat=t,r}function d(e,n){var r=0,i=null,o=0,s=new t(20+o);if(s[0]=1,s.writeUInt16BE(e,1),s.writeUInt32BE(655391,7),r=11,i=n.channelMax,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'channelMax' is the wrong type; must be a number (but not NaN)");if(s.writeUInt16BE(i,r),r+=2,i=n.frameMax,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'frameMax' is the wrong type; must be a number (but not NaN)");if(s.writeUInt32BE(i,r),r+=4,i=n.heartbeat,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'heartbeat' is the wrong type; must be a number (but not NaN)");return s.writeUInt16BE(i,r),r+=2,s[r]=206,s.writeUInt32BE(r-7,3),s}function v(e){var t,n,r=0,i={virtualHost:void 0,capabilities:void 0,insist:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.virtualHost=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.capabilities=t,t=!!(1&e[r]),i.insist=t,i}function g(e,n){var r=0,i=null,o=0,s=0;if(i=n.virtualHost,void 0===i)i="/";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'virtualHost' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");if(s+=a,i=n.capabilities,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'capabilities' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(i,"utf8");s+=u;var c=new t(15+s);return c[0]=1,c.writeUInt16BE(e,1),c.writeUInt32BE(655400,7),r=11,i=n.virtualHost,void 0===i&&(i="/"),c[r]=a,r++,c.write(i,r,"utf8"),r+=a,i=n.capabilities,void 0===i&&(i=""),c[r]=u,r++,c.write(i,r,"utf8"),r+=u,i=n.insist,void 0===i&&(i=!1),i&&(o+=1),c[r]=o,r++,c[r]=206,c.writeUInt32BE(r-7,3),c}function y(e){var t,n,r=0,i={knownHosts:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.knownHosts=t,i}function m(e,n){var r=0,i=null,o=0;if(i=n.knownHosts,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'knownHosts' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=new t(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(655401,7),r=11,i=n.knownHosts,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function b(e){var t,n,r=0,i={replyCode:void 0,replyText:void 0,classId:void 0,methodId:void 0};return t=e.readUInt16BE(r),r+=2,i.replyCode=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.replyText=t,t=e.readUInt16BE(r),r+=2,i.classId=t,t=e.readUInt16BE(r),r+=2,i.methodId=t,i}function w(e,n){var r=0,i=null,o=0;if(i=n.replyText,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'replyText' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=new t(19+o);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(655410,7),r=11,i=n.replyCode,void 0===i)throw new Error("Missing value for mandatory field 'replyCode'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'replyCode' is the wrong type; must be a number (but not NaN)");if(a.writeUInt16BE(i,r),r+=2,i=n.replyText,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,i=n.classId,void 0===i)throw new Error("Missing value for mandatory field 'classId'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'classId' is the wrong type; must be a number (but not NaN)");if(a.writeUInt16BE(i,r),r+=2,i=n.methodId,void 0===i)throw new Error("Missing value for mandatory field 'methodId'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'methodId' is the wrong type; must be a number (but not NaN)");return a.writeUInt16BE(i,r),r+=2,a[r]=206,a.writeUInt32BE(r-7,3),a}function _(e){var t={};return t}function E(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(655411,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function x(e){var t,n,r=0,i={reason:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.reason=t,i}function k(e,n){var r=0,i=null,o=0;if(i=n.reason,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'reason' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=new t(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(655420,7),r=11,i=n.reason,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function I(e){var t={};return t}function S(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(655421,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function C(e){var t,n,r=0,i={outOfBand:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.outOfBand=t,i}function T(e,n){var r=0,i=null,o=0;if(i=n.outOfBand,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'outOfBand' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=new t(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(1310730,7),r=11,i=n.outOfBand,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function j(e){var t,n,r=0,i={channelId:void 0};return n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.channelId=t,i}function U(e,n){var r,i=0,o=null,s=0;if(o=n.channelId,void 0===o)o=new t("");else if(!t.isBuffer(o))throw new TypeError("Field 'channelId' is the wrong type; must be a Buffer");s+=o.length;var a=new t(16+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(1310731,7),i=11,o=n.channelId,void 0===o&&(o=new t("")),r=o.length,a.writeUInt32BE(r,i),i+=4,o.copy(a,i),i+=r,a[i]=206,a.writeUInt32BE(i-7,3),a}function B(e){var t,n=0,r={active:void 0};return t=!!(1&e[n]),r.active=t,r}function O(e,n){var r=0,i=null,o=0,s=0,a=new t(13+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(1310740,7),r=11,i=n.active,void 0===i)throw new Error("Missing value for mandatory field 'active'");return i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function A(e){var t,n=0,r={active:void 0};return t=!!(1&e[n]),r.active=t,r}function R(e,n){var r=0,i=null,o=0,s=0,a=new t(13+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(1310741,7),r=11,i=n.active,void 0===i)throw new Error("Missing value for mandatory field 'active'");return i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function M(e){var t,n,r=0,i={replyCode:void 0,replyText:void 0,classId:void 0,methodId:void 0};return t=e.readUInt16BE(r),r+=2,i.replyCode=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.replyText=t,t=e.readUInt16BE(r),r+=2,i.classId=t,t=e.readUInt16BE(r),r+=2,i.methodId=t,i}function L(e,n){var r=0,i=null,o=0;if(i=n.replyText,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'replyText' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=new t(19+o);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(1310760,7),r=11,i=n.replyCode,void 0===i)throw new Error("Missing value for mandatory field 'replyCode'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'replyCode' is the wrong type; must be a number (but not NaN)");if(a.writeUInt16BE(i,r),r+=2,i=n.replyText,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,i=n.classId,void 0===i)throw new Error("Missing value for mandatory field 'classId'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'classId' is the wrong type; must be a number (but not NaN)");if(a.writeUInt16BE(i,r),r+=2,i=n.methodId,void 0===i)throw new Error("Missing value for mandatory field 'methodId'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'methodId' is the wrong type; must be a number (but not NaN)");return a.writeUInt16BE(i,r),r+=2,a[r]=206,a.writeUInt32BE(r-7,3),a}function F(e){var t={};return t}function P(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(1310761,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function N(e){var t,n,r=0,i={realm:void 0,exclusive:void 0,passive:void 0,active:void 0,write:void 0,read:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.realm=t,t=!!(1&e[r]),i.exclusive=t,t=!!(2&e[r]),i.passive=t,t=!!(4&e[r]),i.active=t,t=!!(8&e[r]),i.write=t,t=!!(16&e[r]),i.read=t,i}function D(e,n){var r=0,i=null,o=0,s=0;if(i=n.realm,void 0===i)i="/data";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'realm' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=new t(14+s);return u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(1966090,7),r=11,i=n.realm,void 0===i&&(i="/data"),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.exclusive,void 0===i&&(i=!1),i&&(o+=1),i=n.passive,void 0===i&&(i=!0),i&&(o+=2),i=n.active,void 0===i&&(i=!0),i&&(o+=4),i=n.write,void 0===i&&(i=!0),i&&(o+=8),i=n.read,void 0===i&&(i=!0),i&&(o+=16),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function q(e){var t,n=0,r={ticket:void 0};return t=e.readUInt16BE(n),n+=2,r.ticket=t,r}function z(e,n){var r=0,i=null,o=0,s=new t(14+o);if(s[0]=1,s.writeUInt16BE(e,1),s.writeUInt32BE(1966091,7),r=11,i=n.ticket,void 0===i)i=1;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return s.writeUInt16BE(i,r),r+=2,s[r]=206,s.writeUInt32BE(r-7,3),s}function H(e){var t,n,r=0,i={ticket:void 0,exchange:void 0,type:void 0,passive:void 0,durable:void 0,autoDelete:void 0,internal:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.type=t,t=!!(1&e[r]),i.passive=t,t=!!(2&e[r]),i.durable=t,t=!!(4&e[r]),i.autoDelete=t,t=!!(8&e[r]),i.internal=t,t=!!(16&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function Q(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.exchange,void 0===o)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.type,void 0===o)o="direct";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'type' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(a+=l,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=Ct(jt,o,u);var f=jt.slice(u,u+r);u+=r,a+=f.length;var h=new t(17+a);if(h[0]=1,h.writeUInt16BE(e,1),h.writeUInt32BE(2621450,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return h.writeUInt16BE(o,i),i+=2,o=n.exchange,void 0===o&&(o=void 0),h[i]=c,i++,h.write(o,i,"utf8"),i+=c,o=n.type,void 0===o&&(o="direct"),h[i]=l,i++,h.write(o,i,"utf8"),i+=l,o=n.passive,void 0===o&&(o=!1),o&&(s+=1),o=n.durable,void 0===o&&(o=!1),o&&(s+=2),o=n.autoDelete,void 0===o&&(o=!1),o&&(s+=4),o=n.internal,void 0===o&&(o=!1),o&&(s+=8),o=n.nowait,void 0===o&&(o=!1),o&&(s+=16),h[i]=s,i++,s=0,i+=f.copy(h,i),h[i]=206,h.writeUInt32BE(i-7,3),h}function W(e){var t={};return t}function K(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(2621451,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function V(e){var t,n,r=0,i={ticket:void 0,exchange:void 0,ifUnused:void 0,nowait:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,t=!!(1&e[r]),i.ifUnused=t,t=!!(2&e[r]),i.nowait=t,i}function G(e,n){var r=0,i=null,o=0,s=0;if(i=n.exchange,void 0===i)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=new t(16+s);if(u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(2621460,7),r=11,i=n.ticket,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return u.writeUInt16BE(i,r),r+=2,i=n.exchange,void 0===i&&(i=void 0),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.ifUnused,void 0===i&&(i=!1),i&&(o+=1),i=n.nowait,void 0===i&&(i=!1),i&&(o+=2),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function Y(e){var t={};return t}function $(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(2621461,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function X(e){var t,n,r=0,i={ticket:void 0,destination:void 0,source:void 0,routingKey:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.destination=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.source=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,t=!!(1&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function J(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.destination,void 0===o)throw new Error("Missing value for mandatory field 'destination'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'destination' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.source,void 0===o)throw new Error("Missing value for mandatory field 'source'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'source' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(a+=l,o=n.routingKey,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var f=t.byteLength(o,"utf8");if(a+=f,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=Ct(jt,o,u);var h=jt.slice(u,u+r);u+=r,a+=h.length;var p=new t(18+a);if(p[0]=1,p.writeUInt16BE(e,1),p.writeUInt32BE(2621470,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return p.writeUInt16BE(o,i),i+=2,o=n.destination,void 0===o&&(o=void 0),p[i]=c,i++,p.write(o,i,"utf8"),i+=c,o=n.source,void 0===o&&(o=void 0),p[i]=l,i++,p.write(o,i,"utf8"),i+=l,o=n.routingKey,void 0===o&&(o=""),p[i]=f,i++,p.write(o,i,"utf8"),i+=f,o=n.nowait,void 0===o&&(o=!1),o&&(s+=1),p[i]=s,i++,s=0,i+=h.copy(p,i),p[i]=206,p.writeUInt32BE(i-7,3),p}function Z(e){var t={};return t}function ee(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(2621471,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function te(e){var t,n,r=0,i={ticket:void 0,destination:void 0,source:void 0,routingKey:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.destination=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.source=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,t=!!(1&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function ne(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.destination,void 0===o)throw new Error("Missing value for mandatory field 'destination'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'destination' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.source,void 0===o)throw new Error("Missing value for mandatory field 'source'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'source' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(a+=l,o=n.routingKey,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var f=t.byteLength(o,"utf8");if(a+=f,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=Ct(jt,o,u);var h=jt.slice(u,u+r);u+=r,a+=h.length;var p=new t(18+a);if(p[0]=1,p.writeUInt16BE(e,1),p.writeUInt32BE(2621480,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return p.writeUInt16BE(o,i),i+=2,o=n.destination,void 0===o&&(o=void 0),p[i]=c,i++,p.write(o,i,"utf8"),i+=c,o=n.source,void 0===o&&(o=void 0),p[i]=l,i++,p.write(o,i,"utf8"),i+=l,o=n.routingKey,void 0===o&&(o=""),p[i]=f,i++,p.write(o,i,"utf8"),i+=f,o=n.nowait,void 0===o&&(o=!1),o&&(s+=1),p[i]=s,i++,s=0,i+=h.copy(p,i),p[i]=206,p.writeUInt32BE(i-7,3),p}function re(e){var t={};return t}function ie(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(2621491,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function oe(e){var t,n,r=0,i={ticket:void 0,queue:void 0,passive:void 0,durable:void 0,exclusive:void 0,autoDelete:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,t=!!(1&e[r]),i.passive=t,t=!!(2&e[r]),i.durable=t,t=!!(4&e[r]),i.exclusive=t,t=!!(8&e[r]),i.autoDelete=t,t=!!(16&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function se(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.queue,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=Ct(jt,o,u);var l=jt.slice(u,u+r);u+=r,a+=l.length;var f=new t(16+a);if(f[0]=1,f.writeUInt16BE(e,1),f.writeUInt32BE(3276810,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return f.writeUInt16BE(o,i),i+=2,o=n.queue,void 0===o&&(o=""),f[i]=c,i++,f.write(o,i,"utf8"),i+=c,o=n.passive,void 0===o&&(o=!1),o&&(s+=1),o=n.durable,void 0===o&&(o=!1),o&&(s+=2),o=n.exclusive,void 0===o&&(o=!1),o&&(s+=4),o=n.autoDelete,void 0===o&&(o=!1),o&&(s+=8),o=n.nowait,void 0===o&&(o=!1),o&&(s+=16),f[i]=s,i++,s=0,i+=l.copy(f,i),f[i]=206,f.writeUInt32BE(i-7,3),f}function ae(e){var t,n,r=0,i={queue:void 0,messageCount:void 0,consumerCount:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,t=e.readUInt32BE(r),r+=4,i.messageCount=t,t=e.readUInt32BE(r),r+=4,i.consumerCount=t,i}function ue(e,n){var r=0,i=null,o=0;if(i=n.queue,void 0===i)throw new Error("Missing value for mandatory field 'queue'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=new t(21+o);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3276811,7),r=11,i=n.queue,void 0===i&&(i=void 0),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,i=n.messageCount,void 0===i)throw new Error("Missing value for mandatory field 'messageCount'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'messageCount' is the wrong type; must be a number (but not NaN)");if(a.writeUInt32BE(i,r),r+=4,i=n.consumerCount,void 0===i)throw new Error("Missing value for mandatory field 'consumerCount'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'consumerCount' is the wrong type; must be a number (but not NaN)");return a.writeUInt32BE(i,r),r+=4,a[r]=206,a.writeUInt32BE(r-7,3),a}function ce(e){var t,n,r=0,i={ticket:void 0,queue:void 0,exchange:void 0,routingKey:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,t=!!(1&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function le(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.queue,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.exchange,void 0===o)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(a+=l,o=n.routingKey,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var f=t.byteLength(o,"utf8");if(a+=f,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=Ct(jt,o,u);var h=jt.slice(u,u+r);u+=r,a+=h.length;var p=new t(18+a);if(p[0]=1,p.writeUInt16BE(e,1),p.writeUInt32BE(3276820,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return p.writeUInt16BE(o,i),i+=2,o=n.queue,void 0===o&&(o=""),p[i]=c,i++,p.write(o,i,"utf8"),i+=c,o=n.exchange,void 0===o&&(o=void 0),p[i]=l,i++,p.write(o,i,"utf8"),i+=l,o=n.routingKey,void 0===o&&(o=""),p[i]=f,i++,p.write(o,i,"utf8"),i+=f,o=n.nowait,void 0===o&&(o=!1),o&&(s+=1),p[i]=s,i++,s=0,i+=h.copy(p,i),p[i]=206,p.writeUInt32BE(i-7,3),p}function fe(e){var t={};return t}function he(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(3276821,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function pe(e){var t,n,r=0,i={ticket:void 0,queue:void 0,nowait:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,t=!!(1&e[r]),i.nowait=t,i}function de(e,n){var r=0,i=null,o=0,s=0;if(i=n.queue,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=new t(16+s);if(u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(3276830,7),r=11,i=n.ticket,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return u.writeUInt16BE(i,r),r+=2,i=n.queue,void 0===i&&(i=""),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.nowait,void 0===i&&(i=!1),i&&(o+=1),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function ve(e){var t,n=0,r={messageCount:void 0};return t=e.readUInt32BE(n),n+=4,r.messageCount=t,r}function ge(e,n){var r=0,i=null,o=0,s=new t(16+o);if(s[0]=1,s.writeUInt16BE(e,1),s.writeUInt32BE(3276831,7),r=11,i=n.messageCount,void 0===i)throw new Error("Missing value for mandatory field 'messageCount'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'messageCount' is the wrong type; must be a number (but not NaN)");return s.writeUInt32BE(i,r),r+=4,s[r]=206,s.writeUInt32BE(r-7,3),s}function ye(e){var t,n,r=0,i={ticket:void 0,queue:void 0,ifUnused:void 0,ifEmpty:void 0,nowait:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,t=!!(1&e[r]),i.ifUnused=t,t=!!(2&e[r]),i.ifEmpty=t,t=!!(4&e[r]),i.nowait=t,i}function me(e,n){var r=0,i=null,o=0,s=0;if(i=n.queue,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=new t(16+s);if(u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(3276840,7),r=11,i=n.ticket,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return u.writeUInt16BE(i,r),r+=2,i=n.queue,void 0===i&&(i=""),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.ifUnused,void 0===i&&(i=!1),i&&(o+=1),i=n.ifEmpty,void 0===i&&(i=!1),i&&(o+=2),i=n.nowait,void 0===i&&(i=!1),i&&(o+=4),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function be(e){var t,n=0,r={messageCount:void 0};return t=e.readUInt32BE(n),n+=4,r.messageCount=t,r}function we(e,n){var r=0,i=null,o=0,s=new t(16+o);if(s[0]=1,s.writeUInt16BE(e,1),s.writeUInt32BE(3276841,7),r=11,i=n.messageCount,void 0===i)throw new Error("Missing value for mandatory field 'messageCount'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'messageCount' is the wrong type; must be a number (but not NaN)");return s.writeUInt32BE(i,r),r+=4,s[r]=206,s.writeUInt32BE(r-7,3),s}function _e(e){var t,n,r=0,i={ticket:void 0,queue:void 0,exchange:void 0,routingKey:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function Ee(e,n){var r,i=0,o=null,s=0,a=0;if(o=n.queue,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(o,"utf8");if(s+=u,o=n.exchange,void 0===o)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(s+=c,o=n.routingKey,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(s+=l,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=Ct(jt,o,a);var f=jt.slice(a,a+r);a+=r,s+=f.length;var h=new t(17+s);if(h[0]=1,h.writeUInt16BE(e,1),h.writeUInt32BE(3276850,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)"); -return h.writeUInt16BE(o,i),i+=2,o=n.queue,void 0===o&&(o=""),h[i]=u,i++,h.write(o,i,"utf8"),i+=u,o=n.exchange,void 0===o&&(o=void 0),h[i]=c,i++,h.write(o,i,"utf8"),i+=c,o=n.routingKey,void 0===o&&(o=""),h[i]=l,i++,h.write(o,i,"utf8"),i+=l,i+=f.copy(h,i),h[i]=206,h.writeUInt32BE(i-7,3),h}function xe(e){var t={};return t}function ke(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(3276851,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function Ie(e){var t,n=0,r={prefetchSize:void 0,prefetchCount:void 0,global:void 0};return t=e.readUInt32BE(n),n+=4,r.prefetchSize=t,t=e.readUInt16BE(n),n+=2,r.prefetchCount=t,t=!!(1&e[n]),r.global=t,r}function Se(e,n){var r=0,i=null,o=0,s=0,a=new t(19+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932170,7),r=11,i=n.prefetchSize,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'prefetchSize' is the wrong type; must be a number (but not NaN)");if(a.writeUInt32BE(i,r),r+=4,i=n.prefetchCount,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'prefetchCount' is the wrong type; must be a number (but not NaN)");return a.writeUInt16BE(i,r),r+=2,i=n.global,void 0===i&&(i=!1),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function Ce(e){var t={};return t}function Te(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(3932171,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function je(e){var t,n,r=0,i={ticket:void 0,queue:void 0,consumerTag:void 0,noLocal:void 0,noAck:void 0,exclusive:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.consumerTag=t,t=!!(1&e[r]),i.noLocal=t,t=!!(2&e[r]),i.noAck=t,t=!!(4&e[r]),i.exclusive=t,t=!!(8&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function Ue(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.queue,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.consumerTag,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'consumerTag' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(a+=l,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=Ct(jt,o,u);var f=jt.slice(u,u+r);u+=r,a+=f.length;var h=new t(17+a);if(h[0]=1,h.writeUInt16BE(e,1),h.writeUInt32BE(3932180,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return h.writeUInt16BE(o,i),i+=2,o=n.queue,void 0===o&&(o=""),h[i]=c,i++,h.write(o,i,"utf8"),i+=c,o=n.consumerTag,void 0===o&&(o=""),h[i]=l,i++,h.write(o,i,"utf8"),i+=l,o=n.noLocal,void 0===o&&(o=!1),o&&(s+=1),o=n.noAck,void 0===o&&(o=!1),o&&(s+=2),o=n.exclusive,void 0===o&&(o=!1),o&&(s+=4),o=n.nowait,void 0===o&&(o=!1),o&&(s+=8),h[i]=s,i++,s=0,i+=f.copy(h,i),h[i]=206,h.writeUInt32BE(i-7,3),h}function Be(e){var t,n,r=0,i={consumerTag:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.consumerTag=t,i}function Oe(e,n){var r=0,i=null,o=0;if(i=n.consumerTag,void 0===i)throw new Error("Missing value for mandatory field 'consumerTag'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'consumerTag' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=new t(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932181,7),r=11,i=n.consumerTag,void 0===i&&(i=void 0),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function Ae(e){var t,n,r=0,i={consumerTag:void 0,nowait:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.consumerTag=t,t=!!(1&e[r]),i.nowait=t,i}function Re(e,n){var r=0,i=null,o=0,s=0;if(i=n.consumerTag,void 0===i)throw new Error("Missing value for mandatory field 'consumerTag'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'consumerTag' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=new t(14+s);return u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(3932190,7),r=11,i=n.consumerTag,void 0===i&&(i=void 0),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.nowait,void 0===i&&(i=!1),i&&(o+=1),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function Me(e){var t,n,r=0,i={consumerTag:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.consumerTag=t,i}function Le(e,n){var r=0,i=null,o=0;if(i=n.consumerTag,void 0===i)throw new Error("Missing value for mandatory field 'consumerTag'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'consumerTag' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=new t(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932191,7),r=11,i=n.consumerTag,void 0===i&&(i=void 0),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function Fe(e){var t,n,r=0,i={ticket:void 0,exchange:void 0,routingKey:void 0,mandatory:void 0,immediate:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,t=!!(1&e[r]),i.mandatory=t,t=!!(2&e[r]),i.immediate=t,i}function Pe(e,n){var r=0,i=null,o=0,s=0;if(i=n.exchange,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");if(s+=a,i=n.routingKey,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(i,"utf8");s+=u;var c=new t(17+s);if(c[0]=1,c.writeUInt16BE(e,1),c.writeUInt32BE(3932200,7),r=11,i=n.ticket,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return c.writeUInt16BE(i,r),r+=2,i=n.exchange,void 0===i&&(i=""),c[r]=a,r++,c.write(i,r,"utf8"),r+=a,i=n.routingKey,void 0===i&&(i=""),c[r]=u,r++,c.write(i,r,"utf8"),r+=u,i=n.mandatory,void 0===i&&(i=!1),i&&(o+=1),i=n.immediate,void 0===i&&(i=!1),i&&(o+=2),c[r]=o,r++,c[r]=206,c.writeUInt32BE(r-7,3),c}function Ne(e){var t,n,r=0,i={replyCode:void 0,replyText:void 0,exchange:void 0,routingKey:void 0};return t=e.readUInt16BE(r),r+=2,i.replyCode=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.replyText=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,i}function De(e,n){var r=0,i=null,o=0;if(i=n.replyText,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'replyText' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");if(o+=s,i=n.exchange,void 0===i)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");if(o+=a,i=n.routingKey,void 0===i)throw new Error("Missing value for mandatory field 'routingKey'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(i,"utf8");o+=u;var c=new t(17+o);if(c[0]=1,c.writeUInt16BE(e,1),c.writeUInt32BE(3932210,7),r=11,i=n.replyCode,void 0===i)throw new Error("Missing value for mandatory field 'replyCode'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'replyCode' is the wrong type; must be a number (but not NaN)");return c.writeUInt16BE(i,r),r+=2,i=n.replyText,void 0===i&&(i=""),c[r]=s,r++,c.write(i,r,"utf8"),r+=s,i=n.exchange,void 0===i&&(i=void 0),c[r]=a,r++,c.write(i,r,"utf8"),r+=a,i=n.routingKey,void 0===i&&(i=void 0),c[r]=u,r++,c.write(i,r,"utf8"),r+=u,c[r]=206,c.writeUInt32BE(r-7,3),c}function qe(e){var t,n,r=0,i={consumerTag:void 0,deliveryTag:void 0,redelivered:void 0,exchange:void 0,routingKey:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.consumerTag=t,t=St.readUInt64BE(e,r),r+=8,i.deliveryTag=t,t=!!(1&e[r]),i.redelivered=t,r++,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,i}function ze(e,n){var r=0,i=null,o=0,s=0;if(i=n.consumerTag,void 0===i)throw new Error("Missing value for mandatory field 'consumerTag'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'consumerTag' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");if(s+=a,i=n.exchange,void 0===i)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(i,"utf8");if(s+=u,i=n.routingKey,void 0===i)throw new Error("Missing value for mandatory field 'routingKey'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(i,"utf8");s+=c;var l=new t(24+s);if(l[0]=1,l.writeUInt16BE(e,1),l.writeUInt32BE(3932220,7),r=11,i=n.consumerTag,void 0===i&&(i=void 0),l[r]=a,r++,l.write(i,r,"utf8"),r+=a,i=n.deliveryTag,void 0===i)throw new Error("Missing value for mandatory field 'deliveryTag'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryTag' is the wrong type; must be a number (but not NaN)");return St.writeUInt64BE(l,i,r),r+=8,i=n.redelivered,void 0===i&&(i=!1),i&&(o+=1),l[r]=o,r++,o=0,i=n.exchange,void 0===i&&(i=void 0),l[r]=u,r++,l.write(i,r,"utf8"),r+=u,i=n.routingKey,void 0===i&&(i=void 0),l[r]=c,r++,l.write(i,r,"utf8"),r+=c,l[r]=206,l.writeUInt32BE(r-7,3),l}function He(e){var t,n,r=0,i={ticket:void 0,queue:void 0,noAck:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,t=!!(1&e[r]),i.noAck=t,i}function Qe(e,n){var r=0,i=null,o=0,s=0;if(i=n.queue,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=new t(16+s);if(u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(3932230,7),r=11,i=n.ticket,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return u.writeUInt16BE(i,r),r+=2,i=n.queue,void 0===i&&(i=""),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.noAck,void 0===i&&(i=!1),i&&(o+=1),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function We(e){var t,n,r=0,i={deliveryTag:void 0,redelivered:void 0,exchange:void 0,routingKey:void 0,messageCount:void 0};return t=St.readUInt64BE(e,r),r+=8,i.deliveryTag=t,t=!!(1&e[r]),i.redelivered=t,r++,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,t=e.readUInt32BE(r),r+=4,i.messageCount=t,i}function Ke(e,n){var r=0,i=null,o=0,s=0;if(i=n.exchange,void 0===i)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");if(s+=a,i=n.routingKey,void 0===i)throw new Error("Missing value for mandatory field 'routingKey'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(i,"utf8");s+=u;var c=new t(27+s);if(c[0]=1,c.writeUInt16BE(e,1),c.writeUInt32BE(3932231,7),r=11,i=n.deliveryTag,void 0===i)throw new Error("Missing value for mandatory field 'deliveryTag'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryTag' is the wrong type; must be a number (but not NaN)");if(St.writeUInt64BE(c,i,r),r+=8,i=n.redelivered,void 0===i&&(i=!1),i&&(o+=1),c[r]=o,r++,o=0,i=n.exchange,void 0===i&&(i=void 0),c[r]=a,r++,c.write(i,r,"utf8"),r+=a,i=n.routingKey,void 0===i&&(i=void 0),c[r]=u,r++,c.write(i,r,"utf8"),r+=u,i=n.messageCount,void 0===i)throw new Error("Missing value for mandatory field 'messageCount'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'messageCount' is the wrong type; must be a number (but not NaN)");return c.writeUInt32BE(i,r),r+=4,c[r]=206,c.writeUInt32BE(r-7,3),c}function Ve(e){var t,n,r=0,i={clusterId:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.clusterId=t,i}function Ge(e,n){var r=0,i=null,o=0;if(i=n.clusterId,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'clusterId' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=new t(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932232,7),r=11,i=n.clusterId,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function Ye(e){var t,n=0,r={deliveryTag:void 0,multiple:void 0};return t=St.readUInt64BE(e,n),n+=8,r.deliveryTag=t,t=!!(1&e[n]),r.multiple=t,r}function $e(e,n){var r=0,i=null,o=0,s=0,a=new t(21+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932240,7),r=11,i=n.deliveryTag,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryTag' is the wrong type; must be a number (but not NaN)");return St.writeUInt64BE(a,i,r),r+=8,i=n.multiple,void 0===i&&(i=!1),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function Xe(e){var t,n=0,r={deliveryTag:void 0,requeue:void 0};return t=St.readUInt64BE(e,n),n+=8,r.deliveryTag=t,t=!!(1&e[n]),r.requeue=t,r}function Je(e,n){var r=0,i=null,o=0,s=0,a=new t(21+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932250,7),r=11,i=n.deliveryTag,void 0===i)throw new Error("Missing value for mandatory field 'deliveryTag'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryTag' is the wrong type; must be a number (but not NaN)");return St.writeUInt64BE(a,i,r),r+=8,i=n.requeue,void 0===i&&(i=!0),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function Ze(e){var t,n=0,r={requeue:void 0};return t=!!(1&e[n]),r.requeue=t,r}function et(e,n){var r=0,i=null,o=0,s=0,a=new t(13+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932260,7),r=11,i=n.requeue,void 0===i&&(i=!1),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function tt(e){var t,n=0,r={requeue:void 0};return t=!!(1&e[n]),r.requeue=t,r}function nt(e,n){var r=0,i=null,o=0,s=0,a=new t(13+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932270,7),r=11,i=n.requeue,void 0===i&&(i=!1),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function rt(e){var t={};return t}function it(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(3932271,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function ot(e){var t,n=0,r={deliveryTag:void 0,multiple:void 0,requeue:void 0};return t=St.readUInt64BE(e,n),n+=8,r.deliveryTag=t,t=!!(1&e[n]),r.multiple=t,t=!!(2&e[n]),r.requeue=t,r}function st(e,n){var r=0,i=null,o=0,s=0,a=new t(21+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932280,7),r=11,i=n.deliveryTag,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryTag' is the wrong type; must be a number (but not NaN)");return St.writeUInt64BE(a,i,r),r+=8,i=n.multiple,void 0===i&&(i=!1),i&&(o+=1),i=n.requeue,void 0===i&&(i=!0),i&&(o+=2),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function at(e){var t={};return t}function ut(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898250,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function ct(e){var t={};return t}function lt(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898251,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function ft(e){var t={};return t}function ht(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898260,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function pt(e){var t={};return t}function dt(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898261,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function vt(e){var t={};return t}function gt(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898270,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function yt(e){var t={};return t}function mt(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898271,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function bt(e){var t,n=0,r={nowait:void 0};return t=!!(1&e[n]),r.nowait=t,r}function wt(e,n){var r=0,i=null,o=0,s=0,a=new t(13+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(5570570,7),r=11,i=n.nowait,void 0===i&&(i=!1),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function _t(e){var t={};return t}function Et(e,n){var r=0,i=0,o=new t(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5570571,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function xt(e,n,r){var i,o,s=0,a=0,u=0,c=0;if(i=r.contentType,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'contentType' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(i,"utf8");c+=1,c+=l}if(i=r.contentEncoding,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'contentEncoding' is the wrong type; must be a string (up to 255 chars)");var f=t.byteLength(i,"utf8");c+=1,c+=f}if(i=r.headers,void 0!=i){if("object"!=typeof i)throw new TypeError("Field 'headers' is the wrong type; must be an object");o=Ct(jt,i,u);var h=jt.slice(u,u+o);u+=o,c+=h.length}if(i=r.deliveryMode,void 0!=i){if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryMode' is the wrong type; must be a number (but not NaN)");c+=1}if(i=r.priority,void 0!=i){if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'priority' is the wrong type; must be a number (but not NaN)");c+=1}if(i=r.correlationId,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'correlationId' is the wrong type; must be a string (up to 255 chars)");var p=t.byteLength(i,"utf8");c+=1,c+=p}if(i=r.replyTo,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'replyTo' is the wrong type; must be a string (up to 255 chars)");var d=t.byteLength(i,"utf8");c+=1,c+=d}if(i=r.expiration,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'expiration' is the wrong type; must be a string (up to 255 chars)");var v=t.byteLength(i,"utf8");c+=1,c+=v}if(i=r.messageId,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'messageId' is the wrong type; must be a string (up to 255 chars)");var g=t.byteLength(i,"utf8");c+=1,c+=g}if(i=r.timestamp,void 0!=i){if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'timestamp' is the wrong type; must be a number (but not NaN)");c+=8}if(i=r.type,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'type' is the wrong type; must be a string (up to 255 chars)");var y=t.byteLength(i,"utf8");c+=1,c+=y}if(i=r.userId,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'userId' is the wrong type; must be a string (up to 255 chars)");var m=t.byteLength(i,"utf8");c+=1,c+=m}if(i=r.appId,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'appId' is the wrong type; must be a string (up to 255 chars)");var b=t.byteLength(i,"utf8");c+=1,c+=b}if(i=r.clusterId,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'clusterId' is the wrong type; must be a string (up to 255 chars)");var w=t.byteLength(i,"utf8");c+=1,c+=w}var _=new t(22+c);return _[0]=2,_.writeUInt16BE(e,1),_.writeUInt32BE(3932160,7),St.writeUInt64BE(_,n,11),a=0,s=21,i=r.contentType,void 0!=i&&(a+=32768,_[s]=l,s++,_.write(i,s,"utf8"),s+=l),i=r.contentEncoding,void 0!=i&&(a+=16384,_[s]=f,s++,_.write(i,s,"utf8"),s+=f),i=r.headers,void 0!=i&&(a+=8192,s+=h.copy(_,s)),i=r.deliveryMode,void 0!=i&&(a+=4096,_.writeUInt8(i,s),s++),i=r.priority,void 0!=i&&(a+=2048,_.writeUInt8(i,s),s++),i=r.correlationId,void 0!=i&&(a+=1024,_[s]=p,s++,_.write(i,s,"utf8"),s+=p),i=r.replyTo,void 0!=i&&(a+=512,_[s]=d,s++,_.write(i,s,"utf8"),s+=d),i=r.expiration,void 0!=i&&(a+=256,_[s]=v,s++,_.write(i,s,"utf8"),s+=v),i=r.messageId,void 0!=i&&(a+=128,_[s]=g,s++,_.write(i,s,"utf8"),s+=g),i=r.timestamp,void 0!=i&&(a+=64,St.writeUInt64BE(_,i,s),s+=8),i=r.type,void 0!=i&&(a+=32,_[s]=y,s++,_.write(i,s,"utf8"),s+=y),i=r.userId,void 0!=i&&(a+=16,_[s]=m,s++,_.write(i,s,"utf8"),s+=m),i=r.appId,void 0!=i&&(a+=8,_[s]=b,s++,_.write(i,s,"utf8"),s+=b),i=r.clusterId,void 0!=i&&(a+=4,_[s]=w,s++,_.write(i,s,"utf8"),s+=w),_[s]=206,_.writeUInt32BE(s-7,3),_.writeUInt16BE(a,19),_.slice(0,s+1)}function kt(e){var t,n,r,i=2;if(t=e.readUInt16BE(0),0===t)return{};var o={contentType:void 0,contentEncoding:void 0,headers:void 0,deliveryMode:void 0,priority:void 0,correlationId:void 0,replyTo:void 0,expiration:void 0,messageId:void 0,timestamp:void 0,type:void 0,userId:void 0,appId:void 0,clusterId:void 0};return 32768&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.contentType=n),16384&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.contentEncoding=n),8192&t&&(r=e.readUInt32BE(i),i+=4,n=Tt(e.slice(i,i+r)),i+=r,o.headers=n),4096&t&&(n=e[i],i++,o.deliveryMode=n),2048&t&&(n=e[i],i++,o.priority=n),1024&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.correlationId=n),512&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.replyTo=n),256&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.expiration=n),128&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.messageId=n),64&t&&(n=St.readUInt64BE(e,i),i+=8,o.timestamp=n),32&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.type=n),16&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.userId=n),8&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.appId=n),4&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.clusterId=n),o}var It=n(70),St=n(71),Ct=It.encodeTable,Tt=It.decodeFields,jt=new t(4096);Object.freeze({});e.exports.constants={FRAME_METHOD:1,FRAME_HEADER:2,FRAME_BODY:3,FRAME_HEARTBEAT:8,FRAME_MIN_SIZE:4096,FRAME_END:206,REPLY_SUCCESS:200,CONTENT_TOO_LARGE:311,NO_ROUTE:312,NO_CONSUMERS:313,ACCESS_REFUSED:403,NOT_FOUND:404,RESOURCE_LOCKED:405,PRECONDITION_FAILED:406,CONNECTION_FORCED:320,INVALID_PATH:402,FRAME_ERROR:501,SYNTAX_ERROR:502,COMMAND_INVALID:503,CHANNEL_ERROR:504,UNEXPECTED_FRAME:505,RESOURCE_ERROR:506,NOT_ALLOWED:530,NOT_IMPLEMENTED:540,INTERNAL_ERROR:541},e.exports.constant_strs={1:"FRAME-METHOD",2:"FRAME-HEADER",3:"FRAME-BODY",8:"FRAME-HEARTBEAT",200:"REPLY-SUCCESS",206:"FRAME-END",311:"CONTENT-TOO-LARGE",312:"NO-ROUTE",313:"NO-CONSUMERS",320:"CONNECTION-FORCED",402:"INVALID-PATH",403:"ACCESS-REFUSED",404:"NOT-FOUND",405:"RESOURCE-LOCKED",406:"PRECONDITION-FAILED",501:"FRAME-ERROR",502:"SYNTAX-ERROR",503:"COMMAND-INVALID",504:"CHANNEL-ERROR",505:"UNEXPECTED-FRAME",506:"RESOURCE-ERROR",530:"NOT-ALLOWED",540:"NOT-IMPLEMENTED",541:"INTERNAL-ERROR",4096:"FRAME-MIN-SIZE"},e.exports.FRAME_OVERHEAD=8,e.exports.decode=function(e,t){switch(e){case 655370:return r(t);case 655371:return o(t);case 655380:return a(t);case 655381:return c(t);case 655390:return f(t);case 655391:return p(t);case 655400:return v(t);case 655401:return y(t);case 655410:return b(t);case 655411:return _(t);case 655420:return x(t);case 655421:return I(t);case 1310730:return C(t);case 1310731:return j(t);case 1310740:return B(t);case 1310741:return A(t);case 1310760:return M(t);case 1310761:return F(t);case 1966090:return N(t);case 1966091:return q(t);case 2621450:return H(t);case 2621451:return W(t);case 2621460:return V(t);case 2621461:return Y(t);case 2621470:return X(t);case 2621471:return Z(t);case 2621480:return te(t);case 2621491:return re(t);case 3276810:return oe(t);case 3276811:return ae(t);case 3276820:return ce(t);case 3276821:return fe(t);case 3276830:return pe(t);case 3276831:return ve(t);case 3276840:return ye(t);case 3276841:return be(t);case 3276850:return _e(t);case 3276851:return xe(t);case 3932170:return Ie(t);case 3932171:return Ce(t);case 3932180:return je(t);case 3932181:return Be(t);case 3932190:return Ae(t);case 3932191:return Me(t);case 3932200:return Fe(t);case 3932210:return Ne(t);case 3932220:return qe(t);case 3932230:return He(t);case 3932231:return We(t);case 3932232:return Ve(t);case 3932240:return Ye(t);case 3932250:return Xe(t);case 3932260:return Ze(t);case 3932270:return tt(t);case 3932271:return rt(t);case 3932280:return ot(t);case 5898250:return at(t);case 5898251:return ct(t);case 5898260:return ft(t);case 5898261:return pt(t);case 5898270:return vt(t);case 5898271:return yt(t);case 5570570:return bt(t);case 5570571:return _t(t);case 60:return kt(t);default:throw new Error("Unknown class/method ID")}},e.exports.encodeMethod=function(e,t,n){switch(e){case 655370:return i(t,n);case 655371:return s(t,n);case 655380:return u(t,n);case 655381:return l(t,n);case 655390:return h(t,n);case 655391:return d(t,n);case 655400:return g(t,n);case 655401:return m(t,n);case 655410:return w(t,n);case 655411:return E(t,n);case 655420:return k(t,n);case 655421:return S(t,n);case 1310730:return T(t,n);case 1310731:return U(t,n);case 1310740:return O(t,n);case 1310741:return R(t,n);case 1310760:return L(t,n);case 1310761:return P(t,n);case 1966090:return D(t,n);case 1966091:return z(t,n);case 2621450:return Q(t,n);case 2621451:return K(t,n);case 2621460:return G(t,n);case 2621461:return $(t,n);case 2621470:return J(t,n);case 2621471:return ee(t,n);case 2621480:return ne(t,n);case 2621491:return ie(t,n);case 3276810:return se(t,n);case 3276811:return ue(t,n);case 3276820:return le(t,n);case 3276821:return he(t,n);case 3276830:return de(t,n);case 3276831:return ge(t,n);case 3276840:return me(t,n);case 3276841:return we(t,n);case 3276850:return Ee(t,n);case 3276851:return ke(t,n);case 3932170:return Se(t,n);case 3932171:return Te(t,n);case 3932180:return Ue(t,n);case 3932181:return Oe(t,n);case 3932190:return Re(t,n);case 3932191:return Le(t,n);case 3932200:return Pe(t,n);case 3932210:return De(t,n);case 3932220:return ze(t,n);case 3932230:return Qe(t,n);case 3932231:return Ke(t,n);case 3932232:return Ge(t,n);case 3932240:return $e(t,n);case 3932250:return Je(t,n);case 3932260:return et(t,n);case 3932270:return nt(t,n);case 3932271:return it(t,n);case 3932280:return st(t,n);case 5898250:return ut(t,n);case 5898251:return lt(t,n);case 5898260:return ht(t,n);case 5898261:return dt(t,n);case 5898270:return gt(t,n);case 5898271:return mt(t,n);case 5570570:return wt(t,n);case 5570571:return Et(t,n);default:throw new Error("Unknown class/method ID")}},e.exports.encodeProperties=function(e,t,n,r){switch(e){case 60:return xt(t,n,r);default:throw new Error("Unknown class/properties ID")}},e.exports.info=function(e){switch(e){case 655370:return Ut;case 655371:return Bt;case 655380:return Ot;case 655381:return At;case 655390:return Rt;case 655391:return Mt;case 655400:return Lt;case 655401:return Ft;case 655410:return Pt;case 655411:return Nt;case 655420:return Dt;case 655421:return qt;case 1310730:return zt;case 1310731:return Ht;case 1310740:return Qt;case 1310741:return Wt;case 1310760:return Kt;case 1310761:return Vt;case 1966090:return Gt;case 1966091:return Yt;case 2621450:return $t;case 2621451:return Xt;case 2621460:return Jt;case 2621461:return Zt;case 2621470:return en;case 2621471:return tn;case 2621480:return nn;case 2621491:return rn;case 3276810:return on;case 3276811:return sn;case 3276820:return an;case 3276821:return un;case 3276830:return cn;case 3276831:return ln;case 3276840:return fn;case 3276841:return hn;case 3276850:return pn;case 3276851:return dn;case 3932170:return vn;case 3932171:return gn;case 3932180:return yn;case 3932181:return mn;case 3932190:return bn;case 3932191:return wn;case 3932200:return _n;case 3932210:return En;case 3932220:return xn;case 3932230:return kn;case 3932231:return In;case 3932232:return Sn;case 3932240:return Cn;case 3932250:return Tn;case 3932260:return jn;case 3932270:return Un;case 3932271:return Bn;case 3932280:return On;case 5898250:return An;case 5898251:return Rn;case 5898260:return Mn;case 5898261:return Ln;case 5898270:return Fn;case 5898271:return Pn;case 5570570:return Nn;case 5570571:return Dn;case 60:return qn;default:throw new Error("Unknown class/method ID")}},e.exports.ConnectionStart=655370;var Ut=e.exports.methodInfoConnectionStart={id:655370,name:"ConnectionStart",args:[{type:"octet",name:"versionMajor","default":0},{type:"octet",name:"versionMinor","default":9},{type:"table",name:"serverProperties"},{type:"longstr",name:"mechanisms","default":"PLAIN"},{type:"longstr",name:"locales","default":"en_US"}]};e.exports.ConnectionStartOk=655371;var Bt=e.exports.methodInfoConnectionStartOk={id:655371,name:"ConnectionStartOk",args:[{type:"table",name:"clientProperties"},{type:"shortstr",name:"mechanism","default":"PLAIN"},{type:"longstr",name:"response"},{type:"shortstr",name:"locale","default":"en_US"}]};e.exports.ConnectionSecure=655380;var Ot=e.exports.methodInfoConnectionSecure={id:655380,name:"ConnectionSecure",args:[{type:"longstr",name:"challenge"}]};e.exports.ConnectionSecureOk=655381;var At=e.exports.methodInfoConnectionSecureOk={id:655381,name:"ConnectionSecureOk",args:[{type:"longstr",name:"response"}]};e.exports.ConnectionTune=655390;var Rt=e.exports.methodInfoConnectionTune={id:655390,name:"ConnectionTune",args:[{type:"short",name:"channelMax","default":0},{type:"long",name:"frameMax","default":0},{type:"short",name:"heartbeat","default":0}]};e.exports.ConnectionTuneOk=655391;var Mt=e.exports.methodInfoConnectionTuneOk={id:655391,name:"ConnectionTuneOk",args:[{type:"short",name:"channelMax","default":0},{type:"long",name:"frameMax","default":0},{type:"short",name:"heartbeat","default":0}]};e.exports.ConnectionOpen=655400;var Lt=e.exports.methodInfoConnectionOpen={id:655400,name:"ConnectionOpen",args:[{type:"shortstr",name:"virtualHost","default":"/"},{type:"shortstr",name:"capabilities","default":""},{type:"bit",name:"insist","default":!1}]};e.exports.ConnectionOpenOk=655401;var Ft=e.exports.methodInfoConnectionOpenOk={id:655401,name:"ConnectionOpenOk",args:[{type:"shortstr",name:"knownHosts","default":""}]};e.exports.ConnectionClose=655410;var Pt=e.exports.methodInfoConnectionClose={id:655410,name:"ConnectionClose",args:[{type:"short",name:"replyCode"},{type:"shortstr",name:"replyText","default":""},{type:"short",name:"classId"},{type:"short",name:"methodId"}]};e.exports.ConnectionCloseOk=655411;var Nt=e.exports.methodInfoConnectionCloseOk={id:655411,name:"ConnectionCloseOk",args:[]};e.exports.ConnectionBlocked=655420;var Dt=e.exports.methodInfoConnectionBlocked={id:655420,name:"ConnectionBlocked",args:[{type:"shortstr",name:"reason","default":""}]};e.exports.ConnectionUnblocked=655421;var qt=e.exports.methodInfoConnectionUnblocked={id:655421,name:"ConnectionUnblocked",args:[]};e.exports.ChannelOpen=1310730;var zt=e.exports.methodInfoChannelOpen={id:1310730,name:"ChannelOpen",args:[{type:"shortstr",name:"outOfBand","default":""}]};e.exports.ChannelOpenOk=1310731;var Ht=e.exports.methodInfoChannelOpenOk={id:1310731,name:"ChannelOpenOk",args:[{type:"longstr",name:"channelId","default":""}]};e.exports.ChannelFlow=1310740;var Qt=e.exports.methodInfoChannelFlow={id:1310740,name:"ChannelFlow",args:[{type:"bit",name:"active" -}]};e.exports.ChannelFlowOk=1310741;var Wt=e.exports.methodInfoChannelFlowOk={id:1310741,name:"ChannelFlowOk",args:[{type:"bit",name:"active"}]};e.exports.ChannelClose=1310760;var Kt=e.exports.methodInfoChannelClose={id:1310760,name:"ChannelClose",args:[{type:"short",name:"replyCode"},{type:"shortstr",name:"replyText","default":""},{type:"short",name:"classId"},{type:"short",name:"methodId"}]};e.exports.ChannelCloseOk=1310761;var Vt=e.exports.methodInfoChannelCloseOk={id:1310761,name:"ChannelCloseOk",args:[]};e.exports.AccessRequest=1966090;var Gt=e.exports.methodInfoAccessRequest={id:1966090,name:"AccessRequest",args:[{type:"shortstr",name:"realm","default":"/data"},{type:"bit",name:"exclusive","default":!1},{type:"bit",name:"passive","default":!0},{type:"bit",name:"active","default":!0},{type:"bit",name:"write","default":!0},{type:"bit",name:"read","default":!0}]};e.exports.AccessRequestOk=1966091;var Yt=e.exports.methodInfoAccessRequestOk={id:1966091,name:"AccessRequestOk",args:[{type:"short",name:"ticket","default":1}]};e.exports.ExchangeDeclare=2621450;var $t=e.exports.methodInfoExchangeDeclare={id:2621450,name:"ExchangeDeclare",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"type","default":"direct"},{type:"bit",name:"passive","default":!1},{type:"bit",name:"durable","default":!1},{type:"bit",name:"autoDelete","default":!1},{type:"bit",name:"internal","default":!1},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.ExchangeDeclareOk=2621451;var Xt=e.exports.methodInfoExchangeDeclareOk={id:2621451,name:"ExchangeDeclareOk",args:[]};e.exports.ExchangeDelete=2621460;var Jt=e.exports.methodInfoExchangeDelete={id:2621460,name:"ExchangeDelete",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"exchange"},{type:"bit",name:"ifUnused","default":!1},{type:"bit",name:"nowait","default":!1}]};e.exports.ExchangeDeleteOk=2621461;var Zt=e.exports.methodInfoExchangeDeleteOk={id:2621461,name:"ExchangeDeleteOk",args:[]};e.exports.ExchangeBind=2621470;var en=e.exports.methodInfoExchangeBind={id:2621470,name:"ExchangeBind",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"destination"},{type:"shortstr",name:"source"},{type:"shortstr",name:"routingKey","default":""},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.ExchangeBindOk=2621471;var tn=e.exports.methodInfoExchangeBindOk={id:2621471,name:"ExchangeBindOk",args:[]};e.exports.ExchangeUnbind=2621480;var nn=e.exports.methodInfoExchangeUnbind={id:2621480,name:"ExchangeUnbind",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"destination"},{type:"shortstr",name:"source"},{type:"shortstr",name:"routingKey","default":""},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.ExchangeUnbindOk=2621491;var rn=e.exports.methodInfoExchangeUnbindOk={id:2621491,name:"ExchangeUnbindOk",args:[]};e.exports.QueueDeclare=3276810;var on=e.exports.methodInfoQueueDeclare={id:3276810,name:"QueueDeclare",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"bit",name:"passive","default":!1},{type:"bit",name:"durable","default":!1},{type:"bit",name:"exclusive","default":!1},{type:"bit",name:"autoDelete","default":!1},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.QueueDeclareOk=3276811;var sn=e.exports.methodInfoQueueDeclareOk={id:3276811,name:"QueueDeclareOk",args:[{type:"shortstr",name:"queue"},{type:"long",name:"messageCount"},{type:"long",name:"consumerCount"}]};e.exports.QueueBind=3276820;var an=e.exports.methodInfoQueueBind={id:3276820,name:"QueueBind",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"routingKey","default":""},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.QueueBindOk=3276821;var un=e.exports.methodInfoQueueBindOk={id:3276821,name:"QueueBindOk",args:[]};e.exports.QueuePurge=3276830;var cn=e.exports.methodInfoQueuePurge={id:3276830,name:"QueuePurge",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"bit",name:"nowait","default":!1}]};e.exports.QueuePurgeOk=3276831;var ln=e.exports.methodInfoQueuePurgeOk={id:3276831,name:"QueuePurgeOk",args:[{type:"long",name:"messageCount"}]};e.exports.QueueDelete=3276840;var fn=e.exports.methodInfoQueueDelete={id:3276840,name:"QueueDelete",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"bit",name:"ifUnused","default":!1},{type:"bit",name:"ifEmpty","default":!1},{type:"bit",name:"nowait","default":!1}]};e.exports.QueueDeleteOk=3276841;var hn=e.exports.methodInfoQueueDeleteOk={id:3276841,name:"QueueDeleteOk",args:[{type:"long",name:"messageCount"}]};e.exports.QueueUnbind=3276850;var pn=e.exports.methodInfoQueueUnbind={id:3276850,name:"QueueUnbind",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"routingKey","default":""},{type:"table",name:"arguments","default":{}}]};e.exports.QueueUnbindOk=3276851;var dn=e.exports.methodInfoQueueUnbindOk={id:3276851,name:"QueueUnbindOk",args:[]};e.exports.BasicQos=3932170;var vn=e.exports.methodInfoBasicQos={id:3932170,name:"BasicQos",args:[{type:"long",name:"prefetchSize","default":0},{type:"short",name:"prefetchCount","default":0},{type:"bit",name:"global","default":!1}]};e.exports.BasicQosOk=3932171;var gn=e.exports.methodInfoBasicQosOk={id:3932171,name:"BasicQosOk",args:[]};e.exports.BasicConsume=3932180;var yn=e.exports.methodInfoBasicConsume={id:3932180,name:"BasicConsume",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"shortstr",name:"consumerTag","default":""},{type:"bit",name:"noLocal","default":!1},{type:"bit",name:"noAck","default":!1},{type:"bit",name:"exclusive","default":!1},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.BasicConsumeOk=3932181;var mn=e.exports.methodInfoBasicConsumeOk={id:3932181,name:"BasicConsumeOk",args:[{type:"shortstr",name:"consumerTag"}]};e.exports.BasicCancel=3932190;var bn=e.exports.methodInfoBasicCancel={id:3932190,name:"BasicCancel",args:[{type:"shortstr",name:"consumerTag"},{type:"bit",name:"nowait","default":!1}]};e.exports.BasicCancelOk=3932191;var wn=e.exports.methodInfoBasicCancelOk={id:3932191,name:"BasicCancelOk",args:[{type:"shortstr",name:"consumerTag"}]};e.exports.BasicPublish=3932200;var _n=e.exports.methodInfoBasicPublish={id:3932200,name:"BasicPublish",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"exchange","default":""},{type:"shortstr",name:"routingKey","default":""},{type:"bit",name:"mandatory","default":!1},{type:"bit",name:"immediate","default":!1}]};e.exports.BasicReturn=3932210;var En=e.exports.methodInfoBasicReturn={id:3932210,name:"BasicReturn",args:[{type:"short",name:"replyCode"},{type:"shortstr",name:"replyText","default":""},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"routingKey"}]};e.exports.BasicDeliver=3932220;var xn=e.exports.methodInfoBasicDeliver={id:3932220,name:"BasicDeliver",args:[{type:"shortstr",name:"consumerTag"},{type:"longlong",name:"deliveryTag"},{type:"bit",name:"redelivered","default":!1},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"routingKey"}]};e.exports.BasicGet=3932230;var kn=e.exports.methodInfoBasicGet={id:3932230,name:"BasicGet",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"bit",name:"noAck","default":!1}]};e.exports.BasicGetOk=3932231;var In=e.exports.methodInfoBasicGetOk={id:3932231,name:"BasicGetOk",args:[{type:"longlong",name:"deliveryTag"},{type:"bit",name:"redelivered","default":!1},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"routingKey"},{type:"long",name:"messageCount"}]};e.exports.BasicGetEmpty=3932232;var Sn=e.exports.methodInfoBasicGetEmpty={id:3932232,name:"BasicGetEmpty",args:[{type:"shortstr",name:"clusterId","default":""}]};e.exports.BasicAck=3932240;var Cn=e.exports.methodInfoBasicAck={id:3932240,name:"BasicAck",args:[{type:"longlong",name:"deliveryTag","default":0},{type:"bit",name:"multiple","default":!1}]};e.exports.BasicReject=3932250;var Tn=e.exports.methodInfoBasicReject={id:3932250,name:"BasicReject",args:[{type:"longlong",name:"deliveryTag"},{type:"bit",name:"requeue","default":!0}]};e.exports.BasicRecoverAsync=3932260;var jn=e.exports.methodInfoBasicRecoverAsync={id:3932260,name:"BasicRecoverAsync",args:[{type:"bit",name:"requeue","default":!1}]};e.exports.BasicRecover=3932270;var Un=e.exports.methodInfoBasicRecover={id:3932270,name:"BasicRecover",args:[{type:"bit",name:"requeue","default":!1}]};e.exports.BasicRecoverOk=3932271;var Bn=e.exports.methodInfoBasicRecoverOk={id:3932271,name:"BasicRecoverOk",args:[]};e.exports.BasicNack=3932280;var On=e.exports.methodInfoBasicNack={id:3932280,name:"BasicNack",args:[{type:"longlong",name:"deliveryTag","default":0},{type:"bit",name:"multiple","default":!1},{type:"bit",name:"requeue","default":!0}]};e.exports.TxSelect=5898250;var An=e.exports.methodInfoTxSelect={id:5898250,name:"TxSelect",args:[]};e.exports.TxSelectOk=5898251;var Rn=e.exports.methodInfoTxSelectOk={id:5898251,name:"TxSelectOk",args:[]};e.exports.TxCommit=5898260;var Mn=e.exports.methodInfoTxCommit={id:5898260,name:"TxCommit",args:[]};e.exports.TxCommitOk=5898261;var Ln=e.exports.methodInfoTxCommitOk={id:5898261,name:"TxCommitOk",args:[]};e.exports.TxRollback=5898270;var Fn=e.exports.methodInfoTxRollback={id:5898270,name:"TxRollback",args:[]};e.exports.TxRollbackOk=5898271;var Pn=e.exports.methodInfoTxRollbackOk={id:5898271,name:"TxRollbackOk",args:[]};e.exports.ConfirmSelect=5570570;var Nn=e.exports.methodInfoConfirmSelect={id:5570570,name:"ConfirmSelect",args:[{type:"bit",name:"nowait","default":!1}]};e.exports.ConfirmSelectOk=5570571;var Dn=e.exports.methodInfoConfirmSelectOk={id:5570571,name:"ConfirmSelectOk",args:[]};e.exports.BasicProperties=60;var qn=e.exports.propertiesInfoBasicProperties={id:60,name:"BasicProperties",args:[{type:"shortstr",name:"contentType"},{type:"shortstr",name:"contentEncoding"},{type:"table",name:"headers"},{type:"octet",name:"deliveryMode"},{type:"octet",name:"priority"},{type:"shortstr",name:"correlationId"},{type:"shortstr",name:"replyTo"},{type:"shortstr",name:"expiration"},{type:"shortstr",name:"messageId"},{type:"timestamp",name:"timestamp"},{type:"shortstr",name:"type"},{type:"shortstr",name:"userId"},{type:"shortstr",name:"appId"},{type:"shortstr",name:"clusterId"}]}}).call(t,n(3).Buffer)},function(e,t,n){(function(t){"use strict";function r(e){return e>=0x8000000000000000||Math.abs(e)<0x4000000000000&&Math.floor(e)!==e}function i(e,n,r){var i=r;r+=4;for(var o in n)if(void 0!==n[o]){var a=t.byteLength(o);e.writeUInt8(a,r),r++,e.write(o,r,"utf8"),r+=a,r+=s(e,n[o],r)}var u=r-i;return e.writeUInt32BE(u-4,i),u}function o(e,t,n){var r=n;n+=4;for(var i=0,o=t.length;i=-128?(a("b"),e.writeInt8(f,s),s++):f>=-32768&&f<32768?(a("s"),e.writeInt16BE(f,s),s+=2):f>=-2147483648&&f<2147483648?(a("I"),e.writeInt32BE(f,s),s+=4):(a("l"),u.writeInt64BE(e,f,s),s+=8);break;case"timestamp":a("T"),u.writeUInt64BE(e,f,s),s+=8;break;case"float":a("f"),e.writeFloatBE(f,s),s+=4;break;case"decimal":if(a("D"),!(f.hasOwnProperty("places")&&f.hasOwnProperty("digits")&&f.places>=0&&f.places<256))throw new TypeError("Decimal value must be {'places': 0..255, 'digits': uint32}, got "+JSON.stringify(f));e[s]=f.places,s++,e.writeUInt32BE(f.digits,s),s+=4;break;default:throw new TypeError("Unknown type to encode: "+l)}return s-c}function a(e){function t(){var t=String.fromCharCode(e[c]);switch(c++,t){case"b":o=e.readInt8(c),c++;break;case"S":r=e.readUInt32BE(c),c+=4,o=e.toString("utf8",c,c+r),c+=r;break;case"I":o=e.readInt32BE(c),c+=4;break;case"D":var i=e[c];c++;var s=e.readUInt32BE(c);c+=4,o={"!":"decimal",value:{places:i,digits:s}};break;case"T":o=u.readUInt64BE(e,c),c+=8,o={"!":"timestamp",value:o};break;case"F":r=e.readUInt32BE(c),c+=4,o=a(e.slice(c,c+r)),c+=r;break;case"A":r=e.readUInt32BE(c),c+=4,n(c+r);break;case"d":o=e.readDoubleBE(c),c+=8;break;case"f":o=e.readFloatBE(c),c+=4;break;case"l":o=u.readInt64BE(e,c),c+=8;break;case"s":o=e.readInt16BE(c),c+=2;break;case"t":o=0!=e[c],c++;break;case"V":o=null;break;case"x":r=e.readUInt32BE(c),c+=4,o=e.slice(c,c+r),c+=r;break;default:throw new TypeError('Unexpected type tag "'+t+'"')}}function n(e){for(var n=[];c=-Y}function i(e){K(r(e),"number cannot be represented as a contiguous integer")}function o(e,t,n){K.ok("number"==typeof e&&e>=t&&e<=n&&Math.floor(e)===e,"not a number in the required range")}function s(e,t,n){return e.readUInt8(t,n)<<16|e.readUInt16BE(t+1,n)}function a(e,t,n,r){r||(o(t,0,16777215),K.ok(n+3<=e.length,"attempt to write beyond end of buffer")),e.writeUInt8(t>>>16,n,r),e.writeUInt16BE(65535&t,n+1,r)}function u(e,t,n){return(e.readUInt8(t,n)||0)*V+e.readUInt32BE(t+1,n)}function c(e,t,n,r){r||(o(t,0,0xffffffffff),K.ok(n+5<=e.length,"attempt to write beyond end of buffer")),e.writeUInt8(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+1,r)}function l(e,t,n){return e.readUInt16BE(t,n)*V+e.readUInt32BE(t+2,n)}function f(e,t,n,r){r||(o(t,0,0xffffffffffff),K.ok(n+6<=e.length,"attempt to write beyond end of buffer")),e.writeUInt16BE(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+2,r)}function h(e,t,n){return((e.readUInt8(t,n)||0)<<16|e.readUInt16BE(t+1,n))*V+e.readUInt32BE(t+3,n)}function p(e,t,n,r){if(r||(o(t,0,72057594037927940),K.ok(n+7<=e.length,"attempt to write beyond end of buffer")),t<72057594037927940){var i=Math.floor(t*G);e.writeUInt8(i>>>16,n,r),e.writeUInt16BE(65535&i,n+1,r),e.writeInt32BE(t&-1,n+3,r)}else e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255}function d(e,t,n){return e.readUInt32BE(t,n)*V+e.readUInt32BE(t+4,n)}function v(e,t,n,r){r||(o(t,0,0x10000000000000000),K.ok(n+8<=e.length,"attempt to write beyond end of buffer")),t<0x10000000000000000?(e.writeUInt32BE(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+4,r)):(e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255,e[n+7]=255)}function g(e,t,n){return e.readUInt8(t+2,n)<<16|e.readUInt16LE(t,n)}function y(e,t,n,r){r||(o(t,0,16777215),K.ok(n+3<=e.length,"attempt to write beyond end of buffer")),e.writeUInt16LE(65535&t,n,r),e.writeUInt8(t>>>16,n+2,r)}function m(e,t,n){return(e.readUInt8(t+4,n)||0)*V+e.readUInt32LE(t,n)}function b(e,t,n,r){r||(o(t,0,0xffffffffff),K.ok(n+5<=e.length,"attempt to write beyond end of buffer")),e.writeInt32LE(t&-1,n,r),e.writeUInt8(Math.floor(t*G),n+4,r)}function w(e,t,n){return e.readUInt16LE(t+4,n)*V+e.readUInt32LE(t,n)}function _(e,t,n,r){r||(o(t,0,0xffffffffffff),K.ok(n+6<=e.length,"attempt to write beyond end of buffer")),e.writeInt32LE(t&-1,n,r),e.writeUInt16LE(Math.floor(t*G),n+4,r)}function E(e,t,n){return((e.readUInt8(t+6,n)||0)<<16|e.readUInt16LE(t+4,n))*V+e.readUInt32LE(t,n)}function x(e,t,n,r){if(r||(o(t,0,72057594037927940),K.ok(n+7<=e.length,"attempt to write beyond end of buffer")),t<72057594037927940){e.writeInt32LE(t&-1,n,r);var i=Math.floor(t*G);e.writeUInt16LE(65535&i,n+4,r),e.writeUInt8(i>>>16,n+6,r)}else e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255}function k(e,t,n){return e.readUInt32LE(t+4,n)*V+e.readUInt32LE(t,n)}function I(e,t,n,r){r||(o(t,0,0x10000000000000000),K.ok(n+8<=e.length,"attempt to write beyond end of buffer")),t<0x10000000000000000?(e.writeInt32LE(t&-1,n,r),e.writeUInt32LE(Math.floor(t*G),n+4,r)):(e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255,e[n+7]=255)}function S(e,t,n){return(e.readInt8(t,n)<<16)+e.readUInt16BE(t+1,n)}function C(e,t,n,r){r||(o(t,-8388608,8388607),K.ok(n+3<=e.length,"attempt to write beyond end of buffer")),e.writeInt8(t>>16,n,r),e.writeUInt16BE(65535&t,n+1,r)}function T(e,t,n){return(e.readInt8(t,n)||0)*V+e.readUInt32BE(t+1,n)}function j(e,t,n,r){r||(o(t,-549755813888,549755813887),K.ok(n+5<=e.length,"attempt to write beyond end of buffer")),e.writeInt8(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+1,r)}function U(e,t,n){return e.readInt16BE(t,n)*V+e.readUInt32BE(t+2,n)}function B(e,t,n,r){r||(o(t,-0x800000000000,0x7fffffffffff),K.ok(n+6<=e.length,"attempt to write beyond end of buffer")),e.writeInt16BE(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+2,r)}function O(e,t,n){return(((e.readInt8(t,n)||0)<<16)+e.readUInt16BE(t+1,n))*V+e.readUInt32BE(t+3,n)}function A(e,t,n,r){if(r||(o(t,-0x800000000000000,0x80000000000000),K.ok(n+7<=e.length,"attempt to write beyond end of buffer")),t<0x80000000000000){var i=Math.floor(t*G);e.writeInt8(i>>16,n,r),e.writeUInt16BE(65535&i,n+1,r),e.writeInt32BE(t&-1,n+3,r)}else e[n]=127,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255}function R(e,t,n){return e.readInt32BE(t,n)*V+e.readUInt32BE(t+4,n)}function M(e,t,n,r){r||(o(t,-0x800000000000000000,0x8000000000000000),K.ok(n+8<=e.length,"attempt to write beyond end of buffer")),t<0x8000000000000000?(e.writeInt32BE(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+4,r)):(e[n]=127,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255,e[n+7]=255)}function L(e,t,n){return(e.readInt8(t+2,n)<<16)+e.readUInt16LE(t,n)}function F(e,t,n,r){r||(o(t,-8388608,8388607),K.ok(n+3<=e.length,"attempt to write beyond end of buffer")),e.writeUInt16LE(65535&t,n,r),e.writeInt8(t>>16,n+2,r)}function P(e,t,n){return(e.readInt8(t+4,n)||0)*V+e.readUInt32LE(t,n)}function N(e,t,n,r){r||(o(t,-549755813888,549755813887),K.ok(n+5<=e.length,"attempt to write beyond end of buffer")),e.writeInt32LE(t&-1,n,r),e.writeInt8(Math.floor(t*G),n+4,r)}function D(e,t,n){return e.readInt16LE(t+4,n)*V+e.readUInt32LE(t,n)}function q(e,t,n,r){r||(o(t,-0x800000000000,0x7fffffffffff),K.ok(n+6<=e.length,"attempt to write beyond end of buffer")),e.writeInt32LE(t&-1,n,r),e.writeInt16LE(Math.floor(t*G),n+4,r)}function z(e,t,n){return(((e.readInt8(t+6,n)||0)<<16)+e.readUInt16LE(t+4,n))*V+e.readUInt32LE(t,n)}function H(e,t,n,r){if(r||(o(t,-0x80000000000000,0x80000000000000),K.ok(n+7<=e.length,"attempt to write beyond end of buffer")),t<0x80000000000000){e.writeInt32LE(t&-1,n,r);var i=Math.floor(t*G);e.writeUInt16LE(65535&i,n+4,r),e.writeInt8(i>>16,n+6,r)}else e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=127}function Q(e,t,n){return e.readInt32LE(t+4,n)*V+e.readUInt32LE(t,n)}function W(e,t,n,r){r||(o(t,-0x8000000000000000,0x8000000000000000),K.ok(n+8<=e.length,"attempt to write beyond end of buffer")),t<0x8000000000000000?(e.writeInt32LE(t&-1,n,r),e.writeInt32LE(Math.floor(t*G),n+4,r)):(e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255,e[n+7]=127)}var K=n(72),V=4294967296,G=1/V,Y=9007199254740991;e.exports.isContiguousInt=r,e.exports.assertContiguousInt=i,["UInt","Int"].forEach(function(n){var r=n+"8";e.exports["read"+r]=t.prototype["read"+r].call,e.exports["write"+r]=t.prototype["write"+r].call,["16","32"].forEach(function(r){["LE","BE"].forEach(function(i){var o=n+r+i,s=t.prototype["read"+o];e.exports["read"+o]=function(e,t,n){return s.call(e,t,n)};var a=t.prototype["write"+o];e.exports["write"+o]=function(e,t,n,r){return a.call(e,t,n,r)}})})}),e.exports.readUInt24BE=s,e.exports.writeUInt24BE=a,e.exports.readUInt40BE=u,e.exports.writeUInt40BE=c,e.exports.readUInt48BE=l,e.exports.writeUInt48BE=f,e.exports.readUInt56BE=h,e.exports.writeUInt56BE=p,e.exports.readUInt64BE=d,e.exports.writeUInt64BE=v,e.exports.readUInt24LE=g,e.exports.writeUInt24LE=y,e.exports.readUInt40LE=m,e.exports.writeUInt40LE=b,e.exports.readUInt48LE=w,e.exports.writeUInt48LE=_,e.exports.readUInt56LE=E,e.exports.writeUInt56LE=x,e.exports.readUInt64LE=k,e.exports.writeUInt64LE=I,e.exports.readInt24BE=S,e.exports.writeInt24BE=C,e.exports.readInt40BE=T,e.exports.writeInt40BE=j,e.exports.readInt48BE=U,e.exports.writeInt48BE=B,e.exports.readInt56BE=O,e.exports.writeInt56BE=A,e.exports.readInt64BE=R,e.exports.writeInt64BE=M,e.exports.readInt24LE=L,e.exports.writeInt24LE=F,e.exports.readInt40LE=P,e.exports.writeInt40LE=N,e.exports.readInt48LE=D,e.exports.writeInt48LE=q,e.exports.readInt56LE=z,e.exports.writeInt56LE=H,e.exports.readInt64LE=Q,e.exports.writeInt64LE=W}).call(t,n(3).Buffer)},function(e,t,n){(function(t){"use strict";/*! +"use strict";function r(e){var t,n,r=0,i={versionMajor:void 0,versionMinor:void 0,serverProperties:void 0,mechanisms:void 0,locales:void 0};return t=e[r],r++,i.versionMajor=t,t=e[r],r++,i.versionMinor=t,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.serverProperties=t,n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.mechanisms=t,n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.locales=t,i}function i(e,n){var r,i=0,o=null,s=0,a=0;if(o=n.serverProperties,void 0===o)throw new Error("Missing value for mandatory field 'serverProperties'");if("object"!=typeof o)throw new TypeError("Field 'serverProperties' is the wrong type; must be an object");r=St(Bt,o,a);var u=Bt.slice(a,a+r);if(a+=r,s+=u.length,o=n.mechanisms,void 0===o)o=t.from("PLAIN");else if(!t.isBuffer(o))throw new TypeError("Field 'mechanisms' is the wrong type; must be a Buffer");if(s+=o.length,o=n.locales,void 0===o)o=t.from("en_US");else if(!t.isBuffer(o))throw new TypeError("Field 'locales' is the wrong type; must be a Buffer");s+=o.length;var c=t.alloc(22+s);if(c[0]=1,c.writeUInt16BE(e,1),c.writeUInt32BE(655370,7),i=11,o=n.versionMajor,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'versionMajor' is the wrong type; must be a number (but not NaN)");if(c.writeUInt8(o,i),i++,o=n.versionMinor,void 0===o)o=9;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'versionMinor' is the wrong type; must be a number (but not NaN)");return c.writeUInt8(o,i),i++,i+=u.copy(c,i),o=n.mechanisms,void 0===o&&(o=t.from("PLAIN")),r=o.length,c.writeUInt32BE(r,i),i+=4,o.copy(c,i),i+=r,o=n.locales,void 0===o&&(o=t.from("en_US")),r=o.length,c.writeUInt32BE(r,i),i+=4,o.copy(c,i),i+=r,c[i]=206,c.writeUInt32BE(i-7,3),c}function o(e){var t,n,r=0,i={clientProperties:void 0,mechanism:void 0,response:void 0,locale:void 0};return n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.clientProperties=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.mechanism=t,n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.response=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.locale=t,i}function s(e,n){var r,i=0,o=null,s=0,a=0;if(o=n.clientProperties,void 0===o)throw new Error("Missing value for mandatory field 'clientProperties'");if("object"!=typeof o)throw new TypeError("Field 'clientProperties' is the wrong type; must be an object");r=St(Bt,o,a);var u=Bt.slice(a,a+r);if(a+=r,s+=u.length,o=n.mechanism,void 0===o)o="PLAIN";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'mechanism' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(s+=c,o=n.response,void 0===o)throw new Error("Missing value for mandatory field 'response'");if(!t.isBuffer(o))throw new TypeError("Field 'response' is the wrong type; must be a Buffer");if(s+=o.length,o=n.locale,void 0===o)o="en_US";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'locale' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");s+=l;var f=t.alloc(18+s);return f[0]=1,f.writeUInt16BE(e,1),f.writeUInt32BE(655371,7),i=11,i+=u.copy(f,i),o=n.mechanism,void 0===o&&(o="PLAIN"),f[i]=c,i++,f.write(o,i,"utf8"),i+=c,o=n.response,void 0===o&&(o=t.from(void 0)),r=o.length,f.writeUInt32BE(r,i),i+=4,o.copy(f,i),i+=r,o=n.locale,void 0===o&&(o="en_US"),f[i]=l,i++,f.write(o,i,"utf8"),i+=l,f[i]=206,f.writeUInt32BE(i-7,3),f}function a(e){var t,n,r=0,i={challenge:void 0};return n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.challenge=t,i}function u(e,n){var r,i=0,o=null,s=0;if(o=n.challenge,void 0===o)throw new Error("Missing value for mandatory field 'challenge'");if(!t.isBuffer(o))throw new TypeError("Field 'challenge' is the wrong type; must be a Buffer");s+=o.length;var a=t.alloc(16+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(655380,7),i=11,o=n.challenge,void 0===o&&(o=t.from(void 0)),r=o.length,a.writeUInt32BE(r,i),i+=4,o.copy(a,i),i+=r,a[i]=206,a.writeUInt32BE(i-7,3),a}function c(e){var t,n,r=0,i={response:void 0};return n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.response=t,i}function l(e,n){var r,i=0,o=null,s=0;if(o=n.response,void 0===o)throw new Error("Missing value for mandatory field 'response'");if(!t.isBuffer(o))throw new TypeError("Field 'response' is the wrong type; must be a Buffer");s+=o.length;var a=t.alloc(16+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(655381,7),i=11,o=n.response,void 0===o&&(o=t.from(void 0)),r=o.length,a.writeUInt32BE(r,i),i+=4,o.copy(a,i),i+=r,a[i]=206,a.writeUInt32BE(i-7,3),a}function f(e){var t,n=0,r={channelMax:void 0,frameMax:void 0,heartbeat:void 0};return t=e.readUInt16BE(n),n+=2,r.channelMax=t,t=e.readUInt32BE(n),n+=4,r.frameMax=t,t=e.readUInt16BE(n),n+=2,r.heartbeat=t,r}function h(e,n){var r=0,i=null,o=0,s=t.alloc(20+o);if(s[0]=1,s.writeUInt16BE(e,1),s.writeUInt32BE(655390,7),r=11,i=n.channelMax,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'channelMax' is the wrong type; must be a number (but not NaN)");if(s.writeUInt16BE(i,r),r+=2,i=n.frameMax,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'frameMax' is the wrong type; must be a number (but not NaN)");if(s.writeUInt32BE(i,r),r+=4,i=n.heartbeat,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'heartbeat' is the wrong type; must be a number (but not NaN)");return s.writeUInt16BE(i,r),r+=2,s[r]=206,s.writeUInt32BE(r-7,3),s}function p(e){var t,n=0,r={channelMax:void 0,frameMax:void 0,heartbeat:void 0};return t=e.readUInt16BE(n),n+=2,r.channelMax=t,t=e.readUInt32BE(n),n+=4,r.frameMax=t,t=e.readUInt16BE(n),n+=2,r.heartbeat=t,r}function d(e,n){var r=0,i=null,o=0,s=t.alloc(20+o);if(s[0]=1,s.writeUInt16BE(e,1),s.writeUInt32BE(655391,7),r=11,i=n.channelMax,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'channelMax' is the wrong type; must be a number (but not NaN)");if(s.writeUInt16BE(i,r),r+=2,i=n.frameMax,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'frameMax' is the wrong type; must be a number (but not NaN)");if(s.writeUInt32BE(i,r),r+=4,i=n.heartbeat,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'heartbeat' is the wrong type; must be a number (but not NaN)");return s.writeUInt16BE(i,r),r+=2,s[r]=206,s.writeUInt32BE(r-7,3),s}function v(e){var t,n,r=0,i={virtualHost:void 0,capabilities:void 0,insist:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.virtualHost=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.capabilities=t,t=!!(1&e[r]),i.insist=t,i}function g(e,n){var r=0,i=null,o=0,s=0;if(i=n.virtualHost,void 0===i)i="/";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'virtualHost' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");if(s+=a,i=n.capabilities,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'capabilities' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(i,"utf8");s+=u;var c=t.alloc(15+s);return c[0]=1,c.writeUInt16BE(e,1),c.writeUInt32BE(655400,7),r=11,i=n.virtualHost,void 0===i&&(i="/"),c[r]=a,r++,c.write(i,r,"utf8"),r+=a,i=n.capabilities,void 0===i&&(i=""),c[r]=u,r++,c.write(i,r,"utf8"),r+=u,i=n.insist,void 0===i&&(i=!1),i&&(o+=1),c[r]=o,r++,c[r]=206,c.writeUInt32BE(r-7,3),c}function y(e){var t,n,r=0,i={knownHosts:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.knownHosts=t,i}function m(e,n){var r=0,i=null,o=0;if(i=n.knownHosts,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'knownHosts' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=t.alloc(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(655401,7),r=11,i=n.knownHosts,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function b(e){var t,n,r=0,i={replyCode:void 0,replyText:void 0,classId:void 0,methodId:void 0};return t=e.readUInt16BE(r),r+=2,i.replyCode=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.replyText=t,t=e.readUInt16BE(r),r+=2,i.classId=t,t=e.readUInt16BE(r),r+=2,i.methodId=t,i}function _(e,n){var r=0,i=null,o=0;if(i=n.replyText,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'replyText' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=t.alloc(19+o);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(655410,7),r=11,i=n.replyCode,void 0===i)throw new Error("Missing value for mandatory field 'replyCode'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'replyCode' is the wrong type; must be a number (but not NaN)");if(a.writeUInt16BE(i,r),r+=2,i=n.replyText,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,i=n.classId,void 0===i)throw new Error("Missing value for mandatory field 'classId'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'classId' is the wrong type; must be a number (but not NaN)");if(a.writeUInt16BE(i,r),r+=2,i=n.methodId,void 0===i)throw new Error("Missing value for mandatory field 'methodId'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'methodId' is the wrong type; must be a number (but not NaN)");return a.writeUInt16BE(i,r),r+=2,a[r]=206,a.writeUInt32BE(r-7,3),a}function w(e){var t={};return t}function E(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(655411,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function x(e){var t,n,r=0,i={reason:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.reason=t,i}function k(e,n){var r=0,i=null,o=0;if(i=n.reason,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'reason' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=t.alloc(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(655420,7),r=11,i=n.reason,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function I(e){var t={};return t}function C(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(655421,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function S(e){var t,n,r=0,i={outOfBand:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.outOfBand=t,i}function T(e,n){var r=0,i=null,o=0;if(i=n.outOfBand,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'outOfBand' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=t.alloc(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(1310730,7),r=11,i=n.outOfBand,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function B(e){var t,n,r=0,i={channelId:void 0};return n=e.readUInt32BE(r),r+=4,t=e.slice(r,r+n),r+=n,i.channelId=t,i}function U(e,n){var r,i=0,o=null,s=0;if(o=n.channelId,void 0===o)o=t.from("");else if(!t.isBuffer(o))throw new TypeError("Field 'channelId' is the wrong type; must be a Buffer");s+=o.length;var a=t.alloc(16+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(1310731,7),i=11,o=n.channelId,void 0===o&&(o=t.from("")),r=o.length,a.writeUInt32BE(r,i),i+=4,o.copy(a,i),i+=r,a[i]=206,a.writeUInt32BE(i-7,3),a}function O(e){var t,n=0,r={active:void 0};return t=!!(1&e[n]),r.active=t,r}function j(e,n){var r=0,i=null,o=0,s=0,a=t.alloc(13+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(1310740,7),r=11,i=n.active,void 0===i)throw new Error("Missing value for mandatory field 'active'");return i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function A(e){var t,n=0,r={active:void 0};return t=!!(1&e[n]),r.active=t,r}function R(e,n){var r=0,i=null,o=0,s=0,a=t.alloc(13+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(1310741,7),r=11,i=n.active,void 0===i)throw new Error("Missing value for mandatory field 'active'");return i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function F(e){var t,n,r=0,i={replyCode:void 0,replyText:void 0,classId:void 0,methodId:void 0};return t=e.readUInt16BE(r),r+=2,i.replyCode=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.replyText=t,t=e.readUInt16BE(r),r+=2,i.classId=t,t=e.readUInt16BE(r),r+=2,i.methodId=t,i}function P(e,n){var r=0,i=null,o=0;if(i=n.replyText,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'replyText' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=t.alloc(19+o);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(1310760,7),r=11,i=n.replyCode,void 0===i)throw new Error("Missing value for mandatory field 'replyCode'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'replyCode' is the wrong type; must be a number (but not NaN)");if(a.writeUInt16BE(i,r),r+=2,i=n.replyText,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,i=n.classId,void 0===i)throw new Error("Missing value for mandatory field 'classId'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'classId' is the wrong type; must be a number (but not NaN)");if(a.writeUInt16BE(i,r),r+=2,i=n.methodId,void 0===i)throw new Error("Missing value for mandatory field 'methodId'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'methodId' is the wrong type; must be a number (but not NaN)");return a.writeUInt16BE(i,r),r+=2,a[r]=206,a.writeUInt32BE(r-7,3),a}function L(e){var t={};return t}function M(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(1310761,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function N(e){var t,n,r=0,i={realm:void 0,exclusive:void 0,passive:void 0,active:void 0,write:void 0,read:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.realm=t,t=!!(1&e[r]),i.exclusive=t,t=!!(2&e[r]),i.passive=t,t=!!(4&e[r]),i.active=t,t=!!(8&e[r]),i.write=t,t=!!(16&e[r]),i.read=t,i}function D(e,n){var r=0,i=null,o=0,s=0;if(i=n.realm,void 0===i)i="/data";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'realm' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=t.alloc(14+s);return u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(1966090,7),r=11,i=n.realm,void 0===i&&(i="/data"),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.exclusive,void 0===i&&(i=!1),i&&(o+=1),i=n.passive,void 0===i&&(i=!0),i&&(o+=2),i=n.active,void 0===i&&(i=!0),i&&(o+=4),i=n.write,void 0===i&&(i=!0),i&&(o+=8),i=n.read,void 0===i&&(i=!0),i&&(o+=16),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function q(e){var t,n=0,r={ticket:void 0};return t=e.readUInt16BE(n),n+=2,r.ticket=t,r}function z(e,n){var r=0,i=null,o=0,s=t.alloc(14+o);if(s[0]=1,s.writeUInt16BE(e,1),s.writeUInt32BE(1966091,7),r=11,i=n.ticket,void 0===i)i=1;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return s.writeUInt16BE(i,r),r+=2,s[r]=206,s.writeUInt32BE(r-7,3),s}function H(e){var t,n,r=0,i={ticket:void 0,exchange:void 0,type:void 0,passive:void 0,durable:void 0,autoDelete:void 0,internal:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.type=t,t=!!(1&e[r]),i.passive=t,t=!!(2&e[r]),i.durable=t,t=!!(4&e[r]),i.autoDelete=t,t=!!(8&e[r]),i.internal=t,t=!!(16&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function Q(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.exchange,void 0===o)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.type,void 0===o)o="direct";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'type' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(a+=l,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=St(Bt,o,u);var f=Bt.slice(u,u+r);u+=r,a+=f.length;var h=t.alloc(17+a);if(h[0]=1,h.writeUInt16BE(e,1),h.writeUInt32BE(2621450,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return h.writeUInt16BE(o,i),i+=2,o=n.exchange,void 0===o&&(o=void 0),h[i]=c,i++,h.write(o,i,"utf8"),i+=c,o=n.type,void 0===o&&(o="direct"),h[i]=l,i++,h.write(o,i,"utf8"),i+=l,o=n.passive,void 0===o&&(o=!1),o&&(s+=1),o=n.durable,void 0===o&&(o=!1),o&&(s+=2),o=n.autoDelete,void 0===o&&(o=!1),o&&(s+=4),o=n.internal,void 0===o&&(o=!1),o&&(s+=8),o=n.nowait,void 0===o&&(o=!1),o&&(s+=16),h[i]=s,i++,s=0,i+=f.copy(h,i),h[i]=206,h.writeUInt32BE(i-7,3),h}function W(e){var t={};return t}function K(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(2621451,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function V(e){var t,n,r=0,i={ticket:void 0,exchange:void 0,ifUnused:void 0,nowait:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,t=!!(1&e[r]),i.ifUnused=t,t=!!(2&e[r]),i.nowait=t,i}function G(e,n){var r=0,i=null,o=0,s=0;if(i=n.exchange,void 0===i)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=t.alloc(16+s);if(u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(2621460,7),r=11,i=n.ticket,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return u.writeUInt16BE(i,r),r+=2,i=n.exchange,void 0===i&&(i=void 0),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.ifUnused,void 0===i&&(i=!1),i&&(o+=1),i=n.nowait,void 0===i&&(i=!1),i&&(o+=2),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function Y(e){var t={};return t}function $(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(2621461,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function X(e){var t,n,r=0,i={ticket:void 0,destination:void 0,source:void 0,routingKey:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.destination=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.source=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,t=!!(1&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function J(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.destination,void 0===o)throw new Error("Missing value for mandatory field 'destination'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'destination' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.source,void 0===o)throw new Error("Missing value for mandatory field 'source'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'source' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(a+=l,o=n.routingKey,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var f=t.byteLength(o,"utf8");if(a+=f,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=St(Bt,o,u);var h=Bt.slice(u,u+r);u+=r,a+=h.length;var p=t.alloc(18+a);if(p[0]=1,p.writeUInt16BE(e,1),p.writeUInt32BE(2621470,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return p.writeUInt16BE(o,i),i+=2,o=n.destination,void 0===o&&(o=void 0),p[i]=c,i++,p.write(o,i,"utf8"),i+=c,o=n.source,void 0===o&&(o=void 0),p[i]=l,i++,p.write(o,i,"utf8"),i+=l,o=n.routingKey,void 0===o&&(o=""),p[i]=f,i++,p.write(o,i,"utf8"),i+=f,o=n.nowait,void 0===o&&(o=!1),o&&(s+=1),p[i]=s,i++,s=0,i+=h.copy(p,i),p[i]=206,p.writeUInt32BE(i-7,3),p}function Z(e){var t={};return t}function ee(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(2621471,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function te(e){var t,n,r=0,i={ticket:void 0,destination:void 0,source:void 0,routingKey:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.destination=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.source=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,t=!!(1&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function ne(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.destination,void 0===o)throw new Error("Missing value for mandatory field 'destination'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'destination' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.source,void 0===o)throw new Error("Missing value for mandatory field 'source'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'source' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(a+=l,o=n.routingKey,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var f=t.byteLength(o,"utf8");if(a+=f,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=St(Bt,o,u);var h=Bt.slice(u,u+r);u+=r,a+=h.length;var p=t.alloc(18+a);if(p[0]=1,p.writeUInt16BE(e,1),p.writeUInt32BE(2621480,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return p.writeUInt16BE(o,i),i+=2,o=n.destination,void 0===o&&(o=void 0),p[i]=c,i++,p.write(o,i,"utf8"),i+=c,o=n.source,void 0===o&&(o=void 0),p[i]=l,i++,p.write(o,i,"utf8"),i+=l,o=n.routingKey,void 0===o&&(o=""),p[i]=f,i++,p.write(o,i,"utf8"),i+=f,o=n.nowait,void 0===o&&(o=!1),o&&(s+=1),p[i]=s,i++,s=0,i+=h.copy(p,i),p[i]=206,p.writeUInt32BE(i-7,3),p}function re(e){var t={};return t}function ie(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(2621491,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function oe(e){var t,n,r=0,i={ticket:void 0,queue:void 0,passive:void 0,durable:void 0,exclusive:void 0,autoDelete:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,t=!!(1&e[r]),i.passive=t,t=!!(2&e[r]),i.durable=t,t=!!(4&e[r]),i.exclusive=t,t=!!(8&e[r]),i.autoDelete=t,t=!!(16&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function se(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.queue,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=St(Bt,o,u);var l=Bt.slice(u,u+r);u+=r,a+=l.length;var f=t.alloc(16+a);if(f[0]=1,f.writeUInt16BE(e,1),f.writeUInt32BE(3276810,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return f.writeUInt16BE(o,i),i+=2,o=n.queue,void 0===o&&(o=""),f[i]=c,i++,f.write(o,i,"utf8"),i+=c,o=n.passive,void 0===o&&(o=!1),o&&(s+=1),o=n.durable,void 0===o&&(o=!1),o&&(s+=2),o=n.exclusive,void 0===o&&(o=!1),o&&(s+=4),o=n.autoDelete,void 0===o&&(o=!1),o&&(s+=8),o=n.nowait,void 0===o&&(o=!1),o&&(s+=16),f[i]=s,i++,s=0,i+=l.copy(f,i),f[i]=206,f.writeUInt32BE(i-7,3),f}function ae(e){var t,n,r=0,i={queue:void 0,messageCount:void 0,consumerCount:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,t=e.readUInt32BE(r),r+=4,i.messageCount=t,t=e.readUInt32BE(r),r+=4,i.consumerCount=t,i}function ue(e,n){var r=0,i=null,o=0;if(i=n.queue,void 0===i)throw new Error("Missing value for mandatory field 'queue'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=t.alloc(21+o);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3276811,7),r=11,i=n.queue,void 0===i&&(i=void 0),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,i=n.messageCount,void 0===i)throw new Error("Missing value for mandatory field 'messageCount'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'messageCount' is the wrong type; must be a number (but not NaN)");if(a.writeUInt32BE(i,r),r+=4,i=n.consumerCount,void 0===i)throw new Error("Missing value for mandatory field 'consumerCount'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'consumerCount' is the wrong type; must be a number (but not NaN)");return a.writeUInt32BE(i,r),r+=4,a[r]=206,a.writeUInt32BE(r-7,3),a}function ce(e){var t,n,r=0,i={ticket:void 0,queue:void 0,exchange:void 0,routingKey:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,t=!!(1&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function le(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.queue,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.exchange,void 0===o)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(a+=l,o=n.routingKey,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var f=t.byteLength(o,"utf8");if(a+=f,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=St(Bt,o,u);var h=Bt.slice(u,u+r);u+=r,a+=h.length;var p=t.alloc(18+a);if(p[0]=1,p.writeUInt16BE(e,1),p.writeUInt32BE(3276820,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return p.writeUInt16BE(o,i),i+=2,o=n.queue,void 0===o&&(o=""),p[i]=c,i++,p.write(o,i,"utf8"),i+=c,o=n.exchange,void 0===o&&(o=void 0),p[i]=l,i++,p.write(o,i,"utf8"),i+=l,o=n.routingKey,void 0===o&&(o=""),p[i]=f,i++,p.write(o,i,"utf8"),i+=f,o=n.nowait,void 0===o&&(o=!1),o&&(s+=1),p[i]=s,i++,s=0,i+=h.copy(p,i),p[i]=206,p.writeUInt32BE(i-7,3),p}function fe(e){var t={};return t}function he(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(3276821,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function pe(e){var t,n,r=0,i={ticket:void 0,queue:void 0,nowait:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,t=!!(1&e[r]),i.nowait=t,i}function de(e,n){var r=0,i=null,o=0,s=0;if(i=n.queue,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=t.alloc(16+s);if(u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(3276830,7),r=11,i=n.ticket,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return u.writeUInt16BE(i,r),r+=2,i=n.queue,void 0===i&&(i=""),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.nowait,void 0===i&&(i=!1),i&&(o+=1),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function ve(e){var t,n=0,r={messageCount:void 0};return t=e.readUInt32BE(n),n+=4,r.messageCount=t,r}function ge(e,n){var r=0,i=null,o=0,s=t.alloc(16+o);if(s[0]=1,s.writeUInt16BE(e,1),s.writeUInt32BE(3276831,7),r=11,i=n.messageCount,void 0===i)throw new Error("Missing value for mandatory field 'messageCount'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'messageCount' is the wrong type; must be a number (but not NaN)");return s.writeUInt32BE(i,r),r+=4,s[r]=206,s.writeUInt32BE(r-7,3),s}function ye(e){var t,n,r=0,i={ticket:void 0,queue:void 0,ifUnused:void 0,ifEmpty:void 0,nowait:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,t=!!(1&e[r]),i.ifUnused=t,t=!!(2&e[r]),i.ifEmpty=t,t=!!(4&e[r]),i.nowait=t,i}function me(e,n){var r=0,i=null,o=0,s=0;if(i=n.queue,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=t.alloc(16+s);if(u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(3276840,7),r=11,i=n.ticket,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return u.writeUInt16BE(i,r),r+=2,i=n.queue,void 0===i&&(i=""),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.ifUnused,void 0===i&&(i=!1),i&&(o+=1),i=n.ifEmpty,void 0===i&&(i=!1),i&&(o+=2),i=n.nowait,void 0===i&&(i=!1),i&&(o+=4),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function be(e){var t,n=0,r={messageCount:void 0};return t=e.readUInt32BE(n),n+=4,r.messageCount=t,r}function _e(e,n){var r=0,i=null,o=0,s=t.alloc(16+o);if(s[0]=1,s.writeUInt16BE(e,1),s.writeUInt32BE(3276841,7),r=11,i=n.messageCount,void 0===i)throw new Error("Missing value for mandatory field 'messageCount'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'messageCount' is the wrong type; must be a number (but not NaN)");return s.writeUInt32BE(i,r),r+=4,s[r]=206,s.writeUInt32BE(r-7,3),s}function we(e){var t,n,r=0,i={ticket:void 0,queue:void 0,exchange:void 0,routingKey:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function Ee(e,n){var r,i=0,o=null,s=0,a=0;if(o=n.queue,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(o,"utf8");if(s+=u,o=n.exchange,void 0===o)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(s+=c,o=n.routingKey,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(s+=l,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=St(Bt,o,a);var f=Bt.slice(a,a+r);a+=r,s+=f.length;var h=t.alloc(17+s);if(h[0]=1,h.writeUInt16BE(e,1),h.writeUInt32BE(3276850,7), +i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return h.writeUInt16BE(o,i),i+=2,o=n.queue,void 0===o&&(o=""),h[i]=u,i++,h.write(o,i,"utf8"),i+=u,o=n.exchange,void 0===o&&(o=void 0),h[i]=c,i++,h.write(o,i,"utf8"),i+=c,o=n.routingKey,void 0===o&&(o=""),h[i]=l,i++,h.write(o,i,"utf8"),i+=l,i+=f.copy(h,i),h[i]=206,h.writeUInt32BE(i-7,3),h}function xe(e){var t={};return t}function ke(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(3276851,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function Ie(e){var t,n=0,r={prefetchSize:void 0,prefetchCount:void 0,global:void 0};return t=e.readUInt32BE(n),n+=4,r.prefetchSize=t,t=e.readUInt16BE(n),n+=2,r.prefetchCount=t,t=!!(1&e[n]),r.global=t,r}function Ce(e,n){var r=0,i=null,o=0,s=0,a=t.alloc(19+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932170,7),r=11,i=n.prefetchSize,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'prefetchSize' is the wrong type; must be a number (but not NaN)");if(a.writeUInt32BE(i,r),r+=4,i=n.prefetchCount,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'prefetchCount' is the wrong type; must be a number (but not NaN)");return a.writeUInt16BE(i,r),r+=2,i=n.global,void 0===i&&(i=!1),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function Se(e){var t={};return t}function Te(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(3932171,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function Be(e){var t,n,r=0,i={ticket:void 0,queue:void 0,consumerTag:void 0,noLocal:void 0,noAck:void 0,exclusive:void 0,nowait:void 0,arguments:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.consumerTag=t,t=!!(1&e[r]),i.noLocal=t,t=!!(2&e[r]),i.noAck=t,t=!!(4&e[r]),i.exclusive=t,t=!!(8&e[r]),i.nowait=t,r++,n=e.readUInt32BE(r),r+=4,t=Tt(e.slice(r,r+n)),r+=n,i.arguments=t,i}function Ue(e,n){var r,i=0,o=null,s=0,a=0,u=0;if(o=n.queue,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(o,"utf8");if(a+=c,o=n.consumerTag,void 0===o)o="";else if(!("string"==typeof o&&t.byteLength(o)<256))throw new TypeError("Field 'consumerTag' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(o,"utf8");if(a+=l,o=n.arguments,void 0===o)o={};else if("object"!=typeof o)throw new TypeError("Field 'arguments' is the wrong type; must be an object");r=St(Bt,o,u);var f=Bt.slice(u,u+r);u+=r,a+=f.length;var h=t.alloc(17+a);if(h[0]=1,h.writeUInt16BE(e,1),h.writeUInt32BE(3932180,7),i=11,o=n.ticket,void 0===o)o=0;else if("number"!=typeof o||isNaN(o))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return h.writeUInt16BE(o,i),i+=2,o=n.queue,void 0===o&&(o=""),h[i]=c,i++,h.write(o,i,"utf8"),i+=c,o=n.consumerTag,void 0===o&&(o=""),h[i]=l,i++,h.write(o,i,"utf8"),i+=l,o=n.noLocal,void 0===o&&(o=!1),o&&(s+=1),o=n.noAck,void 0===o&&(o=!1),o&&(s+=2),o=n.exclusive,void 0===o&&(o=!1),o&&(s+=4),o=n.nowait,void 0===o&&(o=!1),o&&(s+=8),h[i]=s,i++,s=0,i+=f.copy(h,i),h[i]=206,h.writeUInt32BE(i-7,3),h}function Oe(e){var t,n,r=0,i={consumerTag:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.consumerTag=t,i}function je(e,n){var r=0,i=null,o=0;if(i=n.consumerTag,void 0===i)throw new Error("Missing value for mandatory field 'consumerTag'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'consumerTag' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=t.alloc(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932181,7),r=11,i=n.consumerTag,void 0===i&&(i=void 0),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function Ae(e){var t,n,r=0,i={consumerTag:void 0,nowait:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.consumerTag=t,t=!!(1&e[r]),i.nowait=t,i}function Re(e,n){var r=0,i=null,o=0,s=0;if(i=n.consumerTag,void 0===i)throw new Error("Missing value for mandatory field 'consumerTag'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'consumerTag' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=t.alloc(14+s);return u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(3932190,7),r=11,i=n.consumerTag,void 0===i&&(i=void 0),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.nowait,void 0===i&&(i=!1),i&&(o+=1),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function Fe(e){var t,n,r=0,i={consumerTag:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.consumerTag=t,i}function Pe(e,n){var r=0,i=null,o=0;if(i=n.consumerTag,void 0===i)throw new Error("Missing value for mandatory field 'consumerTag'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'consumerTag' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=t.alloc(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932191,7),r=11,i=n.consumerTag,void 0===i&&(i=void 0),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function Le(e){var t,n,r=0,i={ticket:void 0,exchange:void 0,routingKey:void 0,mandatory:void 0,immediate:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,t=!!(1&e[r]),i.mandatory=t,t=!!(2&e[r]),i.immediate=t,i}function Me(e,n){var r=0,i=null,o=0,s=0;if(i=n.exchange,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");if(s+=a,i=n.routingKey,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(i,"utf8");s+=u;var c=t.alloc(17+s);if(c[0]=1,c.writeUInt16BE(e,1),c.writeUInt32BE(3932200,7),r=11,i=n.ticket,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return c.writeUInt16BE(i,r),r+=2,i=n.exchange,void 0===i&&(i=""),c[r]=a,r++,c.write(i,r,"utf8"),r+=a,i=n.routingKey,void 0===i&&(i=""),c[r]=u,r++,c.write(i,r,"utf8"),r+=u,i=n.mandatory,void 0===i&&(i=!1),i&&(o+=1),i=n.immediate,void 0===i&&(i=!1),i&&(o+=2),c[r]=o,r++,c[r]=206,c.writeUInt32BE(r-7,3),c}function Ne(e){var t,n,r=0,i={replyCode:void 0,replyText:void 0,exchange:void 0,routingKey:void 0};return t=e.readUInt16BE(r),r+=2,i.replyCode=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.replyText=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,i}function De(e,n){var r=0,i=null,o=0;if(i=n.replyText,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'replyText' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");if(o+=s,i=n.exchange,void 0===i)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");if(o+=a,i=n.routingKey,void 0===i)throw new Error("Missing value for mandatory field 'routingKey'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(i,"utf8");o+=u;var c=t.alloc(17+o);if(c[0]=1,c.writeUInt16BE(e,1),c.writeUInt32BE(3932210,7),r=11,i=n.replyCode,void 0===i)throw new Error("Missing value for mandatory field 'replyCode'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'replyCode' is the wrong type; must be a number (but not NaN)");return c.writeUInt16BE(i,r),r+=2,i=n.replyText,void 0===i&&(i=""),c[r]=s,r++,c.write(i,r,"utf8"),r+=s,i=n.exchange,void 0===i&&(i=void 0),c[r]=a,r++,c.write(i,r,"utf8"),r+=a,i=n.routingKey,void 0===i&&(i=void 0),c[r]=u,r++,c.write(i,r,"utf8"),r+=u,c[r]=206,c.writeUInt32BE(r-7,3),c}function qe(e){var t,n,r=0,i={consumerTag:void 0,deliveryTag:void 0,redelivered:void 0,exchange:void 0,routingKey:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.consumerTag=t,t=Ct.readUInt64BE(e,r),r+=8,i.deliveryTag=t,t=!!(1&e[r]),i.redelivered=t,r++,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,i}function ze(e,n){var r=0,i=null,o=0,s=0;if(i=n.consumerTag,void 0===i)throw new Error("Missing value for mandatory field 'consumerTag'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'consumerTag' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");if(s+=a,i=n.exchange,void 0===i)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(i,"utf8");if(s+=u,i=n.routingKey,void 0===i)throw new Error("Missing value for mandatory field 'routingKey'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var c=t.byteLength(i,"utf8");s+=c;var l=t.alloc(24+s);if(l[0]=1,l.writeUInt16BE(e,1),l.writeUInt32BE(3932220,7),r=11,i=n.consumerTag,void 0===i&&(i=void 0),l[r]=a,r++,l.write(i,r,"utf8"),r+=a,i=n.deliveryTag,void 0===i)throw new Error("Missing value for mandatory field 'deliveryTag'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryTag' is the wrong type; must be a number (but not NaN)");return Ct.writeUInt64BE(l,i,r),r+=8,i=n.redelivered,void 0===i&&(i=!1),i&&(o+=1),l[r]=o,r++,o=0,i=n.exchange,void 0===i&&(i=void 0),l[r]=u,r++,l.write(i,r,"utf8"),r+=u,i=n.routingKey,void 0===i&&(i=void 0),l[r]=c,r++,l.write(i,r,"utf8"),r+=c,l[r]=206,l.writeUInt32BE(r-7,3),l}function He(e){var t,n,r=0,i={ticket:void 0,queue:void 0,noAck:void 0};return t=e.readUInt16BE(r),r+=2,i.ticket=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.queue=t,t=!!(1&e[r]),i.noAck=t,i}function Qe(e,n){var r=0,i=null,o=0,s=0;if(i=n.queue,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'queue' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");s+=a;var u=t.alloc(16+s);if(u[0]=1,u.writeUInt16BE(e,1),u.writeUInt32BE(3932230,7),r=11,i=n.ticket,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'ticket' is the wrong type; must be a number (but not NaN)");return u.writeUInt16BE(i,r),r+=2,i=n.queue,void 0===i&&(i=""),u[r]=a,r++,u.write(i,r,"utf8"),r+=a,i=n.noAck,void 0===i&&(i=!1),i&&(o+=1),u[r]=o,r++,u[r]=206,u.writeUInt32BE(r-7,3),u}function We(e){var t,n,r=0,i={deliveryTag:void 0,redelivered:void 0,exchange:void 0,routingKey:void 0,messageCount:void 0};return t=Ct.readUInt64BE(e,r),r+=8,i.deliveryTag=t,t=!!(1&e[r]),i.redelivered=t,r++,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.exchange=t,n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.routingKey=t,t=e.readUInt32BE(r),r+=4,i.messageCount=t,i}function Ke(e,n){var r=0,i=null,o=0,s=0;if(i=n.exchange,void 0===i)throw new Error("Missing value for mandatory field 'exchange'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'exchange' is the wrong type; must be a string (up to 255 chars)");var a=t.byteLength(i,"utf8");if(s+=a,i=n.routingKey,void 0===i)throw new Error("Missing value for mandatory field 'routingKey'");if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'routingKey' is the wrong type; must be a string (up to 255 chars)");var u=t.byteLength(i,"utf8");s+=u;var c=t.alloc(27+s);if(c[0]=1,c.writeUInt16BE(e,1),c.writeUInt32BE(3932231,7),r=11,i=n.deliveryTag,void 0===i)throw new Error("Missing value for mandatory field 'deliveryTag'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryTag' is the wrong type; must be a number (but not NaN)");if(Ct.writeUInt64BE(c,i,r),r+=8,i=n.redelivered,void 0===i&&(i=!1),i&&(o+=1),c[r]=o,r++,o=0,i=n.exchange,void 0===i&&(i=void 0),c[r]=a,r++,c.write(i,r,"utf8"),r+=a,i=n.routingKey,void 0===i&&(i=void 0),c[r]=u,r++,c.write(i,r,"utf8"),r+=u,i=n.messageCount,void 0===i)throw new Error("Missing value for mandatory field 'messageCount'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'messageCount' is the wrong type; must be a number (but not NaN)");return c.writeUInt32BE(i,r),r+=4,c[r]=206,c.writeUInt32BE(r-7,3),c}function Ve(e){var t,n,r=0,i={clusterId:void 0};return n=e.readUInt8(r),r++,t=e.toString("utf8",r,r+n),r+=n,i.clusterId=t,i}function Ge(e,n){var r=0,i=null,o=0;if(i=n.clusterId,void 0===i)i="";else if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'clusterId' is the wrong type; must be a string (up to 255 chars)");var s=t.byteLength(i,"utf8");o+=s;var a=t.alloc(13+o);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932232,7),r=11,i=n.clusterId,void 0===i&&(i=""),a[r]=s,r++,a.write(i,r,"utf8"),r+=s,a[r]=206,a.writeUInt32BE(r-7,3),a}function Ye(e){var t,n=0,r={deliveryTag:void 0,multiple:void 0};return t=Ct.readUInt64BE(e,n),n+=8,r.deliveryTag=t,t=!!(1&e[n]),r.multiple=t,r}function $e(e,n){var r=0,i=null,o=0,s=0,a=t.alloc(21+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932240,7),r=11,i=n.deliveryTag,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryTag' is the wrong type; must be a number (but not NaN)");return Ct.writeUInt64BE(a,i,r),r+=8,i=n.multiple,void 0===i&&(i=!1),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function Xe(e){var t,n=0,r={deliveryTag:void 0,requeue:void 0};return t=Ct.readUInt64BE(e,n),n+=8,r.deliveryTag=t,t=!!(1&e[n]),r.requeue=t,r}function Je(e,n){var r=0,i=null,o=0,s=0,a=t.alloc(21+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932250,7),r=11,i=n.deliveryTag,void 0===i)throw new Error("Missing value for mandatory field 'deliveryTag'");if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryTag' is the wrong type; must be a number (but not NaN)");return Ct.writeUInt64BE(a,i,r),r+=8,i=n.requeue,void 0===i&&(i=!0),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function Ze(e){var t,n=0,r={requeue:void 0};return t=!!(1&e[n]),r.requeue=t,r}function et(e,n){var r=0,i=null,o=0,s=0,a=t.alloc(13+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932260,7),r=11,i=n.requeue,void 0===i&&(i=!1),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function tt(e){var t,n=0,r={requeue:void 0};return t=!!(1&e[n]),r.requeue=t,r}function nt(e,n){var r=0,i=null,o=0,s=0,a=t.alloc(13+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932270,7),r=11,i=n.requeue,void 0===i&&(i=!1),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function rt(e){var t={};return t}function it(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(3932271,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function ot(e){var t,n=0,r={deliveryTag:void 0,multiple:void 0,requeue:void 0};return t=Ct.readUInt64BE(e,n),n+=8,r.deliveryTag=t,t=!!(1&e[n]),r.multiple=t,t=!!(2&e[n]),r.requeue=t,r}function st(e,n){var r=0,i=null,o=0,s=0,a=t.alloc(21+s);if(a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(3932280,7),r=11,i=n.deliveryTag,void 0===i)i=0;else if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryTag' is the wrong type; must be a number (but not NaN)");return Ct.writeUInt64BE(a,i,r),r+=8,i=n.multiple,void 0===i&&(i=!1),i&&(o+=1),i=n.requeue,void 0===i&&(i=!0),i&&(o+=2),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function at(e){var t={};return t}function ut(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898250,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function ct(e){var t={};return t}function lt(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898251,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function ft(e){var t={};return t}function ht(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898260,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function pt(e){var t={};return t}function dt(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898261,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function vt(e){var t={};return t}function gt(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898270,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function yt(e){var t={};return t}function mt(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5898271,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function bt(e){var t,n=0,r={nowait:void 0};return t=!!(1&e[n]),r.nowait=t,r}function _t(e,n){var r=0,i=null,o=0,s=0,a=t.alloc(13+s);return a[0]=1,a.writeUInt16BE(e,1),a.writeUInt32BE(5570570,7),r=11,i=n.nowait,void 0===i&&(i=!1),i&&(o+=1),a[r]=o,r++,a[r]=206,a.writeUInt32BE(r-7,3),a}function wt(e){var t={};return t}function Et(e,n){var r=0,i=0,o=t.alloc(12+i);return o[0]=1,o.writeUInt16BE(e,1),o.writeUInt32BE(5570571,7),r=11,o[r]=206,o.writeUInt32BE(r-7,3),o}function xt(e,n,r){var i,o,s=0,a=0,u=0,c=0;if(i=r.contentType,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'contentType' is the wrong type; must be a string (up to 255 chars)");var l=t.byteLength(i,"utf8");c+=1,c+=l}if(i=r.contentEncoding,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'contentEncoding' is the wrong type; must be a string (up to 255 chars)");var f=t.byteLength(i,"utf8");c+=1,c+=f}if(i=r.headers,void 0!=i){if("object"!=typeof i)throw new TypeError("Field 'headers' is the wrong type; must be an object");o=St(Bt,i,u);var h=Bt.slice(u,u+o);u+=o,c+=h.length}if(i=r.deliveryMode,void 0!=i){if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'deliveryMode' is the wrong type; must be a number (but not NaN)");c+=1}if(i=r.priority,void 0!=i){if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'priority' is the wrong type; must be a number (but not NaN)");c+=1}if(i=r.correlationId,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'correlationId' is the wrong type; must be a string (up to 255 chars)");var p=t.byteLength(i,"utf8");c+=1,c+=p}if(i=r.replyTo,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'replyTo' is the wrong type; must be a string (up to 255 chars)");var d=t.byteLength(i,"utf8");c+=1,c+=d}if(i=r.expiration,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'expiration' is the wrong type; must be a string (up to 255 chars)");var v=t.byteLength(i,"utf8");c+=1,c+=v}if(i=r.messageId,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'messageId' is the wrong type; must be a string (up to 255 chars)");var g=t.byteLength(i,"utf8");c+=1,c+=g}if(i=r.timestamp,void 0!=i){if("number"!=typeof i||isNaN(i))throw new TypeError("Field 'timestamp' is the wrong type; must be a number (but not NaN)");c+=8}if(i=r.type,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'type' is the wrong type; must be a string (up to 255 chars)");var y=t.byteLength(i,"utf8");c+=1,c+=y}if(i=r.userId,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'userId' is the wrong type; must be a string (up to 255 chars)");var m=t.byteLength(i,"utf8");c+=1,c+=m}if(i=r.appId,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'appId' is the wrong type; must be a string (up to 255 chars)");var b=t.byteLength(i,"utf8");c+=1,c+=b}if(i=r.clusterId,void 0!=i){if(!("string"==typeof i&&t.byteLength(i)<256))throw new TypeError("Field 'clusterId' is the wrong type; must be a string (up to 255 chars)");var _=t.byteLength(i,"utf8");c+=1,c+=_}var w=t.alloc(22+c);return w[0]=2,w.writeUInt16BE(e,1),w.writeUInt32BE(3932160,7),Ct.writeUInt64BE(w,n,11),a=0,s=21,i=r.contentType,void 0!=i&&(a+=32768,w[s]=l,s++,w.write(i,s,"utf8"),s+=l),i=r.contentEncoding,void 0!=i&&(a+=16384,w[s]=f,s++,w.write(i,s,"utf8"),s+=f),i=r.headers,void 0!=i&&(a+=8192,s+=h.copy(w,s)),i=r.deliveryMode,void 0!=i&&(a+=4096,w.writeUInt8(i,s),s++),i=r.priority,void 0!=i&&(a+=2048,w.writeUInt8(i,s),s++),i=r.correlationId,void 0!=i&&(a+=1024,w[s]=p,s++,w.write(i,s,"utf8"),s+=p),i=r.replyTo,void 0!=i&&(a+=512,w[s]=d,s++,w.write(i,s,"utf8"),s+=d),i=r.expiration,void 0!=i&&(a+=256,w[s]=v,s++,w.write(i,s,"utf8"),s+=v),i=r.messageId,void 0!=i&&(a+=128,w[s]=g,s++,w.write(i,s,"utf8"),s+=g),i=r.timestamp,void 0!=i&&(a+=64,Ct.writeUInt64BE(w,i,s),s+=8),i=r.type,void 0!=i&&(a+=32,w[s]=y,s++,w.write(i,s,"utf8"),s+=y),i=r.userId,void 0!=i&&(a+=16,w[s]=m,s++,w.write(i,s,"utf8"),s+=m),i=r.appId,void 0!=i&&(a+=8,w[s]=b,s++,w.write(i,s,"utf8"),s+=b),i=r.clusterId,void 0!=i&&(a+=4,w[s]=_,s++,w.write(i,s,"utf8"),s+=_),w[s]=206,w.writeUInt32BE(s-7,3),w.writeUInt16BE(a,19),w.slice(0,s+1)}function kt(e){var t,n,r,i=2;if(t=e.readUInt16BE(0),0===t)return{};var o={contentType:void 0,contentEncoding:void 0,headers:void 0,deliveryMode:void 0,priority:void 0,correlationId:void 0,replyTo:void 0,expiration:void 0,messageId:void 0,timestamp:void 0,type:void 0,userId:void 0,appId:void 0,clusterId:void 0};return 32768&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.contentType=n),16384&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.contentEncoding=n),8192&t&&(r=e.readUInt32BE(i),i+=4,n=Tt(e.slice(i,i+r)),i+=r,o.headers=n),4096&t&&(n=e[i],i++,o.deliveryMode=n),2048&t&&(n=e[i],i++,o.priority=n),1024&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.correlationId=n),512&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.replyTo=n),256&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.expiration=n),128&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.messageId=n),64&t&&(n=Ct.readUInt64BE(e,i),i+=8,o.timestamp=n),32&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.type=n),16&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.userId=n),8&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.appId=n),4&t&&(r=e.readUInt8(i),i++,n=e.toString("utf8",i,i+r),i+=r,o.clusterId=n),o}var t=n(118).Buffer,It=n(119),Ct=n(120),St=It.encodeTable,Tt=It.decodeFields,Bt=t.alloc(16384);Object.freeze({});e.exports.constants={FRAME_METHOD:1,FRAME_HEADER:2,FRAME_BODY:3,FRAME_HEARTBEAT:8,FRAME_MIN_SIZE:4096,FRAME_END:206,REPLY_SUCCESS:200,CONTENT_TOO_LARGE:311,NO_ROUTE:312,NO_CONSUMERS:313,ACCESS_REFUSED:403,NOT_FOUND:404,RESOURCE_LOCKED:405,PRECONDITION_FAILED:406,CONNECTION_FORCED:320,INVALID_PATH:402,FRAME_ERROR:501,SYNTAX_ERROR:502,COMMAND_INVALID:503,CHANNEL_ERROR:504,UNEXPECTED_FRAME:505,RESOURCE_ERROR:506,NOT_ALLOWED:530,NOT_IMPLEMENTED:540,INTERNAL_ERROR:541},e.exports.constant_strs={1:"FRAME-METHOD",2:"FRAME-HEADER",3:"FRAME-BODY",8:"FRAME-HEARTBEAT",200:"REPLY-SUCCESS",206:"FRAME-END",311:"CONTENT-TOO-LARGE",312:"NO-ROUTE",313:"NO-CONSUMERS",320:"CONNECTION-FORCED",402:"INVALID-PATH",403:"ACCESS-REFUSED",404:"NOT-FOUND",405:"RESOURCE-LOCKED",406:"PRECONDITION-FAILED",501:"FRAME-ERROR",502:"SYNTAX-ERROR",503:"COMMAND-INVALID",504:"CHANNEL-ERROR",505:"UNEXPECTED-FRAME",506:"RESOURCE-ERROR",530:"NOT-ALLOWED",540:"NOT-IMPLEMENTED",541:"INTERNAL-ERROR",4096:"FRAME-MIN-SIZE"},e.exports.FRAME_OVERHEAD=8,e.exports.decode=function(e,t){switch(e){case 655370:return r(t);case 655371:return o(t);case 655380:return a(t);case 655381:return c(t);case 655390:return f(t);case 655391:return p(t);case 655400:return v(t);case 655401:return y(t);case 655410:return b(t);case 655411:return w(t);case 655420:return x(t);case 655421:return I(t);case 1310730:return S(t);case 1310731:return B(t);case 1310740:return O(t);case 1310741:return A(t);case 1310760:return F(t);case 1310761:return L(t);case 1966090:return N(t);case 1966091:return q(t);case 2621450:return H(t);case 2621451:return W(t);case 2621460:return V(t);case 2621461:return Y(t);case 2621470:return X(t);case 2621471:return Z(t);case 2621480:return te(t);case 2621491:return re(t);case 3276810:return oe(t);case 3276811:return ae(t);case 3276820:return ce(t);case 3276821:return fe(t);case 3276830:return pe(t);case 3276831:return ve(t);case 3276840:return ye(t);case 3276841:return be(t);case 3276850:return we(t);case 3276851:return xe(t);case 3932170:return Ie(t);case 3932171:return Se(t);case 3932180:return Be(t);case 3932181:return Oe(t);case 3932190:return Ae(t);case 3932191:return Fe(t);case 3932200:return Le(t);case 3932210:return Ne(t);case 3932220:return qe(t);case 3932230:return He(t);case 3932231:return We(t);case 3932232:return Ve(t);case 3932240:return Ye(t);case 3932250:return Xe(t);case 3932260:return Ze(t);case 3932270:return tt(t);case 3932271:return rt(t);case 3932280:return ot(t);case 5898250:return at(t);case 5898251:return ct(t);case 5898260:return ft(t);case 5898261:return pt(t);case 5898270:return vt(t);case 5898271:return yt(t);case 5570570:return bt(t);case 5570571:return wt(t);case 60:return kt(t);default:throw new Error("Unknown class/method ID")}},e.exports.encodeMethod=function(e,t,n){switch(e){case 655370:return i(t,n);case 655371:return s(t,n);case 655380:return u(t,n);case 655381:return l(t,n);case 655390:return h(t,n);case 655391:return d(t,n);case 655400:return g(t,n);case 655401:return m(t,n);case 655410:return _(t,n);case 655411:return E(t,n);case 655420:return k(t,n);case 655421:return C(t,n);case 1310730:return T(t,n);case 1310731:return U(t,n);case 1310740:return j(t,n);case 1310741:return R(t,n);case 1310760:return P(t,n);case 1310761:return M(t,n);case 1966090:return D(t,n);case 1966091:return z(t,n);case 2621450:return Q(t,n);case 2621451:return K(t,n);case 2621460:return G(t,n);case 2621461:return $(t,n);case 2621470:return J(t,n);case 2621471:return ee(t,n);case 2621480:return ne(t,n);case 2621491:return ie(t,n);case 3276810:return se(t,n);case 3276811:return ue(t,n);case 3276820:return le(t,n);case 3276821:return he(t,n);case 3276830:return de(t,n);case 3276831:return ge(t,n);case 3276840:return me(t,n);case 3276841:return _e(t,n);case 3276850:return Ee(t,n);case 3276851:return ke(t,n);case 3932170:return Ce(t,n);case 3932171:return Te(t,n);case 3932180:return Ue(t,n);case 3932181:return je(t,n);case 3932190:return Re(t,n);case 3932191:return Pe(t,n);case 3932200:return Me(t,n);case 3932210:return De(t,n);case 3932220:return ze(t,n);case 3932230:return Qe(t,n);case 3932231:return Ke(t,n);case 3932232:return Ge(t,n);case 3932240:return $e(t,n);case 3932250:return Je(t,n);case 3932260:return et(t,n);case 3932270:return nt(t,n);case 3932271:return it(t,n);case 3932280:return st(t,n);case 5898250:return ut(t,n);case 5898251:return lt(t,n);case 5898260:return ht(t,n);case 5898261:return dt(t,n);case 5898270:return gt(t,n);case 5898271:return mt(t,n);case 5570570:return _t(t,n);case 5570571:return Et(t,n);default:throw new Error("Unknown class/method ID")}},e.exports.encodeProperties=function(e,t,n,r){switch(e){case 60:return xt(t,n,r);default:throw new Error("Unknown class/properties ID")}},e.exports.info=function(e){switch(e){case 655370:return Ut;case 655371:return Ot;case 655380:return jt;case 655381:return At;case 655390:return Rt;case 655391:return Ft;case 655400:return Pt;case 655401:return Lt;case 655410:return Mt;case 655411:return Nt;case 655420:return Dt;case 655421:return qt;case 1310730:return zt;case 1310731:return Ht;case 1310740:return Qt;case 1310741:return Wt;case 1310760:return Kt;case 1310761:return Vt;case 1966090:return Gt;case 1966091:return Yt;case 2621450:return $t;case 2621451:return Xt;case 2621460:return Jt;case 2621461:return Zt;case 2621470:return en;case 2621471:return tn;case 2621480:return nn;case 2621491:return rn;case 3276810:return on;case 3276811:return sn;case 3276820:return an;case 3276821:return un;case 3276830:return cn;case 3276831:return ln;case 3276840:return fn;case 3276841:return hn;case 3276850:return pn;case 3276851:return dn;case 3932170:return vn;case 3932171:return gn;case 3932180:return yn;case 3932181:return mn;case 3932190:return bn;case 3932191:return _n;case 3932200:return wn;case 3932210:return En;case 3932220:return xn;case 3932230:return kn;case 3932231:return In;case 3932232:return Cn;case 3932240:return Sn;case 3932250:return Tn;case 3932260:return Bn;case 3932270:return Un;case 3932271:return On;case 3932280:return jn;case 5898250:return An;case 5898251:return Rn;case 5898260:return Fn;case 5898261:return Pn;case 5898270:return Ln;case 5898271:return Mn;case 5570570:return Nn;case 5570571:return Dn;case 60:return qn;default:throw new Error("Unknown class/method ID")}},e.exports.ConnectionStart=655370;var Ut=e.exports.methodInfoConnectionStart={id:655370,name:"ConnectionStart",args:[{type:"octet",name:"versionMajor","default":0},{type:"octet",name:"versionMinor","default":9},{type:"table",name:"serverProperties"},{type:"longstr",name:"mechanisms","default":"PLAIN"},{type:"longstr",name:"locales","default":"en_US"}]};e.exports.ConnectionStartOk=655371;var Ot=e.exports.methodInfoConnectionStartOk={id:655371,name:"ConnectionStartOk",args:[{type:"table",name:"clientProperties"},{type:"shortstr",name:"mechanism","default":"PLAIN"},{type:"longstr",name:"response"},{type:"shortstr",name:"locale","default":"en_US"}]};e.exports.ConnectionSecure=655380;var jt=e.exports.methodInfoConnectionSecure={id:655380,name:"ConnectionSecure",args:[{type:"longstr",name:"challenge"}]};e.exports.ConnectionSecureOk=655381;var At=e.exports.methodInfoConnectionSecureOk={id:655381,name:"ConnectionSecureOk",args:[{type:"longstr",name:"response"}]};e.exports.ConnectionTune=655390;var Rt=e.exports.methodInfoConnectionTune={id:655390,name:"ConnectionTune",args:[{type:"short",name:"channelMax","default":0},{type:"long",name:"frameMax","default":0},{type:"short",name:"heartbeat","default":0}]};e.exports.ConnectionTuneOk=655391;var Ft=e.exports.methodInfoConnectionTuneOk={id:655391,name:"ConnectionTuneOk",args:[{type:"short",name:"channelMax","default":0},{type:"long",name:"frameMax","default":0},{type:"short",name:"heartbeat","default":0}]};e.exports.ConnectionOpen=655400;var Pt=e.exports.methodInfoConnectionOpen={id:655400,name:"ConnectionOpen",args:[{type:"shortstr",name:"virtualHost","default":"/"},{type:"shortstr",name:"capabilities","default":""},{type:"bit",name:"insist","default":!1}]};e.exports.ConnectionOpenOk=655401;var Lt=e.exports.methodInfoConnectionOpenOk={id:655401,name:"ConnectionOpenOk",args:[{type:"shortstr",name:"knownHosts","default":""}]};e.exports.ConnectionClose=655410;var Mt=e.exports.methodInfoConnectionClose={id:655410,name:"ConnectionClose",args:[{type:"short",name:"replyCode"},{type:"shortstr",name:"replyText","default":""},{type:"short",name:"classId"},{type:"short",name:"methodId"}]};e.exports.ConnectionCloseOk=655411;var Nt=e.exports.methodInfoConnectionCloseOk={id:655411,name:"ConnectionCloseOk",args:[]};e.exports.ConnectionBlocked=655420;var Dt=e.exports.methodInfoConnectionBlocked={id:655420,name:"ConnectionBlocked",args:[{type:"shortstr",name:"reason","default":""}]};e.exports.ConnectionUnblocked=655421;var qt=e.exports.methodInfoConnectionUnblocked={id:655421,name:"ConnectionUnblocked",args:[]};e.exports.ChannelOpen=1310730;var zt=e.exports.methodInfoChannelOpen={id:1310730,name:"ChannelOpen",args:[{type:"shortstr",name:"outOfBand","default":""}]};e.exports.ChannelOpenOk=1310731;var Ht=e.exports.methodInfoChannelOpenOk={ +id:1310731,name:"ChannelOpenOk",args:[{type:"longstr",name:"channelId","default":""}]};e.exports.ChannelFlow=1310740;var Qt=e.exports.methodInfoChannelFlow={id:1310740,name:"ChannelFlow",args:[{type:"bit",name:"active"}]};e.exports.ChannelFlowOk=1310741;var Wt=e.exports.methodInfoChannelFlowOk={id:1310741,name:"ChannelFlowOk",args:[{type:"bit",name:"active"}]};e.exports.ChannelClose=1310760;var Kt=e.exports.methodInfoChannelClose={id:1310760,name:"ChannelClose",args:[{type:"short",name:"replyCode"},{type:"shortstr",name:"replyText","default":""},{type:"short",name:"classId"},{type:"short",name:"methodId"}]};e.exports.ChannelCloseOk=1310761;var Vt=e.exports.methodInfoChannelCloseOk={id:1310761,name:"ChannelCloseOk",args:[]};e.exports.AccessRequest=1966090;var Gt=e.exports.methodInfoAccessRequest={id:1966090,name:"AccessRequest",args:[{type:"shortstr",name:"realm","default":"/data"},{type:"bit",name:"exclusive","default":!1},{type:"bit",name:"passive","default":!0},{type:"bit",name:"active","default":!0},{type:"bit",name:"write","default":!0},{type:"bit",name:"read","default":!0}]};e.exports.AccessRequestOk=1966091;var Yt=e.exports.methodInfoAccessRequestOk={id:1966091,name:"AccessRequestOk",args:[{type:"short",name:"ticket","default":1}]};e.exports.ExchangeDeclare=2621450;var $t=e.exports.methodInfoExchangeDeclare={id:2621450,name:"ExchangeDeclare",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"type","default":"direct"},{type:"bit",name:"passive","default":!1},{type:"bit",name:"durable","default":!1},{type:"bit",name:"autoDelete","default":!1},{type:"bit",name:"internal","default":!1},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.ExchangeDeclareOk=2621451;var Xt=e.exports.methodInfoExchangeDeclareOk={id:2621451,name:"ExchangeDeclareOk",args:[]};e.exports.ExchangeDelete=2621460;var Jt=e.exports.methodInfoExchangeDelete={id:2621460,name:"ExchangeDelete",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"exchange"},{type:"bit",name:"ifUnused","default":!1},{type:"bit",name:"nowait","default":!1}]};e.exports.ExchangeDeleteOk=2621461;var Zt=e.exports.methodInfoExchangeDeleteOk={id:2621461,name:"ExchangeDeleteOk",args:[]};e.exports.ExchangeBind=2621470;var en=e.exports.methodInfoExchangeBind={id:2621470,name:"ExchangeBind",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"destination"},{type:"shortstr",name:"source"},{type:"shortstr",name:"routingKey","default":""},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.ExchangeBindOk=2621471;var tn=e.exports.methodInfoExchangeBindOk={id:2621471,name:"ExchangeBindOk",args:[]};e.exports.ExchangeUnbind=2621480;var nn=e.exports.methodInfoExchangeUnbind={id:2621480,name:"ExchangeUnbind",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"destination"},{type:"shortstr",name:"source"},{type:"shortstr",name:"routingKey","default":""},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.ExchangeUnbindOk=2621491;var rn=e.exports.methodInfoExchangeUnbindOk={id:2621491,name:"ExchangeUnbindOk",args:[]};e.exports.QueueDeclare=3276810;var on=e.exports.methodInfoQueueDeclare={id:3276810,name:"QueueDeclare",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"bit",name:"passive","default":!1},{type:"bit",name:"durable","default":!1},{type:"bit",name:"exclusive","default":!1},{type:"bit",name:"autoDelete","default":!1},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.QueueDeclareOk=3276811;var sn=e.exports.methodInfoQueueDeclareOk={id:3276811,name:"QueueDeclareOk",args:[{type:"shortstr",name:"queue"},{type:"long",name:"messageCount"},{type:"long",name:"consumerCount"}]};e.exports.QueueBind=3276820;var an=e.exports.methodInfoQueueBind={id:3276820,name:"QueueBind",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"routingKey","default":""},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.QueueBindOk=3276821;var un=e.exports.methodInfoQueueBindOk={id:3276821,name:"QueueBindOk",args:[]};e.exports.QueuePurge=3276830;var cn=e.exports.methodInfoQueuePurge={id:3276830,name:"QueuePurge",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"bit",name:"nowait","default":!1}]};e.exports.QueuePurgeOk=3276831;var ln=e.exports.methodInfoQueuePurgeOk={id:3276831,name:"QueuePurgeOk",args:[{type:"long",name:"messageCount"}]};e.exports.QueueDelete=3276840;var fn=e.exports.methodInfoQueueDelete={id:3276840,name:"QueueDelete",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"bit",name:"ifUnused","default":!1},{type:"bit",name:"ifEmpty","default":!1},{type:"bit",name:"nowait","default":!1}]};e.exports.QueueDeleteOk=3276841;var hn=e.exports.methodInfoQueueDeleteOk={id:3276841,name:"QueueDeleteOk",args:[{type:"long",name:"messageCount"}]};e.exports.QueueUnbind=3276850;var pn=e.exports.methodInfoQueueUnbind={id:3276850,name:"QueueUnbind",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"routingKey","default":""},{type:"table",name:"arguments","default":{}}]};e.exports.QueueUnbindOk=3276851;var dn=e.exports.methodInfoQueueUnbindOk={id:3276851,name:"QueueUnbindOk",args:[]};e.exports.BasicQos=3932170;var vn=e.exports.methodInfoBasicQos={id:3932170,name:"BasicQos",args:[{type:"long",name:"prefetchSize","default":0},{type:"short",name:"prefetchCount","default":0},{type:"bit",name:"global","default":!1}]};e.exports.BasicQosOk=3932171;var gn=e.exports.methodInfoBasicQosOk={id:3932171,name:"BasicQosOk",args:[]};e.exports.BasicConsume=3932180;var yn=e.exports.methodInfoBasicConsume={id:3932180,name:"BasicConsume",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"shortstr",name:"consumerTag","default":""},{type:"bit",name:"noLocal","default":!1},{type:"bit",name:"noAck","default":!1},{type:"bit",name:"exclusive","default":!1},{type:"bit",name:"nowait","default":!1},{type:"table",name:"arguments","default":{}}]};e.exports.BasicConsumeOk=3932181;var mn=e.exports.methodInfoBasicConsumeOk={id:3932181,name:"BasicConsumeOk",args:[{type:"shortstr",name:"consumerTag"}]};e.exports.BasicCancel=3932190;var bn=e.exports.methodInfoBasicCancel={id:3932190,name:"BasicCancel",args:[{type:"shortstr",name:"consumerTag"},{type:"bit",name:"nowait","default":!1}]};e.exports.BasicCancelOk=3932191;var _n=e.exports.methodInfoBasicCancelOk={id:3932191,name:"BasicCancelOk",args:[{type:"shortstr",name:"consumerTag"}]};e.exports.BasicPublish=3932200;var wn=e.exports.methodInfoBasicPublish={id:3932200,name:"BasicPublish",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"exchange","default":""},{type:"shortstr",name:"routingKey","default":""},{type:"bit",name:"mandatory","default":!1},{type:"bit",name:"immediate","default":!1}]};e.exports.BasicReturn=3932210;var En=e.exports.methodInfoBasicReturn={id:3932210,name:"BasicReturn",args:[{type:"short",name:"replyCode"},{type:"shortstr",name:"replyText","default":""},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"routingKey"}]};e.exports.BasicDeliver=3932220;var xn=e.exports.methodInfoBasicDeliver={id:3932220,name:"BasicDeliver",args:[{type:"shortstr",name:"consumerTag"},{type:"longlong",name:"deliveryTag"},{type:"bit",name:"redelivered","default":!1},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"routingKey"}]};e.exports.BasicGet=3932230;var kn=e.exports.methodInfoBasicGet={id:3932230,name:"BasicGet",args:[{type:"short",name:"ticket","default":0},{type:"shortstr",name:"queue","default":""},{type:"bit",name:"noAck","default":!1}]};e.exports.BasicGetOk=3932231;var In=e.exports.methodInfoBasicGetOk={id:3932231,name:"BasicGetOk",args:[{type:"longlong",name:"deliveryTag"},{type:"bit",name:"redelivered","default":!1},{type:"shortstr",name:"exchange"},{type:"shortstr",name:"routingKey"},{type:"long",name:"messageCount"}]};e.exports.BasicGetEmpty=3932232;var Cn=e.exports.methodInfoBasicGetEmpty={id:3932232,name:"BasicGetEmpty",args:[{type:"shortstr",name:"clusterId","default":""}]};e.exports.BasicAck=3932240;var Sn=e.exports.methodInfoBasicAck={id:3932240,name:"BasicAck",args:[{type:"longlong",name:"deliveryTag","default":0},{type:"bit",name:"multiple","default":!1}]};e.exports.BasicReject=3932250;var Tn=e.exports.methodInfoBasicReject={id:3932250,name:"BasicReject",args:[{type:"longlong",name:"deliveryTag"},{type:"bit",name:"requeue","default":!0}]};e.exports.BasicRecoverAsync=3932260;var Bn=e.exports.methodInfoBasicRecoverAsync={id:3932260,name:"BasicRecoverAsync",args:[{type:"bit",name:"requeue","default":!1}]};e.exports.BasicRecover=3932270;var Un=e.exports.methodInfoBasicRecover={id:3932270,name:"BasicRecover",args:[{type:"bit",name:"requeue","default":!1}]};e.exports.BasicRecoverOk=3932271;var On=e.exports.methodInfoBasicRecoverOk={id:3932271,name:"BasicRecoverOk",args:[]};e.exports.BasicNack=3932280;var jn=e.exports.methodInfoBasicNack={id:3932280,name:"BasicNack",args:[{type:"longlong",name:"deliveryTag","default":0},{type:"bit",name:"multiple","default":!1},{type:"bit",name:"requeue","default":!0}]};e.exports.TxSelect=5898250;var An=e.exports.methodInfoTxSelect={id:5898250,name:"TxSelect",args:[]};e.exports.TxSelectOk=5898251;var Rn=e.exports.methodInfoTxSelectOk={id:5898251,name:"TxSelectOk",args:[]};e.exports.TxCommit=5898260;var Fn=e.exports.methodInfoTxCommit={id:5898260,name:"TxCommit",args:[]};e.exports.TxCommitOk=5898261;var Pn=e.exports.methodInfoTxCommitOk={id:5898261,name:"TxCommitOk",args:[]};e.exports.TxRollback=5898270;var Ln=e.exports.methodInfoTxRollback={id:5898270,name:"TxRollback",args:[]};e.exports.TxRollbackOk=5898271;var Mn=e.exports.methodInfoTxRollbackOk={id:5898271,name:"TxRollbackOk",args:[]};e.exports.ConfirmSelect=5570570;var Nn=e.exports.methodInfoConfirmSelect={id:5570570,name:"ConfirmSelect",args:[{type:"bit",name:"nowait","default":!1}]};e.exports.ConfirmSelectOk=5570571;var Dn=e.exports.methodInfoConfirmSelectOk={id:5570571,name:"ConfirmSelectOk",args:[]};e.exports.BasicProperties=60;var qn=e.exports.propertiesInfoBasicProperties={id:60,name:"BasicProperties",args:[{type:"shortstr",name:"contentType"},{type:"shortstr",name:"contentEncoding"},{type:"table",name:"headers"},{type:"octet",name:"deliveryMode"},{type:"octet",name:"priority"},{type:"shortstr",name:"correlationId"},{type:"shortstr",name:"replyTo"},{type:"shortstr",name:"expiration"},{type:"shortstr",name:"messageId"},{type:"timestamp",name:"timestamp"},{type:"shortstr",name:"type"},{type:"shortstr",name:"userId"},{type:"shortstr",name:"appId"},{type:"shortstr",name:"clusterId"}]}}).call(t,n(3).Buffer)},function(e,t,n){function r(e,t){for(var n in e)t[n]=e[n]}function i(e,t,n){return s(e,t,n)}var o=n(3),s=o.Buffer;s.from&&s.alloc&&s.allocUnsafe&&s.allocUnsafeSlow?e.exports=o:(r(o,t),t.Buffer=i),r(s,i),i.from=function(e,t,n){if("number"==typeof e)throw new TypeError("Argument must not be a number");return s(e,t,n)},i.alloc=function(e,t,n){if("number"!=typeof e)throw new TypeError("Argument must be a number");var r=s(e);return void 0!==t?"string"==typeof n?r.fill(t,n):r.fill(t):r.fill(0),r},i.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return s(e)},i.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return o.SlowBuffer(e)}},function(e,t,n){(function(t){"use strict";function r(e){return e>=0x8000000000000000||Math.abs(e)<0x4000000000000&&Math.floor(e)!==e}function i(e,n,r){var i=r;r+=4;for(var o in n)if(void 0!==n[o]){var a=t.byteLength(o);e.writeUInt8(a,r),r++,e.write(o,r,"utf8"),r+=a,r+=s(e,n[o],r)}var u=r-i;return e.writeUInt32BE(u-4,i),u}function o(e,t,n){var r=n;n+=4;for(var i=0,o=t.length;i=-128?"byte":f>=-32768&&f<32768?"short":f>=-2147483648&&f<2147483648?"int":"long"),l){case"string":var h=t.byteLength(f,"utf8");a("S"),e.writeUInt32BE(h,s),s+=4,e.write(f,s,"utf8"),s+=h;break;case"object":null===f?a("V"):Array.isArray(f)?(a("A"),s+=o(e,f,s)):t.isBuffer(f)?(a("x"),e.writeUInt32BE(f.length,s),s+=4,f.copy(e,s),s+=f.length):(a("F"),s+=i(e,f,s));break;case"boolean":a("t"),e.writeUInt8(f?1:0,s),s++;break;case"double":case"float64":a("d"),e.writeDoubleBE(f,s),s+=8;break;case"byte":case"int8":a("b"),e.writeInt8(f,s),s++;break;case"short":case"int16":a("s"),e.writeInt16BE(f,s),s+=2;break;case"int":case"int32":a("I"),e.writeInt32BE(f,s),s+=4;break;case"long":case"int64":a("l"),u.writeInt64BE(e,f,s),s+=8;break;case"timestamp":a("T"),u.writeUInt64BE(e,f,s),s+=8;break;case"float":a("f"),e.writeFloatBE(f,s),s+=4;break;case"decimal":if(a("D"),!(f.hasOwnProperty("places")&&f.hasOwnProperty("digits")&&f.places>=0&&f.places<256))throw new TypeError("Decimal value must be {'places': 0..255, 'digits': uint32}, got "+JSON.stringify(f));e[s]=f.places,s++,e.writeUInt32BE(f.digits,s),s+=4;break;default:throw new TypeError("Unknown type to encode: "+l)}return s-c}function a(e){function t(){var t=String.fromCharCode(e[c]);switch(c++,t){case"b":o=e.readInt8(c),c++;break;case"S":r=e.readUInt32BE(c),c+=4,o=e.toString("utf8",c,c+r),c+=r;break;case"I":o=e.readInt32BE(c),c+=4;break;case"D":var i=e[c];c++;var s=e.readUInt32BE(c);c+=4,o={"!":"decimal",value:{places:i,digits:s}};break;case"T":o=u.readUInt64BE(e,c),c+=8,o={"!":"timestamp",value:o};break;case"F":r=e.readUInt32BE(c),c+=4,o=a(e.slice(c,c+r)),c+=r;break;case"A":r=e.readUInt32BE(c),c+=4,n(c+r);break;case"d":o=e.readDoubleBE(c),c+=8;break;case"f":o=e.readFloatBE(c),c+=4;break;case"l":o=u.readInt64BE(e,c),c+=8;break;case"s":o=e.readInt16BE(c),c+=2;break;case"t":o=0!=e[c],c++;break;case"V":o=null;break;case"x":r=e.readUInt32BE(c),c+=4,o=e.slice(c,c+r),c+=r;break;default:throw new TypeError('Unexpected type tag "'+t+'"')}}function n(e){for(var n=[];c=-Y}function i(e){K(r(e),"number cannot be represented as a contiguous integer")}function o(e,t,n){K.ok("number"==typeof e&&e>=t&&e<=n&&Math.floor(e)===e,"not a number in the required range")}function s(e,t,n){return e.readUInt8(t,n)<<16|e.readUInt16BE(t+1,n)}function a(e,t,n,r){r||(o(t,0,16777215),K.ok(n+3<=e.length,"attempt to write beyond end of buffer")),e.writeUInt8(t>>>16,n,r),e.writeUInt16BE(65535&t,n+1,r)}function u(e,t,n){return(e.readUInt8(t,n)||0)*V+e.readUInt32BE(t+1,n)}function c(e,t,n,r){r||(o(t,0,0xffffffffff),K.ok(n+5<=e.length,"attempt to write beyond end of buffer")),e.writeUInt8(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+1,r)}function l(e,t,n){return e.readUInt16BE(t,n)*V+e.readUInt32BE(t+2,n)}function f(e,t,n,r){r||(o(t,0,0xffffffffffff),K.ok(n+6<=e.length,"attempt to write beyond end of buffer")),e.writeUInt16BE(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+2,r)}function h(e,t,n){return((e.readUInt8(t,n)||0)<<16|e.readUInt16BE(t+1,n))*V+e.readUInt32BE(t+3,n)}function p(e,t,n,r){if(r||(o(t,0,72057594037927940),K.ok(n+7<=e.length,"attempt to write beyond end of buffer")),t<72057594037927940){var i=Math.floor(t*G);e.writeUInt8(i>>>16,n,r),e.writeUInt16BE(65535&i,n+1,r),e.writeInt32BE(t&-1,n+3,r)}else e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255}function d(e,t,n){return e.readUInt32BE(t,n)*V+e.readUInt32BE(t+4,n)}function v(e,t,n,r){r||(o(t,0,0x10000000000000000),K.ok(n+8<=e.length,"attempt to write beyond end of buffer")),t<0x10000000000000000?(e.writeUInt32BE(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+4,r)):(e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255,e[n+7]=255)}function g(e,t,n){return e.readUInt8(t+2,n)<<16|e.readUInt16LE(t,n)}function y(e,t,n,r){r||(o(t,0,16777215),K.ok(n+3<=e.length,"attempt to write beyond end of buffer")),e.writeUInt16LE(65535&t,n,r),e.writeUInt8(t>>>16,n+2,r)}function m(e,t,n){return(e.readUInt8(t+4,n)||0)*V+e.readUInt32LE(t,n)}function b(e,t,n,r){r||(o(t,0,0xffffffffff),K.ok(n+5<=e.length,"attempt to write beyond end of buffer")),e.writeInt32LE(t&-1,n,r),e.writeUInt8(Math.floor(t*G),n+4,r)}function _(e,t,n){return e.readUInt16LE(t+4,n)*V+e.readUInt32LE(t,n)}function w(e,t,n,r){r||(o(t,0,0xffffffffffff),K.ok(n+6<=e.length,"attempt to write beyond end of buffer")),e.writeInt32LE(t&-1,n,r),e.writeUInt16LE(Math.floor(t*G),n+4,r)}function E(e,t,n){return((e.readUInt8(t+6,n)||0)<<16|e.readUInt16LE(t+4,n))*V+e.readUInt32LE(t,n)}function x(e,t,n,r){if(r||(o(t,0,72057594037927940),K.ok(n+7<=e.length,"attempt to write beyond end of buffer")),t<72057594037927940){e.writeInt32LE(t&-1,n,r);var i=Math.floor(t*G);e.writeUInt16LE(65535&i,n+4,r),e.writeUInt8(i>>>16,n+6,r)}else e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255}function k(e,t,n){return e.readUInt32LE(t+4,n)*V+e.readUInt32LE(t,n)}function I(e,t,n,r){r||(o(t,0,0x10000000000000000),K.ok(n+8<=e.length,"attempt to write beyond end of buffer")),t<0x10000000000000000?(e.writeInt32LE(t&-1,n,r),e.writeUInt32LE(Math.floor(t*G),n+4,r)):(e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255,e[n+7]=255)}function C(e,t,n){return(e.readInt8(t,n)<<16)+e.readUInt16BE(t+1,n)}function S(e,t,n,r){r||(o(t,-8388608,8388607),K.ok(n+3<=e.length,"attempt to write beyond end of buffer")),e.writeInt8(t>>16,n,r),e.writeUInt16BE(65535&t,n+1,r)}function T(e,t,n){return(e.readInt8(t,n)||0)*V+e.readUInt32BE(t+1,n)}function B(e,t,n,r){r||(o(t,-549755813888,549755813887),K.ok(n+5<=e.length,"attempt to write beyond end of buffer")),e.writeInt8(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+1,r)}function U(e,t,n){return e.readInt16BE(t,n)*V+e.readUInt32BE(t+2,n)}function O(e,t,n,r){r||(o(t,-0x800000000000,0x7fffffffffff),K.ok(n+6<=e.length,"attempt to write beyond end of buffer")),e.writeInt16BE(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+2,r)}function j(e,t,n){return(((e.readInt8(t,n)||0)<<16)+e.readUInt16BE(t+1,n))*V+e.readUInt32BE(t+3,n)}function A(e,t,n,r){if(r||(o(t,-0x800000000000000,0x80000000000000),K.ok(n+7<=e.length,"attempt to write beyond end of buffer")),t<0x80000000000000){var i=Math.floor(t*G);e.writeInt8(i>>16,n,r),e.writeUInt16BE(65535&i,n+1,r),e.writeInt32BE(t&-1,n+3,r)}else e[n]=127,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255}function R(e,t,n){return e.readInt32BE(t,n)*V+e.readUInt32BE(t+4,n)}function F(e,t,n,r){r||(o(t,-0x800000000000000000,0x8000000000000000),K.ok(n+8<=e.length,"attempt to write beyond end of buffer")),t<0x8000000000000000?(e.writeInt32BE(Math.floor(t*G),n,r),e.writeInt32BE(t&-1,n+4,r)):(e[n]=127,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255,e[n+7]=255)}function P(e,t,n){return(e.readInt8(t+2,n)<<16)+e.readUInt16LE(t,n)}function L(e,t,n,r){r||(o(t,-8388608,8388607),K.ok(n+3<=e.length,"attempt to write beyond end of buffer")),e.writeUInt16LE(65535&t,n,r),e.writeInt8(t>>16,n+2,r)}function M(e,t,n){return(e.readInt8(t+4,n)||0)*V+e.readUInt32LE(t,n)}function N(e,t,n,r){r||(o(t,-549755813888,549755813887),K.ok(n+5<=e.length,"attempt to write beyond end of buffer")),e.writeInt32LE(t&-1,n,r),e.writeInt8(Math.floor(t*G),n+4,r)}function D(e,t,n){return e.readInt16LE(t+4,n)*V+e.readUInt32LE(t,n)}function q(e,t,n,r){r||(o(t,-0x800000000000,0x7fffffffffff),K.ok(n+6<=e.length,"attempt to write beyond end of buffer")),e.writeInt32LE(t&-1,n,r),e.writeInt16LE(Math.floor(t*G),n+4,r)}function z(e,t,n){return(((e.readInt8(t+6,n)||0)<<16)+e.readUInt16LE(t+4,n))*V+e.readUInt32LE(t,n)}function H(e,t,n,r){if(r||(o(t,-0x80000000000000,0x80000000000000),K.ok(n+7<=e.length,"attempt to write beyond end of buffer")),t<0x80000000000000){e.writeInt32LE(t&-1,n,r);var i=Math.floor(t*G);e.writeUInt16LE(65535&i,n+4,r),e.writeInt8(i>>16,n+6,r)}else e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=127}function Q(e,t,n){return e.readInt32LE(t+4,n)*V+e.readUInt32LE(t,n)}function W(e,t,n,r){r||(o(t,-0x8000000000000000,0x8000000000000000),K.ok(n+8<=e.length,"attempt to write beyond end of buffer")),t<0x8000000000000000?(e.writeInt32LE(t&-1,n,r),e.writeInt32LE(Math.floor(t*G),n+4,r)):(e[n]=255,e[n+1]=255,e[n+2]=255,e[n+3]=255,e[n+4]=255,e[n+5]=255,e[n+6]=255,e[n+7]=127)}var K=n(121),V=4294967296,G=1/V,Y=9007199254740991;e.exports.isContiguousInt=r,e.exports.assertContiguousInt=i,["UInt","Int"].forEach(function(n){var r=n+"8";e.exports["read"+r]=t.prototype["read"+r].call,e.exports["write"+r]=t.prototype["write"+r].call,["16","32"].forEach(function(r){["LE","BE"].forEach(function(i){var o=n+r+i,s=t.prototype["read"+o];e.exports["read"+o]=function(e,t,n){return s.call(e,t,n)};var a=t.prototype["write"+o];e.exports["write"+o]=function(e,t,n,r){return a.call(e,t,n,r)}})})}),e.exports.readUInt24BE=s,e.exports.writeUInt24BE=a,e.exports.readUInt40BE=u,e.exports.writeUInt40BE=c,e.exports.readUInt48BE=l,e.exports.writeUInt48BE=f,e.exports.readUInt56BE=h,e.exports.writeUInt56BE=p,e.exports.readUInt64BE=d,e.exports.writeUInt64BE=v,e.exports.readUInt24LE=g,e.exports.writeUInt24LE=y,e.exports.readUInt40LE=m,e.exports.writeUInt40LE=b,e.exports.readUInt48LE=_,e.exports.writeUInt48LE=w,e.exports.readUInt56LE=E,e.exports.writeUInt56LE=x,e.exports.readUInt64LE=k,e.exports.writeUInt64LE=I,e.exports.readInt24BE=C,e.exports.writeInt24BE=S,e.exports.readInt40BE=T,e.exports.writeInt40BE=B,e.exports.readInt48BE=U,e.exports.writeInt48BE=O,e.exports.readInt56BE=j,e.exports.writeInt56BE=A,e.exports.readInt64BE=R,e.exports.writeInt64BE=F,e.exports.readInt24LE=P,e.exports.writeInt24LE=L,e.exports.readInt40LE=M,e.exports.writeInt40LE=N,e.exports.readInt48LE=D,e.exports.writeInt48LE=q,e.exports.readInt56LE=z,e.exports.writeInt56LE=H,e.exports.readInt64LE=Q,e.exports.writeInt64LE=W}).call(t,n(3).Buffer)},function(e,t,n){(function(t){"use strict";/*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh * @license MIT */ -function r(e,t){if(e===t)return 0;for(var n=e.length,r=t.length,i=0,o=Math.min(n,r);i=0;a--)if(u[a]!==c[a])return!1;for(a=u.length-1;a>=0;a--)if(s=u[a],!p(e[s],t[s],n,r))return!1;return!0}function g(e,t,n){p(e,t,!0)&&f(e,t,n,"notDeepStrictEqual",g)}function y(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(n){}return!Error.isPrototypeOf(t)&&t.call({},e)===!0}function m(e){var t;try{e()}catch(n){t=n}return t}function b(e,t,n,r){var i;if("function"!=typeof t)throw new TypeError('"block" argument must be a function');"string"==typeof n&&(r=n,n=null),i=m(t),r=(n&&n.name?" ("+n.name+").":".")+(r?" "+r:"."),e&&!i&&f(i,n,"Missing expected exception"+r);var o="string"==typeof r,s=!e&&w.isError(i),a=!e&&i&&!n;if((s&&o&&y(i,n)||a)&&f(i,n,"Got unwanted exception"+r),e&&i&&n&&!y(i,n)||!e&&i)throw i}var w=n(73),_=Object.prototype.hasOwnProperty,E=Array.prototype.slice,x=function(){return"foo"===function(){}.name}(),k=e.exports=h,I=/\s*function\s+([^\(\s]*)\s*/;k.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=l(this),this.generatedMessage=!0);var t=e.stackStartFunction||f;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var n=new Error;if(n.stack){var r=n.stack,i=a(t),o=r.indexOf("\n"+i);if(o>=0){var s=r.indexOf("\n",o+1);r=r.substring(s+1)}this.stack=r}}},w.inherits(k.AssertionError,Error),k.fail=f,k.ok=h,k.equal=function(e,t,n){e!=t&&f(e,t,n,"==",k.equal)},k.notEqual=function(e,t,n){e==t&&f(e,t,n,"!=",k.notEqual)},k.deepEqual=function(e,t,n){p(e,t,!1)||f(e,t,n,"deepEqual",k.deepEqual)},k.deepStrictEqual=function(e,t,n){p(e,t,!0)||f(e,t,n,"deepStrictEqual",k.deepStrictEqual)},k.notDeepEqual=function(e,t,n){p(e,t,!1)&&f(e,t,n,"notDeepEqual",k.notDeepEqual)},k.notDeepStrictEqual=g,k.strictEqual=function(e,t,n){e!==t&&f(e,t,n,"===",k.strictEqual)},k.notStrictEqual=function(e,t,n){e===t&&f(e,t,n,"!==",k.notStrictEqual)},k["throws"]=function(e,t,n){b(!0,e,t,n)},k.doesNotThrow=function(e,t,n){b(!1,e,t,n)},k.ifError=function(e){if(e)throw e};var S=Object.keys||function(e){var t=[];for(var n in e)_.call(e,n)&&t.push(n);return t}}).call(t,function(){return this}())},[312,74,75],function(e,t){e.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},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 n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},function(e,t,n){(function(t){"use strict";function r(e,t){var n=d(e);if(n){var r=n.size,i=n.rest;if(r>t)throw new Error("Frame size exceeds frame max");if(i.length>r){if(i[r]!==h)throw new Error("Invalid frame");return{type:n.type,channel:n.channel,size:r,payload:i.slice(0,r),rest:i.slice(r+1)}}}return!1}var i=n(69),o=i.constants,s=i.decode,a=n(77);e.exports.PROTOCOL_HEADER="AMQP"+String.fromCharCode(0,0,9,1);var u=o.FRAME_METHOD,c=o.FRAME_HEARTBEAT,l=o.FRAME_HEADER,f=o.FRAME_BODY,h=o.FRAME_END,p=a.builder(f,"channel:16, size:32, payload:size/binary",h);e.exports.makeBodyFrame=function(e,t){return p({channel:e,size:t.length,payload:t})};var d=a.matcher("type:8","channel:16","size:32","rest/binary");e.exports.parseFrame=r;var v=a.matcher("class:16","_weight:16","size:64","flagsAndfields/binary"),g=a.matcher("id:32, args/binary"),y={channel:0};e.exports.decodeFrame=function(e){var t=e.payload;switch(e.type){case u:var n=g(t),r=n.id,i=s(r,n.args);return{id:r,channel:e.channel,fields:i};case l:var o=v(t),r=o["class"],i=s(r,o.flagsAndfields);return{id:r,channel:e.channel,size:o.size,fields:i};case f:return{channel:e.channel,content:e.payload};case c:return y;default:throw new Error("Unknown frame type "+e.type)}},e.exports.HEARTBEAT_BUF=new t([o.FRAME_HEARTBEAT,0,0,0,0,0,0,o.FRAME_END]),e.exports.HEARTBEAT=y}).call(t,n(3).Buffer)},function(e,t,n){"use strict";e.exports.parse=n(78).parse,e.exports.match=n(81).match,e.exports.build=n(82).build,e.exports.write=n(82).write,e.exports.matcher=e.exports.compile=n(83).compile,e.exports.builder=n(83).compile_builder},function(e,t,n){"use strict";function r(e){for(var t=o.parse(e),n=0,r=t.length;nk&&(k=E,I=[]),I.push(e))}function i(){var e,t,n,r,i,a;if(i=E,a=E,e=m(),null!==e)if(t=s(),null!==t){for(n=[],r=o();null!==r;)n.push(r),r=o();null!==n?e=[e,t,n]:(e=null,E=a)}else e=null,E=a;else e=null,E=a;return null!==e&&(e=function(e,t,n){return n.unshift(t),n}(i,e[1],e[2])),null===e&&(E=i),e}function o(){var e,n,i,o,a,u;return a=E,u=E,e=m(),null!==e?(44===t.charCodeAt(E)?(n=",",E++):(n=null,0===x&&r('","')),null!==n?(i=m(),null!==i?(o=s(),null!==o?e=[e,n,i,o]:(e=null,E=u)):(e=null,E=u)):(e=null,E=u)):(e=null,E=u),null!==e&&(e=function(e,t){return t}(a,e[3])),null===e&&(E=a),e}function s(){var e,t,n,r,i;return r=E,e=a(),null!==e&&(e=function(e,t){return{string:t}}(r,e)),null===e&&(E=r),null===e&&(r=E,i=E,e=f(),null!==e?(t=p(),t=null!==t?t:"",null!==t?(n=d(),n=null!==n?n:"",null!==n?e=[e,t,n]:(e=null,E=i)):(e=null,E=i)):(e=null,E=i),null!==e&&(e=function(e,t,n,r){return{name:t,size:n,specifiers:r}}(r,e[0],e[1],e[2])),null===e&&(E=r),null===e&&(r=E,i=E,e=h(),null!==e?(t=p(),t=null!==t?t:"",null!==t?(n=d(),n=null!==n?n:"",null!==n?e=[e,t,n]:(e=null,E=i)):(e=null,E=i)):(e=null,E=i),null!==e&&(e=function(e,t,n,r){return{value:t,size:n,specifiers:r}}(r,e[0],e[1],e[2])),null===e&&(E=r))),e}function a(){var e,n,i,o,s;return o=E,s=E,34===t.charCodeAt(E)?(e='"',E++):(e=null,0===x&&r('"\\""')),null!==e?(34===t.charCodeAt(E)?(n='"',E++):(n=null,0===x&&r('"\\""')),null!==n?e=[e,n]:(e=null,E=s)):(e=null,E=s),null!==e&&(e=function(e){return""}(o)),null===e&&(E=o),null===e&&(o=E,s=E,34===t.charCodeAt(E)?(e='"',E++):(e=null,0===x&&r('"\\""')),null!==e?(n=u(),null!==n?(34===t.charCodeAt(E)?(i='"',E++):(i=null,0===x&&r('"\\""')),null!==i?e=[e,n,i]:(e=null,E=s)):(e=null,E=s)):(e=null,E=s),null!==e&&(e=function(e,t){return t}(o,e[1])),null===e&&(E=o)),e}function u(){var e,t,n;if(n=E,t=c(),null!==t)for(e=[];null!==t;)e.push(t),t=c();else e=null;return null!==e&&(e=function(e,t){return t.join("")}(n,e)),null===e&&(E=n),e}function c(){var e,n,i,o,s,a,u;return/^[^"\\\0-\x1F]/.test(t.charAt(E))?(e=t.charAt(E),E++):(e=null,0===x&&r('[^"\\\\\\0-\\x1F]')),null===e&&(a=E,'\\"'===t.substr(E,2)?(e='\\"',E+=2):(e=null,0===x&&r('"\\\\\\""')),null!==e&&(e=function(e){return'"'}(a)),null===e&&(E=a),null===e&&(a=E,"\\\\"===t.substr(E,2)?(e="\\\\",E+=2):(e=null,0===x&&r('"\\\\\\\\"')),null!==e&&(e=function(e){return"\\"}(a)),null===e&&(E=a),null===e&&(a=E,"\\/"===t.substr(E,2)?(e="\\/",E+=2):(e=null,0===x&&r('"\\\\/"')),null!==e&&(e=function(e){return"/"}(a)),null===e&&(E=a),null===e&&(a=E,"\\b"===t.substr(E,2)?(e="\\b",E+=2):(e=null,0===x&&r('"\\\\b"')),null!==e&&(e=function(e){return"\b"}(a)),null===e&&(E=a),null===e&&(a=E,"\\f"===t.substr(E,2)?(e="\\f",E+=2):(e=null,0===x&&r('"\\\\f"')),null!==e&&(e=function(e){return"\f"}(a)),null===e&&(E=a),null===e&&(a=E,"\\n"===t.substr(E,2)?(e="\\n",E+=2):(e=null,0===x&&r('"\\\\n"')),null!==e&&(e=function(e){return"\n"}(a)),null===e&&(E=a),null===e&&(a=E,"\\r"===t.substr(E,2)?(e="\\r",E+=2):(e=null,0===x&&r('"\\\\r"')),null!==e&&(e=function(e){return"\r"}(a)),null===e&&(E=a),null===e&&(a=E,"\\t"===t.substr(E,2)?(e="\\t",E+=2):(e=null,0===x&&r('"\\\\t"')),null!==e&&(e=function(e){return"\t"}(a)),null===e&&(E=a),null===e&&(a=E,u=E,"\\u"===t.substr(E,2)?(e="\\u",E+=2):(e=null,0===x&&r('"\\\\u"')),null!==e?(n=l(),null!==n?(i=l(),null!==i?(o=l(),null!==o?(s=l(),null!==s?e=[e,n,i,o,s]:(e=null,E=u)):(e=null,E=u)):(e=null,E=u)):(e=null,E=u)):(e=null,E=u),null!==e&&(e=function(e,t,n,r,i){return String.fromCharCode(parseInt("0x"+t+n+r+i))}(a,e[1],e[2],e[3],e[4])),null===e&&(E=a)))))))))),e}function l(){var e;return/^[0-9a-fA-F]/.test(t.charAt(E))?(e=t.charAt(E),E++):(e=null,0===x&&r("[0-9a-fA-F]")),e}function f(){var e,n,i,o,s;if(o=E,s=E,/^[_a-zA-Z]/.test(t.charAt(E))?(e=t.charAt(E),E++):(e=null,0===x&&r("[_a-zA-Z]")),null!==e){for(n=[],/^[_a-zA-Z0-9]/.test(t.charAt(E))?(i=t.charAt(E),E++):(i=null,0===x&&r("[_a-zA-Z0-9]"));null!==i;)n.push(i),/^[_a-zA-Z0-9]/.test(t.charAt(E))?(i=t.charAt(E),E++):(i=null,0===x&&r("[_a-zA-Z0-9]"));null!==n?e=[e,n]:(e=null,E=s)}else e=null,E=s;return null!==e&&(e=function(e,t,n){return t+n.join("")}(o,e[0],e[1])),null===e&&(E=o),e}function h(){var e,n,i,o,s;if(o=E,48===t.charCodeAt(E)?(e="0",E++):(e=null,0===x&&r('"0"')),null!==e&&(e=function(e){return 0}(o)),null===e&&(E=o),null===e){if(o=E,s=E,/^[1-9]/.test(t.charAt(E))?(e=t.charAt(E),E++):(e=null,0===x&&r("[1-9]")),null!==e){for(n=[],/^[0-9]/.test(t.charAt(E))?(i=t.charAt(E),E++):(i=null,0===x&&r("[0-9]"));null!==i;)n.push(i),/^[0-9]/.test(t.charAt(E))?(i=t.charAt(E),E++):(i=null,0===x&&r("[0-9]"));null!==n?e=[e,n]:(e=null,E=s)}else e=null,E=s;null!==e&&(e=function(e,t,n){return parseInt(t+n.join(""))}(o,e[0],e[1])),null===e&&(E=o)}return e}function p(){var e,n,i,o;return i=E,o=E,58===t.charCodeAt(E)?(e=":",E++):(e=null,0===x&&r('":"')),null!==e?(n=h(),null!==n?e=[e,n]:(e=null,E=o)):(e=null,E=o),null!==e&&(e=function(e,t){return t}(i,e[1])),null===e&&(E=i),null===e&&(i=E,o=E,58===t.charCodeAt(E)?(e=":",E++):(e=null,0===x&&r('":"')),null!==e?(n=f(),null!==n?e=[e,n]:(e=null,E=o)):(e=null,E=o),null!==e&&(e=function(e,t){return t}(i,e[1])),null===e&&(E=i)),e}function d(){var e,n,i,o,s,a;if(s=E,a=E,47===t.charCodeAt(E)?(e="/",E++):(e=null,0===x&&r('"/"')),null!==e)if(n=g(),null!==n){for(i=[],o=v();null!==o;)i.push(o),o=v();null!==i?e=[e,n,i]:(e=null,E=a)}else e=null,E=a;else e=null,E=a;return null!==e&&(e=function(e,t,n){return n.unshift(t),n}(s,e[1],e[2])),null===e&&(E=s),e}function v(){var e,n,i,o;return i=E,o=E,45===t.charCodeAt(E)?(e="-",E++):(e=null,0===x&&r('"-"')),null!==e?(n=g(),null!==n?e=[e,n]:(e=null,E=o)):(e=null,E=o),null!==e&&(e=function(e,t){return t}(i,e[1])),null===e&&(E=i),e}function g(){var e;return"little"===t.substr(E,6)?(e="little",E+=6):(e=null,0===x&&r('"little"')),null===e&&("big"===t.substr(E,3)?(e="big",E+=3):(e=null,0===x&&r('"big"')),null===e&&("signed"===t.substr(E,6)?(e="signed",E+=6):(e=null,0===x&&r('"signed"')),null===e&&("unsigned"===t.substr(E,8)?(e="unsigned",E+=8):(e=null,0===x&&r('"unsigned"')),null===e&&("integer"===t.substr(E,7)?(e="integer",E+=7):(e=null,0===x&&r('"integer"')),null===e&&("binary"===t.substr(E,6)?(e="binary",E+=6):(e=null,0===x&&r('"binary"')),null===e&&("float"===t.substr(E,5)?(e="float",E+=5):(e=null,0===x&&r('"float"')),null===e&&(e=y()))))))),e}function y(){var e,n,i,o;return i=E,o=E,"unit:"===t.substr(E,5)?(e="unit:",E+=5):(e=null,0===x&&r('"unit:"')),null!==e?(n=h(),null!==n?e=[e,n]:(e=null,E=o)):(e=null,E=o),null!==e&&(e=function(e,t){return"unit:"+t}(i,e[1])),null===e&&(E=i),e}function m(){var e,n;for(e=[],/^[ \t\n]/.test(t.charAt(E))?(n=t.charAt(E),E++):(n=null,0===x&&r("[ \\t\\n]"));null!==n;)e.push(n),/^[ \t\n]/.test(t.charAt(E))?(n=t.charAt(E),E++):(n=null,0===x&&r("[ \\t\\n]"));return e}function b(e){e.sort();for(var t=null,n=[],r=0;rg)&&void(d+=n)}function c(e){l("get_integer"),l(e);var n=e.unit,i=o(e,v),s=i*n,a=d/8;return d+=s,!(s%8>0||d>g)&&r(t,a,s/8,e.bigendian,e.signed)}function f(e){l("get_float"),l(e);var n=e.unit,r=o(e,v),s=r*n,a=d/8;return d+=s,!(d>g)&&i(t,a,s/8,e.bigendian)}function h(e){l("get_binary"),l(e);var n=e.unit,r=o(e,v),i=d/8;if(r===!0)return d=g,t.slice(i);var s=r*n;return!(s%8>0||d+s>g)&&(d+=s,t.slice(i,i+s/8))}function p(e){l("get_string"),l(e);var n=e.value.length,r=d/8;return d+=8*n,!(d>g)&&t.slice(r,r+n).toString("utf8")}for(var d=0,v=s(n),g=8*t.length,y=e.length,m=0;m1?[].join.call(arguments,","):e;var t=p(e);return function(e){return i(t,e)}}}).call(t,n(3).Buffer)},function(e,t,n){(function(t){"use strict";function r(){T=[]}function i(){T.push(w.apply(null,arguments))}function o(){return T.join("\n")}function s(e){return"string"==typeof e.size?w("%s * %d",h(e.size),e.unit):(e.size*e.unit).toString()}function a(e){i("bits = %s;\n",s(e));var t="integer"===e.type?"parse_int":"parse_float",n=e.bigendian,r=e.signed;i("byteoffset = offset / 8; offset += bits"),i("if (offset > binsize) { return false; }"),i("else { result = %s(bin, byteoffset, bits / 8, %s, %s); }",t,n,r)}function u(e){i("byteoffset = offset / 8;"),e.size===!0?(i("offset = binsize;"),i("result = bin.slice(byteoffset);")):(i("bits = %s;",s(e)),i("offset += bits;"),i("if (offset > binsize) { return false; }"),i("else { result = bin.slice(byteoffset,","byteoffset + bits / 8); }"))}function c(e){i("byteoffset = offset / 8;");var t=e.value.length,n=8*t;i("offset += %d;",n),i("if (offset > binsize) { return false; }"),i("else { result = bin.toString(byteoffset,",w("byteoffset + %d); }",t))}function l(e){if("string"==typeof e.size)i("var skipbits = %s * %d;",h(e.size),e.unit),i("if (offset + skipbits > binsize) { return false; }"),i("else { offset += skipbits; }");else if(e.size===!0)i("if (offset % 8 === 0) { offset = binsize; }"),i("else { return false; }");else{var t=e.unit*e.size;i("if (offset + %d > binsize) { return false; }",t),i("else { offset += %d; }",t)}}function f(e){if("_"===e.name)l(e);else{switch(e.type){case"integer":case"float":a(e);break;case"binary":u(e);break;case"string":c(e)}if(i("if (result === false) return false;"),e.name)i("else if (%s !== undefined) {",h(e.name)),i("if (%s != result) return false;",h(e.name)),i("}"),i("else %s = result;",h(e.name));else{var t=JSON.stringify(e.value);i("else if (result != %s) return false;",t)}}}function h(e){return"var_"+e}function p(e){for(var t={},n=0;n0)for(var a=0;a0,"Expect some new streams to remain"),this.oldStreams=this.oldStreams.concat(this.newStreams),this.newStreams=[]),this.blocked=!t}},i.prototype._scheduleRead=function(){var e=this;e.scheduledRead||(s(function(){e.scheduledRead=!1,e._readIncoming()}),e.scheduledRead=!0)},i.prototype.pipeFrom=function(e){function t(){i.newStreams.push(e),i._scheduleRead()}function n(){e.removeListener("readable",t),e.removeListener("error",n),e.removeListener("end",n),e.removeListener("unpipeFrom",r)}function r(e){e===i&&n()}var i=this;e.on("unpipeFrom",r),e.on("end",n),e.on("error",n),e.on("readable",t)},i.prototype.unpipeFrom=function(e){e.emit("unpipeFrom",this)},e.exports.Mux=i}).call(t,n(39).setImmediate,n(38))},function(e,t,n){function r(){i.call(this)}e.exports=r;var i=n(89).EventEmitter,o=n(86);o(r,i),r.Readable=n(90),r.Writable=n(100),r.Duplex=n(101),r.Transform=n(102),r.PassThrough=n(103),r.Stream=r,r.prototype.pipe=function(e,t){function n(t){e.writable&&!1===e.write(t)&&c.pause&&c.pause()}function r(){c.readable&&c.resume&&c.resume()}function o(){l||(l=!0,e.end())}function s(){l||(l=!0,"function"==typeof e.destroy&&e.destroy())}function a(e){if(u(),0===i.listenerCount(this,"error"))throw e}function u(){c.removeListener("data",n),e.removeListener("drain",r),c.removeListener("end",o),c.removeListener("close",s),c.removeListener("error",a),e.removeListener("error",a),c.removeListener("end",u),c.removeListener("close",u),e.removeListener("close",u)}var c=this;c.on("data",n),e.on("drain",r),e._isStdio||t&&t.end===!1||(c.on("end",o),c.on("close",s));var l=!1;return c.on("error",a),e.on("error",a),c.on("end",u),c.on("close",u),e.on("close",u),e.emit("pipe",c),e}},function(e,t){function n(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}function r(e){return"function"==typeof e}function i(e){return"number"==typeof e}function o(e){return"object"==typeof e&&null!==e}function s(e){return void 0===e}e.exports=n,n.EventEmitter=n,n.prototype._events=void 0,n.prototype._maxListeners=void 0,n.defaultMaxListeners=10,n.prototype.setMaxListeners=function(e){if(!i(e)||e<0||isNaN(e))throw TypeError("n must be a positive number");return this._maxListeners=e,this},n.prototype.emit=function(e){var t,n,i,a,u,c;if(this._events||(this._events={}),"error"===e&&(!this._events.error||o(this._events.error)&&!this._events.error.length)){if(t=arguments[1],t instanceof Error)throw t;var l=new Error('Uncaught, unspecified "error" event. ('+t+")");throw l.context=t,l}if(n=this._events[e],s(n))return!1;if(r(n))switch(arguments.length){case 1:n.call(this);break;case 2:n.call(this,arguments[1]);break;case 3:n.call(this,arguments[1],arguments[2]);break;default:a=Array.prototype.slice.call(arguments,1),n.apply(this,a)}else if(o(n))for(a=Array.prototype.slice.call(arguments,1),c=n.slice(),i=c.length,u=0;u0&&this._events[e].length>i&&(this._events[e].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[e].length),"function"==typeof console.trace&&console.trace())),this},n.prototype.on=n.prototype.addListener,n.prototype.once=function(e,t){function n(){this.removeListener(e,n),i||(i=!0,t.apply(this,arguments))}if(!r(t))throw TypeError("listener must be a function");var i=!1;return n.listener=t,this.on(e,n),this},n.prototype.removeListener=function(e,t){var n,i,s,a;if(!r(t))throw TypeError("listener must be a function");if(!this._events||!this._events[e])return this;if(n=this._events[e],s=n.length,i=-1,n===t||r(n.listener)&&n.listener===t)delete this._events[e],this._events.removeListener&&this.emit("removeListener",e,t);else if(o(n)){for(a=s;a-- >0;)if(n[a]===t||n[a].listener&&n[a].listener===t){i=a;break}if(i<0)return this;1===n.length?(n.length=0,delete this._events[e]):n.splice(i,1),this._events.removeListener&&this.emit("removeListener",e,t)}return this},n.prototype.removeAllListeners=function(e){var t,n;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[e]&&delete this._events[e],this;if(0===arguments.length){for(t in this._events)"removeListener"!==t&&this.removeAllListeners(t);return this.removeAllListeners("removeListener"),this._events={},this}if(n=this._events[e],r(n))this.removeListener(e,n);else if(n)for(;n.length;)this.removeListener(e,n[n.length-1]);return delete this._events[e],this},n.prototype.listeners=function(e){var t;return t=this._events&&this._events[e]?r(this._events[e])?[this._events[e]]:this._events[e].slice():[]},n.prototype.listenerCount=function(e){if(this._events){var t=this._events[e];if(r(t))return 1;if(t)return t.length}return 0},n.listenerCount=function(e,t){return e.listenerCount(t)}},function(e,t,n){(function(r){t=e.exports=n(91),t.Stream=n(88),t.Readable=t,t.Writable=n(96),t.Duplex=n(95),t.Transform=n(98),t.PassThrough=n(99),r.browser||"disable"!=={NODE_ENV:"production"}.READABLE_STREAM||(e.exports=n(88))}).call(t,n(38))},[313,92,94,95,95],function(e,t){e.exports=Array.isArray||function(e){return"[object Array]"==Object.prototype.toString.call(e)}},function(e,t,n){(function(e){function n(e){return Array.isArray?Array.isArray(e):"[object Array]"===g(e)}function r(e){return"boolean"==typeof e}function i(e){return null===e}function o(e){return null==e}function s(e){return"number"==typeof e}function a(e){return"string"==typeof e}function u(e){return"symbol"==typeof e}function c(e){return void 0===e}function l(e){return"[object RegExp]"===g(e)}function f(e){return"object"==typeof e&&null!==e}function h(e){return"[object Date]"===g(e)}function p(e){return"[object Error]"===g(e)||e instanceof Error}function d(e){return"function"==typeof e}function v(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||"undefined"==typeof e}function g(e){return Object.prototype.toString.call(e)}t.isArray=n,t.isBoolean=r,t.isNull=i,t.isNullOrUndefined=o,t.isNumber=s,t.isString=a,t.isSymbol=u,t.isUndefined=c,t.isRegExp=l,t.isObject=f,t.isDate=h,t.isError=p,t.isFunction=d,t.isPrimitive=v,t.isBuffer=e.isBuffer}).call(t,n(3).Buffer)},43,[314,91,96],[315,95,95],function(e,t,n){function r(e){if(e&&!u(e))throw new Error("Unknown encoding: "+e)}function i(e){return e.toString(this.encoding)}function o(e){this.charReceived=e.length%2,this.charLength=this.charReceived?2:0}function s(e){this.charReceived=e.length%3,this.charLength=this.charReceived?3:0}var a=n(3).Buffer,u=a.isEncoding||function(e){switch(e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}},c=t.StringDecoder=function(e){switch(this.encoding=(e||"utf8").toLowerCase().replace(/[-_]/,""),r(e),this.encoding){case"utf8":this.surrogateSize=3; -break;case"ucs2":case"utf16le":this.surrogateSize=2,this.detectIncompleteChar=o;break;case"base64":this.surrogateSize=3,this.detectIncompleteChar=s;break;default:return void(this.write=i)}this.charBuffer=new a(6),this.charReceived=0,this.charLength=0};c.prototype.write=function(e){for(var t="";this.charLength;){var n=e.length>=this.charLength-this.charReceived?this.charLength-this.charReceived:e.length;if(e.copy(this.charBuffer,this.charReceived,0,n),this.charReceived+=n,this.charReceived=55296&&r<=56319)){if(this.charReceived=this.charLength=0,0===e.length)return t;break}this.charLength+=this.surrogateSize,t=""}this.detectIncompleteChar(e);var i=e.length;this.charLength&&(e.copy(this.charBuffer,0,e.length-this.charReceived,i),i-=this.charReceived),t+=e.toString(this.encoding,0,i);var i=t.length-1,r=t.charCodeAt(i);if(r>=55296&&r<=56319){var o=this.surrogateSize;return this.charLength+=o,this.charReceived+=o,this.charBuffer.copy(this.charBuffer,o,0,o),e.copy(this.charBuffer,0,0,o),t.substring(0,i)}return t},c.prototype.detectIncompleteChar=function(e){for(var t=e.length>=3?3:e.length;t>0;t--){var n=e[e.length-t];if(1==t&&n>>5==6){this.charLength=2;break}if(t<=2&&n>>4==14){this.charLength=3;break}if(t<=3&&n>>3==30){this.charLength=4;break}}this.charReceived=t},c.prototype.end=function(e){var t="";if(e&&e.length&&(t=this.write(e)),this.charReceived){var n=this.charReceived,r=this.charBuffer,i=this.encoding;t+=r.slice(0,n).toString(i)}return t}},[316,95],[317,98],function(e,t,n){e.exports=n(96)},[318,95],function(e,t,n){e.exports=n(98)},[319,99],[318,105],[314,106,109],[313,107,108,105,105],92,43,[315,105,105],function(e,t,n){"use strict";function r(t,n,r){function i(){return r()?(c=0,!0):++c<2}o.call(this),this.interval=t;var s=t*e.exports.UNITS_TO_MS,a=this.emit.bind(this,"beat"),u=this.emit.bind(this,"timeout");this.sendTimer=setInterval(this.runHeartbeat.bind(this,n,a),s/2);var c=0;this.recvTimer=setInterval(this.runHeartbeat.bind(this,i,u),s)}var i=n(84).inherits,o=n(89).EventEmitter;e.exports.UNITS_TO_MS=1e3,i(r,o),e.exports.Heart=r,r.prototype.clear=function(){clearInterval(this.sendTimer),clearInterval(this.recvTimer)},r.prototype.runHeartbeat=function(e,t){e()||t()}},function(e,t,n){"use strict";var r=n(69),i=n(84).format,o=(n(84).inherits,n(76).HEARTBEAT);e.exports.closeMessage=function(e){var t=e.fields.replyCode;return i('%d (%s) with message "%s"',t,r.constant_strs[t],e.fields.replyText)},e.exports.methodName=function(e){return r.info(e).name},e.exports.inspect=function(e,t){if(e===o)return"";if(e.id){var n=r.info(e.id);return i("<%s channel:%d%s>",n.name,e.channel,t?" "+JSON.stringify(e.fields,void 0,2):"")}return i("",e.channel,e.size)}},function(e,t){"use strict";function n(e){if(e){var t=Math.ceil(e/32);this.words=new Array(t)}else this.words=[];this.wordsInUse=0}function r(e){return Math.floor(e/32)}function i(e){if(0===e)return 32;var t,n=31;return t=e<<16,0!=t&&(n-=16,e=t),t=e<<8,0!=t&&(n-=8,e=t),t=e<<4,0!=t&&(n-=4,e=t),t=e<<2,0!=t&&(n-=2,e=t),n-(e<<1>>>31)}var o=n.prototype;o.ensureSize=function(e){var t=this.words.length;t=this.wordsInUse&&(this.ensureSize(t+1),this.wordsInUse=t+1);var n=1<=this.wordsInUse)){var n=~(1<=this.wordsInUse)return!1;var n=1<=this.wordsInUse)return-1;for(var n=this.words[t]&4294967295<=this.wordsInUse)return e;for(var n=~this.words[t]&4294967295<=0.8 <4 || ^4"},dependencies:{bitsyntax:"~0.0.4","buffer-more-ints":"0.0.2","readable-stream":"1.x >=1.1.9",when:"~3.6.2"},devDependencies:{mocha:"~1",claire:"0.4.1","uglify-js":"2.4.x",istanbul:"0.1.x"},scripts:{test:"make test",prepublish:"make"},keywords:["AMQP","AMQP 0-9-1","RabbitMQ"],author:"Michael Bridgen ",license:"MIT"}},function(e,t){},function(e,t,n){"use strict";function r(e){if(!(this instanceof r))return new r(e);l.call(this),this.connection=e;var t=this;["error","close","blocked","unblocked"].forEach(function(n){e.on(n,t.emit.bind(t,n))})}function i(e){f.call(this,e),this.on("delivery",this.handleDelivery.bind(this)),this.on("cancel",this.handleCancel.bind(this))}function o(e){i.call(this,e)}var s=n(69),a=n(121),u=a.defer,c=n(84).inherits,l=n(89).EventEmitter,f=n(140).BaseChannel,h=n(140).acceptMessage,p=n(141);c(r,l),e.exports.ChannelModel=r;var d=r.prototype;d.close=function(){var e=u();return this.connection.close(function(t){null===t?e.resolve():e.reject(t)}),e.promise},c(i,f),e.exports.Channel=i,d.createChannel=function(){var e=new i(this.connection);return e.open().then(function(t){return e})};var v=i.prototype;v.rpc=function(e,t,n){var r=u();return this._rpc(e,t,n,function(e,t){null!==e?r.reject(e):r.resolve(t.fields)}),r.promise},v.open=function(){return a["try"](this.allocate.bind(this)).then(function(e){return e.rpc(s.ChannelOpen,{outOfBand:""},s.ChannelOpenOk)})},v.close=function(){var e=u();return this.closeBecause("Goodbye",s.constants.REPLY_SUCCESS,e.resolve),e.promise},v.assertQueue=function(e,t){return this.rpc(s.QueueDeclare,p.assertQueue(e,t),s.QueueDeclareOk)},v.checkQueue=function(e){return this.rpc(s.QueueDeclare,p.checkQueue(e),s.QueueDeclareOk)},v.deleteQueue=function(e,t){return this.rpc(s.QueueDelete,p.deleteQueue(e,t),s.QueueDeleteOk)},v.purgeQueue=function(e){return this.rpc(s.QueuePurge,p.purgeQueue(e),s.QueuePurgeOk)},v.bindQueue=function(e,t,n,r){return this.rpc(s.QueueBind,p.bindQueue(e,t,n,r),s.QueueBindOk)},v.unbindQueue=function(e,t,n,r){return this.rpc(s.QueueUnbind,p.unbindQueue(e,t,n,r),s.QueueUnbindOk)},v.assertExchange=function(e,t,n){return this.rpc(s.ExchangeDeclare,p.assertExchange(e,t,n),s.ExchangeDeclareOk).then(function(t){return{exchange:e}})},v.checkExchange=function(e){return this.rpc(s.ExchangeDeclare,p.checkExchange(e),s.ExchangeDeclareOk)},v.deleteExchange=function(e,t){return this.rpc(s.ExchangeDelete,p.deleteExchange(e,t),s.ExchangeDeleteOk)},v.bindExchange=function(e,t,n,r){return this.rpc(s.ExchangeBind,p.bindExchange(e,t,n,r),s.ExchangeBindOk)},v.unbindExchange=function(e,t,n,r){return this.rpc(s.ExchangeUnbind,p.unbindExchange(e,t,n,r),s.ExchangeUnbindOk)},v.publish=function(e,t,n,r){var i=p.publish(e,t,r);return this.sendMessage(i,i,n)},v.sendToQueue=function(e,t,n){return this.publish("",e,t,n)},v.consume=function(e,t,n){var r=this,i=p.consume(e,n),o=u();return this._rpc(s.BasicConsume,i,s.BasicConsumeOk,function(e,n){null===e?(r.registerConsumer(n.fields.consumerTag,t),o.resolve(n.fields)):o.reject(e)}),o.promise},v.cancel=function(e){var t=this,n=u();return this._rpc(s.BasicCancel,p.cancel(e),s.BasicCancelOk,function(r,i){null===r?(t.unregisterConsumer(e),n.resolve(i.fields)):n.reject(r)}),n.promise},v.get=function(e,t){var n=u(),r=this,i=p.get(e,t);return this.sendOrEnqueue(s.BasicGet,i,function(e,t){if(null===e)if(t.id===s.BasicGetEmpty)n.resolve(!1);else if(t.id===s.BasicGetOk){var i=t.fields;r.handleMessage=h(function(e){e.fields=i,n.resolve(e)})}else n.reject(new Error("Unexpected response to BasicGet: "+inspect(t)));else n.reject(e)}),n.promise},v.ack=function(e,t){this.sendImmediately(s.BasicAck,p.ack(e.fields.deliveryTag,t))},v.ackAll=function(){this.sendImmediately(s.BasicAck,p.ack(0,!0))},v.nack=function(e,t,n){this.sendImmediately(s.BasicNack,p.nack(e.fields.deliveryTag,t,n))},v.nackAll=function(e){this.sendImmediately(s.BasicNack,p.nack(0,!0,e))},v.reject=function(e,t){this.sendImmediately(s.BasicReject,p.reject(e.fields.deliveryTag,t))},v.prefetch=v.qos=function(e,t){return this.rpc(s.BasicQos,p.prefetch(e,t),s.BasicQosOk)},v.recover=function(){return this.rpc(s.BasicRecover,p.recover(),s.BasicRecoverOk)},c(o,i),e.exports.ConfirmChannel=o,d.createConfirmChannel=function(){var e=new o(this.connection);return e.open().then(function(t){return e.rpc(s.ConfirmSelect,{nowait:!1},s.ConfirmSelectOk)}).then(function(){return e})};var g=o.prototype;g.publish=function(e,t,n,r,i){return this.pushConfirmCallback(i),v.publish.call(this,e,t,n,r)},g.sendToQueue=function(e,t,n,r){return this.publish("",e,t,n,r)},g.waitForConfirms=function(){var e=[],t=this.unconfirmed;return t.forEach(function(n,r){if(null===n);else{var i=u();t[r]=function(e){n&&n(e),null===e?i.resolve():i.reject(e)},e.push(i.promise)}}),a.all(e)}},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(e){function t(e,t,n,r){var i=k.resolve(e);return arguments.length<2?i:i.then(t,n,r)}function r(e){return new k(e)}function i(e){return function(){for(var t=0,n=arguments.length,r=new Array(n);t>>0,c=u,l=[],f=0;f0){a.become(i),e._visitRemaining(t,f,i);break}i.visit(a,n,r)}else--c;return 0===c&&a.reject(new RangeError("any(): array must not be empty")),s}function i(t,n){function r(e){this.resolved||(l.push(e),0===--p&&(f=null,this.resolve(l)))}function i(e){this.resolved||(f.push(e),0===--o&&(l=null,this.reject(f)))}var o,s,a,u=e._defer(),c=u._handler,l=[],f=[],h=t.length>>>0,p=0;for(a=0;ap?c.reject(new RangeError("some(): array must contain at least "+n+" item(s), but had "+p)):0===p&&c.resolve(l),a=0;a2?g.call(e,h(t),arguments[2]):g.call(e,h(t))}function f(e,t){return arguments.length>2?y.call(e,h(t),arguments[2]):y.call(e,h(t))}function h(e){return function(t,n,r){return p(e,void 0,[t,n,r])}}var p=r(e),d=e.resolve,v=e.all,g=Array.prototype.reduce,y=Array.prototype.reduceRight,m=Array.prototype.slice;return e.any=n,e.some=i,e.settle=u,e.map=o,e.filter=s,e.reduce=l,e.reduceRight=f,e.prototype.spread=function(e){return this.then(v).then(function(t){return e.apply(this,t)})},e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},47,48,49,50,[310,127],52,53,54,function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(e){function t(e){throw e}function r(){}var i=n(123).setTimer,o=n(136);return function(e){function n(e){e.handled||(p.push(e),l("Potentially unhandled rejection ["+e.id+"] "+o.formatError(e.value)))}function s(e){var t=p.indexOf(e);t>=0&&(p.splice(t,1),f("Handled previous rejection ["+e.id+"] "+o.formatObject(e.value)))}function a(e,t){h.push(e,t),null===d&&(d=i(u,0))}function u(){for(d=null;h.length>0;)h.shift()(h.shift())}var c,l=r,f=r;"undefined"!=typeof console&&(c=console,l="undefined"!=typeof c.error?function(e){c.error(e)}:function(e){c.log(e)},f="undefined"!=typeof c.info?function(e){c.info(e)}:function(e){c.log(e)}),e.onPotentiallyUnhandledRejection=function(e){a(n,e)},e.onPotentiallyUnhandledRejectionHandled=function(e){a(s,e)},e.onFatalRejection=function(e){a(t,e.value)};var h=[],p=[],d=null;return e}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(){function e(e){var n="object"==typeof e&&null!==e&&e.stack?e.stack:t(e);return e instanceof Error?n:n+" (WARNING: non-Error used)"}function t(e){var t=String(e);return"[object Object]"===t&&"undefined"!=typeof JSON&&(t=n(e,t)),t}function n(e,t){try{return JSON.stringify(e)}catch(n){return t}}return{formatError:e,formatObject:t,tryStringify:n}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))}(n(44))},[311,138,139,123],function(e,t,n){var r;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(i){"use strict";r=function(){return function(e){function t(e,t){this._handler=e===b?t:n(e)}function n(e){function t(e){i.resolve(e)}function n(e){i.reject(e)}function r(e){i.notify(e)}var i=new _;try{e(t,n,r)}catch(o){n(o)}return i}function r(e){return R(e)?e:new t(b,new E(g(e)))}function i(e){return new t(b,new E(new I(e)))}function o(){return X}function s(){return new t(b,new _)}function a(e,t){var n=new _(e.receiver,e.join().context);return new t(b,n)}function u(e){return l(Q,null,e)}function c(e,t){return l(N,e,t)}function l(e,n,r){function i(t,i,s){s.resolved||f(r,o,t,e(n,i,t),s)}function o(e,t,n){l[e]=t,0===--c&&n.become(new k(l))}for(var s,a="function"==typeof n?i:o,u=new _,c=r.length>>>0,l=new Array(c),h=0;h0?t(n,o.value,i):(i.become(o),h(e,n+1,o))}else t(n,r,i)}function h(e,t,n){for(var r=t;r0||"function"!=typeof t&&i<0)return new this.constructor(b,r);var o=this._beget(),s=o._handler;return r.chain(s,r.receiver,e,t,n),o},t.prototype["catch"]=function(e){return this.then(void 0,e)},t.prototype._beget=function(){return a(this._handler,this.constructor)},t.all=u,t.race=d,t._traverse=c,t._visitRemaining=h,b.prototype.when=b.prototype.become=b.prototype.notify=b.prototype.fail=b.prototype._unreport=b.prototype._report=W,b.prototype._state=0,b.prototype.state=function(){return this._state},b.prototype.join=function(){for(var e=this;void 0!==e.handler;)e=e.handler;return e},b.prototype.chain=function(e,t,n,r,i){this.when({resolver:e,receiver:t,fulfilled:n,rejected:r,progress:i})},b.prototype.visit=function(e,t,n,r){this.chain(G,e,t,n,r)},b.prototype.fold=function(e,t,n,r){this.when(new A(e,t,n,r))},H(b,w),w.prototype.become=function(e){e.fail()};var G=new w;H(b,_),_.prototype._state=0,_.prototype.resolve=function(e){this.become(g(e))},_.prototype.reject=function(e){this.resolved||this.become(new I(e))},_.prototype.join=function(){if(!this.resolved)return this;for(var e=this;void 0!==e.handler;)if(e=e.handler,e===this)return this.handler=T();return e},_.prototype.run=function(){var e=this.consumers,t=this.join();this.consumers=void 0;for(var n=0;n0){var o=this.pending.shift();this.reply=o.reply,this.sendImmediately(o.method,o.fields)}return t(null,e)}},b.onBufferDrain=function(){this.emit("drain")},d(u,r),e.exports.BaseChannel=u,u.prototype.registerConsumer=function(e,t){this.consumers[e]=t},u.prototype.unregisterConsumer=function(e){delete this.consumers[e]},u.prototype.dispatchMessage=function(e,t){var n=e.consumerTag,r=this.consumers[n];if(r)return r(t);throw new Error("Unknown consumer: "+n)},u.prototype.handleDelivery=function(e){return this.dispatchMessage(e.fields,e)},u.prototype.handleCancel=function(e){return this.dispatchMessage(e,null)}}).call(t,n(3).Buffer)},function(e,t){"use strict";function n(e,t,n){void 0!=n&&(e[t]=n)}var r=Object.freeze({}),i={};i.assertQueue=function(e,t){e=e||"",t=t||r;var i=Object.create(t.arguments||null);return n(i,"x-expires",t.expires),n(i,"x-message-ttl",t.messageTtl),n(i,"x-dead-letter-exchange",t.deadLetterExchange),n(i,"x-dead-letter-routing-key",t.deadLetterRoutingKey),n(i,"x-max-length",t.maxLength),n(i,"x-max-priority",t.maxPriority),{queue:e,exclusive:!!t.exclusive,durable:void 0===t.durable||t.durable,autoDelete:!!t.autoDelete,arguments:i,passive:!1,ticket:0,nowait:!1}},i.checkQueue=function(e){return{queue:e,passive:!0,nowait:!1,durable:!0,autoDelete:!1,exclusive:!1,ticket:0}},i.deleteQueue=function(e,t){return t=t||r,{queue:e,ifUnused:!!t.ifUnused,ifEmpty:!!t.ifEmpty,ticket:0,nowait:!1}},i.purgeQueue=function(e){return{queue:e,ticket:0,nowait:!1}},i.bindQueue=function(e,t,n,r){return{queue:e,exchange:t,routingKey:n,arguments:r,ticket:0,nowait:!1}},i.unbindQueue=function(e,t,n,r){return{queue:e,exchange:t,routingKey:n,arguments:r,ticket:0,nowait:!1}},i.assertExchange=function(e,t,i){i=i||r;var o=Object.create(i.arguments||null);return n(o,"alternate-exchange",i.alternateExchange),{exchange:e,ticket:0,type:t,passive:!1,durable:void 0===i.durable||i.durable,autoDelete:!!i.autoDelete,internal:!!i.internal,nowait:!1,arguments:o}},i.checkExchange=function(e){return{exchange:e,passive:!0,nowait:!1,durable:!0,internal:!1,type:"",autoDelete:!1,ticket:0}},i.deleteExchange=function(e,t){return t=t||r,{exchange:e,ifUnused:!!t.ifUnused,ticket:0,nowait:!1}},i.bindExchange=function(e,t,n,r){return{source:t,destination:e,routingKey:n,arguments:r,ticket:0,nowait:!1}},i.unbindExchange=function(e,t,n,r){return{source:t,destination:e,routingKey:n,arguments:r,ticket:0,nowait:!1}},i.publish=function(e,t,i){function o(e){return void 0===e?void 0:Array.isArray(e)?e.map(String):[String(e)]}i=i||r;var s=Object.create(i.headers||null);n(s,"CC",o(i.CC)),n(s,"BCC",o(i.BCC));var a;void 0!==i.persistent?a=i.persistent?2:1:"number"==typeof i.deliveryMode?a=i.deliveryMode:i.deliveryMode&&(a=2);var u=i.expiration;return void 0!==u&&(u=u.toString()),{exchange:e,routingKey:t,mandatory:!!i.mandatory,immediate:!1,ticket:void 0,contentType:i.contentType,contentEncoding:i.contentEncoding,headers:s,deliveryMode:a,priority:i.priority,correlationId:i.correlationId,replyTo:i.replyTo,expiration:u,messageId:i.messageId,timestamp:i.timestamp,type:i.type,userId:i.userId,appId:i.appId,clusterId:void 0}},i.consume=function(e,t){t=t||r;var i=Object.create(t.arguments||null);return n(i,"x-priority",t.priority),{ticket:0,queue:e,consumerTag:t.consumerTag||"",noLocal:!!t.noLocal,noAck:!!t.noAck,exclusive:!!t.exclusive,nowait:!1,arguments:i}},i.cancel=function(e){return{consumerTag:e,nowait:!1}},i.get=function(e,t){return t=t||r,{ticket:0,queue:e,noAck:!!t.noAck}},i.ack=function(e,t){return{deliveryTag:e,multiple:!!t}},i.nack=function(e,t,n){return{deliveryTag:e,multiple:!!t,requeue:void 0===n||n}},i.reject=function(e,t){return{deliveryTag:e,requeue:void 0===t||t}},i.prefetch=function(e,t){return{prefetchCount:e||0,prefetchSize:0,global:!!t}},i.recover=function(){return{requeue:!0}},e.exports=Object.freeze(i)},function(e,t,n){(function(e){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(143),u=r(a),c=n(223),l=r(c),f=function(){function e(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};i(this,n);var t=o(this,(n.__proto__||Object.getPrototypeOf(n)).call(this));return t._connectionParams=(0,v["default"])({},b["default"].camelizeKeys(e)),t._endpointConfigs=void 0,t._endpoint=(0,v["default"])(S.endpoint,t._connectionParams.endpoint),t._deviceKey=t._connectionParams.deviceKey,t._channels=t._connectionParams.channels,t._deviceId=t._connectionParams.deviceId,t._client=t._connectionParams.client,t._secret=t._connectionParams.secret,t._host=t._connectionParams.host,t._port=t._connectionParams.port,t._vhost=t._connectionParams.vhost,t._protocol=S.protocol,t._inboxTopic=t._connectionParams.inputTopic||S.inboxTopic,t._liveStreamSuffix=S.liveStreamSuffix,t._tempQueueSuffix=S.tempQueueSuffix,t._liveStreams=[],t._tls=t._connectionParams.tls||!1,t._tlsOpts={},t._connectionParams.cert&&(t._tlsOpts.cert=p["default"].readFileSync(t._connectionParams.cert)),t._connectionParams.key&&(t._tlsOpts.key=p["default"].readFileSync(t._connectionParams.key)),t._connectionParams.passphrase&&(t._tlsOpts.passphrase=t._connectionParams.passphrase),t._connectionParams.ca&&(Array.isArray(t._connectionParams.ca)?t._tlsOpts.ca=t._connectionParams.ca.map(function(e){return p["default"].readFileSync(e)}):t._tlsOpts.ca=[p["default"].readFileSync(t._connectionParams.ca)]),t._connectionParams.pfx&&(t._tlsOpts.pfx=p["default"].readFileSync(t._connectionParams.pfx)),t._connectionParams.disableCertCheck?t._tlsOpts.rejectUnauthorized=!1:t._tlsOpts.rejectUnauthorized=!0,t._tlsOpts.secureProtocol=t._connectionParams.secureProtocol||S.tls.secureProtocol,t}return s(n,t),f(n,[{key:"getEndpointConfigs",value:function(){var e=this;return new _["default"](function(t,n){if(void 0!==e._endpointConfigs&&t(e._endpointConfigs),e._deviceId&&e._secret||e._deviceKey){var r=e._generateHostname(),i=x["default"].resolve(r,e._endpoint.deviceConfigurationsPath);if(e._deviceKey){var o={url:i,method:"get",responseType:"json",headers:{"Device-Key":e._deviceKey,"Content-Type":"application/json"}};(0,y["default"])(o).then(function(n){e._endpointConfigs=b["default"].camelizeKeys(n.data),e._connectionParams=e._endpointConfigs.connection,t(e._endpointConfigs)})["catch"](function(e){n(e)})}else e._deviceId&&e._secret&&e._host&&e._port&&e._vhost&&(e._connectionParams.protocols={},e._tls?e._connectionParams.protocols[e._protocol]={tlsPort:e._port}:e._connectionParams.protocols[e._protocol]={port:e._port},e._endpointConfigs={connection:e._connectionParams,channels:[]},t(e._endpointConfigs))}else if(e._client&&e._secret)if(e._host&&e._port&&e._vhost)e._connectionParams.protocols={},e._tls?e._connectionParams.protocols[e._protocol]={tlsPort:e._port}:e._connectionParams.protocols[e._protocol]={port:e._port},e._endpointConfigs={connection:e._connectionParams,liveStreams:[]},t(e._endpointConfigs);else{var s=e._generateHostname(),a=x["default"].resolve(s,e._endpoint.liveStreamKeyConfigurationsPath),u={url:a,method:"get",responseType:"json",headers:{"Live-Stream-Key-Client":e._client,"Live-Stream-Key-Secret":e._secret,"Content-Type":"application/json"}};(0,y["default"])(u).then(function(n){e._endpointConfigs=b["default"].camelizeKeys(n.data),e._connectionParams=e._endpointConfigs.connection,e._liveStreams=e._endpointConfigs.liveStreams||[],t(e._endpointConfigs)})["catch"](function(e){n(e)})}else n("Missing Device Key or wrong connection parameters")})}},{key:"channels",value:function(){return this._endpointConfigs.channels?(this._channels=this._endpointConfigs.channels.map(function(e){return e.name}),this._channels||[]):[]}},{key:"deviceId",value:function(){return this._deviceId=this._deviceId||this._connectionParams.deviceId,this._deviceId}},{key:"liveStreamByName",value:function(e){var t=(0,u["default"])(this._liveStreams,function(t){return t.name===e});return t.length>0?t[0].id||e:e}},{key:"liveStreamExists",value:function(e){var t=(0,u["default"])(this._liveStreams,function(t){return t.name===e});return t.length>0}},{key:"tempQueue",value:function(e,t,n){var r=n||(new Date).getTime();return r+"-"+this._connectionParams.client+"-"+(this.exchangeName(e,t)+".")+(""+this._tempQueueSuffix)}},{key:"exchangeName",value:function(e,t){return e&&t?this.liveStreamByName(e)+"."+t:""+t}},{key:"_encapsulateContent",value:function(e){var t=e;try{t=JSON.stringify(e)}catch(n){t=e}return t}},{key:"_generateHostname",value:function(){if(this._endpoint.url)return this._endpoint.url;var e=this._endpoint.host+":"+this._endpoint.port,t=this._tls?this._endpoint.secureProtocol:this._endpoint.protocol;return(0,l["default"])(e,t)||(e=t+"://"+e),e}},{key:"_parseContent",value:function(t){var n=t;e.isBuffer(n)&&(n=n.toString("utf-8"));var r=void 0;try{r=JSON.parse(n)}catch(i){r=n}return r}}]),n}(I["default"]);t["default"]=C}).call(t,n(3).Buffer)},function(e,t,n){function r(e,t){var n=a(e)?i:o;return n(e,s(t,3))}var i=n(144),o=n(145),s=n(151),a=n(17);e.exports=r},function(e,t){function n(e,t){for(var n=-1,r=e.length,i=0,o=[];++n-1}var i=n(158);e.exports=r},function(e,t,n){function r(e,t){var n=this.__data__,r=n.array;r&&(r.lengthh))return!1;var d=u.get(e);if(d)return d==t;var v=!0;for(u.set(e,t);++c=t?e:t)),e}e.exports=n},function(e,t,n){e.exports=n(226)},function(e,t,n){"use strict";function r(e){this.defaults=o.merge({},e),this.interceptors={request:new a,response:new a}}var i=n(227),o=n(228),s=n(229),a=n(238),u=n(239),c=n(240),l=n(241),f=n(233);r.prototype.request=function(e){"string"==typeof e&&(e=o.merge({url:arguments[0]},arguments[1])),e=o.merge(i,this.defaults,{method:"get"},e),e.baseURL&&!u(e.url)&&(e.url=c(e.baseURL,e.url)),e.withCredentials=e.withCredentials||this.defaults.withCredentials,e.data=f(e.data,e.headers,e.transformRequest),e.headers=o.merge(e.headers.common||{},e.headers[e.method]||{},e.headers||{}),o.forEach(["delete","get","head","post","put","patch","common"],function(t){delete e.headers[t]});var t=[s,void 0],n=Promise.resolve(e);for(this.interceptors.request.forEach(function(e){t.unshift(e.fulfilled,e.rejected)}),this.interceptors.response.forEach(function(e){t.push(e.fulfilled,e.rejected)});t.length;)n=n.then(t.shift(),t.shift());return n};var h=new r(i),p=e.exports=l(r.prototype.request,h);p.defaults=h.defaults,p.interceptors=h.interceptors,p.create=function(e){return new r(e)},p.all=function(e){return Promise.all(e)},p.spread=n(242),o.forEach(["delete","get","head"],function(e){r.prototype[e]=function(t,n){return this.request(o.merge(n||{},{method:e,url:t}))},p[e]=l(r.prototype[e],h)}),o.forEach(["post","put","patch"],function(e){r.prototype[e]=function(t,n,r){return this.request(o.merge(r||{},{method:e,url:t,data:n}))},p[e]=l(r.prototype[e],h)})},function(e,t,n){"use strict";var r=n(228),i=/^\)\]\}',?\n/,o={"Content-Type":"application/x-www-form-urlencoded"};e.exports={transformRequest:[function(e,t){return r.isFormData(e)||r.isArrayBuffer(e)||r.isStream(e)?e:r.isArrayBufferView(e)?e.buffer:!r.isObject(e)||r.isFile(e)||r.isBlob(e)?e:(r.isUndefined(t)||(r.forEach(t,function(e,n){"content-type"===n.toLowerCase()&&(t["Content-Type"]=e)}),r.isUndefined(t["Content-Type"])&&(t["Content-Type"]="application/json;charset=utf-8")), -JSON.stringify(e))}],transformResponse:[function(e){if("string"==typeof e){e=e.replace(i,"");try{e=JSON.parse(e)}catch(t){}}return e}],headers:{common:{Accept:"application/json, text/plain, */*"},patch:r.merge(o),post:r.merge(o),put:r.merge(o)},timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,validateStatus:function(e){return e>=200&&e<300}}},function(e,t){"use strict";function n(e){return"[object Array]"===b.call(e)}function r(e){return"[object ArrayBuffer]"===b.call(e)}function i(e){return"[object FormData]"===b.call(e)}function o(e){var t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer}function s(e){return"string"==typeof e}function a(e){return"number"==typeof e}function u(e){return"undefined"==typeof e}function c(e){return null!==e&&"object"==typeof e}function l(e){return"[object Date]"===b.call(e)}function f(e){return"[object File]"===b.call(e)}function h(e){return"[object Blob]"===b.call(e)}function p(e){return"[object Function]"===b.call(e)}function d(e){return c(e)&&p(e.pipe)}function v(e){return e.replace(/^\s*/,"").replace(/\s*$/,"")}function g(){return"undefined"!=typeof window&&"undefined"!=typeof document&&"function"==typeof document.createElement}function y(e,t){if(null!==e&&"undefined"!=typeof e)if("object"==typeof e||n(e)||(e=[e]),n(e))for(var r=0,i=e.length;r>8-a%1*8)){if(r=o.charCodeAt(a+=.75),r>255)throw new n;t=t<<8|r}return s}var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";n.prototype=new Error,n.prototype.code=5,n.prototype.name="InvalidCharacterError",e.exports=r},function(e,t){"use strict";e.exports=function(e,t,n){var r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(n):e(n)}},function(e,t,n){"use strict";var r=n(228);e.exports=r.isStandardBrowserEnv()?function(){return{write:function(e,t,n,i,o,s){var a=[];a.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),r.isString(i)&&a.push("path="+i),r.isString(o)&&a.push("domain="+o),s===!0&&a.push("secure"),document.cookie=a.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()},function(e,t,n){"use strict";function r(){this.handlers=[]}var i=n(228);r.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},r.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},r.prototype.forEach=function(e){i.forEach(this.handlers,function(t){null!==t&&e(t)})},e.exports=r},function(e,t){"use strict";e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},function(e,t){"use strict";e.exports=function(e,t){return e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,"")}},function(e,t){"use strict";e.exports=function(e,t){return function(){for(var n=new Array(arguments.length),r=0;r2&&void 0!==arguments[2]?arguments[2]:{};r(this,e),this.content=t.content,this.fields=t.fields,this.properties=t.properties;try{var s=this.fields.routingKey.split("."),a=i(s,2);this.senderId=a[0],this.channelName=a[1]}catch(u){console.error("Wrong routing key format")}this._receiverId=n,this._discardMine=o.discardMine||!1,this._discardFromApi=o.discardFromApi||!1}return o(e,[{key:"blackListed",value:function(){return!(!this._discardMine||this._receiverId!==this.senderId||this.fromApi())||!(!this._discardFromApi||!this.fromApi())}},{key:"fromApi",value:function(){return this.properties.headers&&this.properties.headers[s.fromApiHeader]}}]),e}();t["default"]=a},function(e,t,n){(function(e){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(247),u=r(a),c=function(){function e(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};return t=(0,f["default"])(this._connectionOpts,t),new p["default"](function(n,r){e.getEndpointConfigs().then(function(i){var o=i.connection;if(void 0!==e._mqttConnection)n(e._mqttConnection);else try{var s={host:o.host,port:e._tls?o.protocols.mqtt.tlsPort:o.protocols.mqtt.port,username:o.vhost+":"+(o.deviceId||o.client),password:o.secret,clientId:o.deviceId||o.client,connectionTimeout:t.connectionTimeout||e._connectionTimeout};e._tls&&(s=(0,f["default"])(s,e._tlsOpts));var a=v["default"].connect(s);a.on("error",function(t){e.emit("error",t),r(t)}),a.on("close",function(t){r(t),e.emit("close",t),e._mqttConnection=void 0}),e._mqttConnection=a,e.emit("connect"),n(e._mqttConnection)}catch(u){r(u)}})["catch"](function(e){r(e)})})}},{key:"isConnected",value:function(){return void 0!==this._mqttConnection}},{key:"_topicFor",value:function(e){return this.deviceId()+"/"+e}}]),n}(y["default"]);t["default"]=b}).call(t,n(3).Buffer)},function(e,t,n){function r(e){if(a(e)&&(s(e)||f(e)||c(e.splice)||o(e)||u(e)))return!e.length;if(l(e)){var t=i(e);if(t==p||t==d)return!e.size}for(var n in e)if(g.call(e,n))return!1;return!(m&&h(e).length)}var i=n(196),o=n(31),s=n(17),a=n(10),u=n(248),c=n(13),l=n(18),f=n(16),h=n(25),p="[object Map]",d="[object Set]",v=Object.prototype,g=v.hasOwnProperty,y=v.propertyIsEnumerable,m=!y.call({valueOf:1},"valueOf");e.exports=r},function(e,t,n){(function(e){var r=n(249),i=n(174),o={"function":!0,object:!0},s=o[typeof t]&&t&&!t.nodeType?t:void 0,a=o[typeof e]&&e&&!e.nodeType?e:void 0,u=a&&a.exports===s?s:void 0,c=u?i.Buffer:void 0,l=c?function(e){return e instanceof c}:r(!1);e.exports=l}).call(t,n(36)(e))},function(e,t){function n(e){return function(){return e}}e.exports=n},function(e,t,n){(function(t){"use strict";function r(e){var t;e.auth&&(t=e.auth.match(/^(.+):(.+)$/),t?(e.username=t[1],e.password=t[2]):e.username=e.auth)}function i(e,t){function n(e){return t.servers&&(e._reconnectCount&&e._reconnectCount!==t.servers.length||(e._reconnectCount=0),t.host=t.servers[e._reconnectCount].host,t.port=t.servers[e._reconnectCount].port,t.hostname=t.host,e._reconnectCount++),u[t.protocol](e,t)}if("object"!=typeof e||t||(t=e,e=null),t=t||{},e&&(t=a(s.parse(e,!0),t),t.protocol=t.protocol.replace(/\:$/,"")),r(t),t.query&&"string"==typeof t.query.clientId&&(t.clientId=t.query.clientId),t.cert&&t.key){if(!t.protocol)throw new Error("Missing secure protocol key");if(-1===["mqtts","wss"].indexOf(t.protocol))switch(t.protocol){case"mqtt":t.protocol="mqtts";break;case"ws":t.protocol="wss";break;default:throw new Error('Unknown protocol for secure conenction: "'+t.protocol+'"!')}}if(u[t.protocol]||(t.protocol=c.filter(function(e){return"function"==typeof u[e]})[0]),!1===t.clean&&!t.clientId)throw new Error("Missing clientId for unclean clients");return new o(n,t)}var o=n(251),s=n(62),a=n(283),u={},c=[];"browser"!==t.title&&(u.mqtt=n(284),u.tcp=n(284),u.ssl=n(286),u.tls=n(286),u.mqtts=n(286)),u.ws=n(288),u.wss=n(288),c=["mqtt","mqtts","ws","wss"],e.exports=i,e.exports.connect=i}).call(t,n(38))},function(e,t,n){(function(t,r){"use strict";function i(){return"mqttjs_"+Math.random().toString(16).substr(2,8)}function o(e,t,n){try{var r=h.generate(t);!e.stream.write(r)&&n?e.stream.once("drain",n):n&&n()}catch(i){n?n(i):e.emit("error",i)}}function s(e,t,n){e.outgoingStore.put(t,function(r){return r?n&&n(r):void o(e,t,n)})}function a(){}function u(e,t){var n,r=this;if(!(this instanceof u))return new u(e,t);this.options=t||{};for(n in y)"undefined"==typeof this.options[n]?this.options[n]=y[n]:this.options[n]=t[n];this.options.clientId=this.options.clientId||i(),this.streamBuilder=e,this.outgoingStore=this.options.outgoingStore||new l,this.incomingStore=this.options.incomingStore||new l,this.queueQoSZero=null==this.options.queueQoSZero||this.options.queueQoSZero,this.pingTimer=null,this.connected=!1,this.disconnecting=!1,this.queue=[],this.connackTimer=null,this.reconnectTimer=null,this.nextId=Math.floor(65535*Math.random()),this.outgoing={},this.on("connect",function(){this.connected=!0;var e=null;e=this.outgoingStore.createStream(),e.once("readable",function(){function t(){var n,i=e.read(1);i&&(!r.disconnecting&&!r.reconnectTimer&&00)if(t.ended&&!i){var a=new Error("stream.push() after EOF");e.emit("error",a)}else if(t.endEmitted&&i){var a=new Error("stream.unshift() after end event");e.emit("error",a)}else!t.decoder||i||r||(n=t.decoder.write(n)),t.length+=t.objectMode?1:n.length,i?t.buffer.unshift(n):(t.reading=!1,t.buffer.push(n)),t.needReadable&&f(e),p(e,t);else i||(t.reading=!1);return s(t)}function s(e){return!e.ended&&(e.needReadable||e.length=j)e=j;else{e--;for(var t=1;t<32;t<<=1)e|=e>>t;e++}return e}function u(e,t){return 0===t.length&&t.ended?0:t.objectMode?0===e?0:1:null===e||isNaN(e)?t.flowing&&t.buffer.length?t.buffer[0].length:t.length:e<=0?0:(e>t.highWaterMark&&(t.highWaterMark=a(e)),e>t.length?t.ended?t.length:(t.needReadable=!0,0):e)}function c(e,t){var n=null;return k.isBuffer(t)||"string"==typeof t||null===t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function l(e,t){if(t.decoder&&!t.ended){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,t.length>0?f(e):w(e)}function f(e){var n=e._readableState;n.needReadable=!1,n.emittedReadable||(n.emittedReadable=!0,n.sync?t.nextTick(function(){h(e)}):h(e))}function h(e){e.emit("readable")}function p(e,n){n.readingMore||(n.readingMore=!0,t.nextTick(function(){d(e,n)}))}function d(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length0)return;return 0===r.pipesCount?(r.flowing=!1,void(I.listenerCount(e,"data")>0&&m(e))):void(r.ranOut=!0)}function y(){this._readableState.ranOut&&(this._readableState.ranOut=!1,g(this))}function m(e,n){var r=e._readableState;if(r.flowing)throw new Error("Cannot switch to old mode now.");var i=n||!1,o=!1;e.readable=!0,e.pipe=S.prototype.pipe,e.on=e.addListener=S.prototype.on,e.on("readable",function(){o=!0;for(var t;!i&&null!==(t=e.read());)e.emit("data",t);null===t&&(o=!1,e._readableState.needReadable=!0)}),e.pause=function(){i=!0,this.emit("pause")},e.resume=function(){i=!1,o?t.nextTick(function(){e.emit("readable")}):this.read(0),this.emit("resume")},e.emit("readable")}function b(e,t){var n,r=t.buffer,i=t.length,o=!!t.decoder,s=!!t.objectMode;if(0===r.length)return null;if(0===i)n=null;else if(s)n=r.shift();else if(!e||e>=i)n=o?r.join(""):k.concat(r,i),r.length=0;else if(e0)throw new Error("endReadable called on non-empty stream");!n.endEmitted&&n.calledRead&&(n.ended=!0,t.nextTick(function(){n.endEmitted||0!==n.length||(n.endEmitted=!0,e.readable=!1,e.emit("end"))}))}function _(e,t){for(var n=0,r=e.length;n0)&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return f(this),null;if(e=u(e,t),0===e&&t.ended)return n=null,t.length>0&&t.decoder&&(n=b(e,t), -t.length-=n.length),0===t.length&&w(this),n;var i=t.needReadable;return t.length-e<=t.highWaterMark&&(i=!0),(t.ended||t.reading)&&(i=!1),i&&(t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1),i&&!t.reading&&(e=u(r,t)),n=e>0?b(e,t):null,null===n&&(t.needReadable=!0,e=0),t.length-=e,0!==t.length||t.ended||(t.needReadable=!0),t.ended&&!t.endEmitted&&0===t.length&&w(this),n},i.prototype._read=function(e){this.emit("error",new Error("not implemented"))},i.prototype.pipe=function(e,n){function r(e){e===l&&o()}function i(){e.end()}function o(){e.removeListener("close",a),e.removeListener("finish",u),e.removeListener("drain",d),e.removeListener("error",s),e.removeListener("unpipe",r),l.removeListener("end",i),l.removeListener("end",o),e._writableState&&!e._writableState.needDrain||d()}function s(t){c(),e.removeListener("error",s),0===I.listenerCount(e,"error")&&e.emit("error",t)}function a(){e.removeListener("finish",u),c()}function u(){e.removeListener("close",a),c()}function c(){l.unpipe(e)}var l=this,f=this._readableState;switch(f.pipesCount){case 0:f.pipes=e;break;case 1:f.pipes=[f.pipes,e];break;default:f.pipes.push(e)}f.pipesCount+=1;var h=(!n||n.end!==!1)&&e!==t.stdout&&e!==t.stderr,p=h?i:o;f.endEmitted?t.nextTick(p):l.once("end",p),e.on("unpipe",r);var d=v(l);return e.on("drain",d),e._events&&e._events.error?x(e._events.error)?e._events.error.unshift(s):e._events.error=[s,e._events.error]:e.on("error",s),e.once("close",a),e.once("finish",u),e.emit("pipe",l),f.flowing||(this.on("readable",y),f.flowing=!0,t.nextTick(function(){g(l)})),e},i.prototype.unpipe=function(e){var t=this._readableState;if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,this.removeListener("readable",y),t.flowing=!1,e&&e.emit("unpipe",this),this);if(!e){var n=t.pipes,r=t.pipesCount;t.pipes=null,t.pipesCount=0,this.removeListener("readable",y),t.flowing=!1;for(var i=0;i0)&&this[this._states[this._stateCounter]]()&&!this.error;)this._stateCounter++,this._stateCounter>=this._states.length&&(this._stateCounter=0);return this._list.length},r.prototype._parseHeader=function(){var e=this._list.readUInt8(0);return this.packet.cmd=u.types[e>>u.CMD_SHIFT],this.packet.retain=0!==(e&u.RETAIN_MASK),this.packet.qos=e>>u.QOS_SHIFT&u.QOS_MASK,this.packet.dup=0!==(e&u.DUP_MASK),this._list.consume(1),!0},r.prototype._parseLength=function(){for(var e,t=0,n=1,r=0,i=!0;t<5&&(e=this._list.readUInt8(t++),r+=n*(e&u.LENGTH_MASK),n*=128,0!==(e&u.LENGTH_FIN_MASK));)if(this._list.length<=t){i=!1;break}return i&&(this.packet.length=r,this._list.consume(t)),i},r.prototype._parsePayload=function(){var e=!1;if(0===this.packet.length||this._list.length>=this.packet.length){switch(this._pos=0,this.packet.cmd){case"connect":this._parseConnect();break;case"connack":this._parseConnack();break;case"publish":this._parsePublish();break;case"puback":case"pubrec":case"pubrel":case"pubcomp":this._parseMessageId();break;case"subscribe":this._parseSubscribe();break;case"suback":this._parseSuback();break;case"unsubscribe":this._parseUnsubscribe();break;case"unsuback":this._parseUnsuback();break;case"pingreq":case"pingresp":case"disconnect":break;default:this._emitError(new Error("not supported"))}e=!0}return e},r.prototype._parseConnect=function(){var e,t,n,r,i,o,s={},a=this.packet;if(e=this._parseString(),null===e)return this._emitError(new Error("cannot parse protocol id"));if("MQTT"!=e&&"MQIsdp"!=e)return this._emitError(new Error("invalid protocol id"));if(a.protocolId=e,this._pos>=this._list.length)return this._emitError(new Error("packet too short"));if(a.protocolVersion=this._list.readUInt8(this._pos),3!=a.protocolVersion&&4!=a.protocolVersion)return this._emitError(new Error("invalid protocol version"));if(this._pos++,this._pos>=this._list.length)return this._emitError(new Error("packet too short"));if(s.username=this._list.readUInt8(this._pos)&u.USERNAME_MASK,s.password=this._list.readUInt8(this._pos)&u.PASSWORD_MASK,s.will=this._list.readUInt8(this._pos)&u.WILL_FLAG_MASK,s.will&&(a.will={},a.will.retain=0!==(this._list.readUInt8(this._pos)&u.WILL_RETAIN_MASK),a.will.qos=(this._list.readUInt8(this._pos)&u.WILL_QOS_MASK)>>u.WILL_QOS_SHIFT),a.clean=0!==(this._list.readUInt8(this._pos)&u.CLEAN_SESSION_MASK),this._pos++,a.keepalive=this._parseNum(),a.keepalive===-1)return this._emitError(new Error("packet too short"));if(t=this._parseString(),null===t)return this._emitError(new Error("packet too short"));if(a.clientId=t,s.will){if(n=this._parseString(),null===n)return this._emitError(new Error("cannot parse will topic"));if(a.will.topic=n,r=this._parseBuffer(),null===r)return this._emitError(new Error("cannot parse will payload"));a.will.payload=r}if(s.username){if(o=this._parseString(),null===o)return this._emitError(new Error("cannot parse username"));a.username=o}if(s.password){if(i=this._parseBuffer(),null===i)return this._emitError(new Error("cannot parse username"));a.password=i}return a},r.prototype._parseConnack=function(){var e=this.packet;return this._list.length<2?null:(e.sessionPresent=!!(this._list.readUInt8(this._pos++)&u.SESSIONPRESENT_MASK),e.returnCode=this._list.readUInt8(this._pos),e.returnCode===-1?this._emitError(new Error("cannot parse return code")):void 0)},r.prototype._parsePublish=function(){var e=this.packet;return e.topic=this._parseString(),null===e.topic?this._emitError(new Error("cannot parse topic")):void(e.qos>0&&!this._parseMessageId()||(e.payload=this._list.slice(this._pos,e.length)))},r.prototype._parseSubscribe=function(){var e,t,n=this.packet;if(1!=n.qos)return this._emitError(new Error("wrong subscribe header"));if(n.subscriptions=[],this._parseMessageId())for(;this._posthis._list.length||r>this.packet.length?null:(t=this._list.toString("utf8",this._pos,r),this._pos+=n,t)},r.prototype._parseBuffer=function(){var e,t=this._parseNum(),n=t+this._pos;return t===-1||n>this._list.length||n>this.packet.length?null:(e=this._list.slice(this._pos,n),this._pos+=t,e)},r.prototype._parseNum=function(){if(this._list.length-this._pos<2)return-1;var e=this._list.readUInt16BE(this._pos);return this._pos+=2,e},r.prototype._newPacket=function(){return this.packet&&(this._list.consume(this.packet.length),this.emit("packet",this.packet)),this.packet=new a,!0},r.prototype._emitError=function(e){this.error=e,this.emit("error",e)},e.exports=r},function(e,t,n){function r(e){if(!(this instanceof r))return new r(e);if(this._bufs=[],this.length=0,"function"==typeof e){this._callback=e;var t=function(e){this._callback&&(this._callback(e),this._callback=null)}.bind(this);this.on("pipe",function(e){e.on("error",t)}),this.on("unpipe",function(e){e.removeListener("error",t)})}else this.append(e);i.call(this)}var i=n(266),o=n(84),s=n(271).Buffer;o.inherits(r,i),r.prototype._offset=function(e){var t,n=0,r=0;if(0===e)return[0,0];for(;rthis.length)&&(r=this.length),n>=this.length)return e||s.alloc(0);if(r<=0)return e||s.alloc(0);var i,o,a=!!e,u=this._offset(n),c=r-n,l=c,f=a&&t||0,h=u[1];if(0===n&&r==this.length){if(!a)return 1===this._bufs.length?this._bufs[0]:s.concat(this._bufs,this.length);for(o=0;oi)){this._bufs[o].copy(e,f,h,h+l);break}this._bufs[o].copy(e,f,h),f+=i,l-=i,h&&(h=0)}return e},r.prototype.shallowSlice=function(e,t){e=e||0,t=t||this.length,e<0&&(e+=this.length),t<0&&(t+=this.length);var n=this._offset(e),i=this._offset(t),o=this._bufs.slice(n[0],i[0]+1);return 0==i[1]?o.pop():o[o.length-1]=o[o.length-1].slice(0,i[1]),0!=n[1]&&(o[0]=o[0].slice(n[1])),new r(o)},r.prototype.toString=function(e,t,n){return this.slice(t,n).toString(e)},r.prototype.consume=function(e){for(;this._bufs.length;){if(!(e>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(e),this.length-=e;break}e-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},r.prototype.duplicate=function(){for(var e=0,t=new r;e0?("string"==typeof t||s.objectMode||Object.getPrototypeOf(t)===F.prototype||(t=i(t)),r?s.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):l(e,s,t,!0):s.ended?e.emit("error",new Error("stream.push() after EOF")):(s.reading=!1,s.decoder&&!n?(t=s.decoder.write(t),s.objectMode||0!==t.length?l(e,s,t,!1):m(e,s)):l(e,s,t,!1))):r||(s.reading=!1)}return h(s)}function l(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&g(e)),m(e,t)}function f(e,t){var n;return o(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function h(e){return!e.ended&&(e.needReadable||e.length=K?e=K:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function d(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!==e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=p(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function v(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,g(e)}}function g(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(q("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?O.nextTick(y,e):y(e))}function y(e){q("emit readable"),e.emit("readable"),k(e)}function m(e,t){t.readingMore||(t.readingMore=!0,O.nextTick(b,e,t))}function b(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=S(e,t.buffer,t.decoder),n}function S(e,t,n){var r;return eo.length?o.length:e;if(i+=s===o.length?o:o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function T(e,t){var n=F.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function j(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,O.nextTick(U,t,e))}function U(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function B(e,t){for(var n=0,r=e.length;n=t.highWaterMark||t.ended))return q("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?j(this):g(this),null;if(e=d(e,t),0===e&&t.ended)return 0===t.length&&j(this),null;var r=t.needReadable;q("need readable",r),(0===t.length||t.length-e0?I(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&j(this)),null!==i&&this.emit("data",i),i},u.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},u.prototype.pipe=function(e,t){function n(e,t){q("onunpipe"),e===h&&t&&t.hasUnpiped===!1&&(t.hasUnpiped=!0,o())}function i(){q("onend"),e.end()}function o(){q("cleanup"),e.removeListener("close",c),e.removeListener("finish",l),e.removeListener("drain",g),e.removeListener("error",u),e.removeListener("unpipe",n),h.removeListener("end",i),h.removeListener("end",f),h.removeListener("data",a),y=!0,!p.awaitDrain||e._writableState&&!e._writableState.needDrain||g()}function a(t){q("ondata"),m=!1;var n=e.write(t);!1!==n||m||((1===p.pipesCount&&p.pipes===e||p.pipesCount>1&&B(p.pipes,e)!==-1)&&!y&&(q("false write response, pause",h._readableState.awaitDrain),h._readableState.awaitDrain++,m=!0),h.pause())}function u(t){q("onerror",t),f(),e.removeListener("error",u),0===M(e,"error")&&e.emit("error",t)}function c(){e.removeListener("finish",l),f()}function l(){q("onfinish"),e.removeListener("close",c),f()}function f(){q("unpipe"),h.unpipe(e)}var h=this,p=this._readableState;switch(p.pipesCount){case 0:p.pipes=e;break;case 1:p.pipes=[p.pipes,e];break;default:p.pipes.push(e)}p.pipesCount+=1,q("pipe count=%d opts=%j",p.pipesCount,t);var d=(!t||t.end!==!1)&&e!==r.stdout&&e!==r.stderr,v=d?i:f;p.endEmitted?O.nextTick(v):h.once("end",v),e.on("unpipe",n);var g=w(h);e.on("drain",g);var y=!1,m=!1;return h.on("data",a),s(e,"error",u),e.once("close",c),e.once("finish",l),e.emit("pipe",h),p.flowing||(q("pipe resume"),h.resume()),e},u.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o0?this.tail.next=t:this.head=t,this.tail=t,++this.length},e.prototype.unshift=function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length},e.prototype.shift=function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}},e.prototype.clear=function(){this.head=this.tail=null,this.length=0},e.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,n=""+t.data;t=t.next;)n+=e+t.data;return n},e.prototype.concat=function(e){if(0===this.length)return o.alloc(0);if(1===this.length)return this.head.data;for(var t=o.allocUnsafe(e>>>0),n=this.head,r=0;n;)i(n.data,t,r),r+=n.data.length,n=n.next;return t},e}(),s&&s.inspect&&s.inspect.custom&&(e.exports.prototype[s.inspect.custom]=function(){var e=s.inspect({length:this.length});return this.constructor.name+" "+e})},43,function(e,t,n){"use strict";function r(e,t){var n=this,r=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return r||i?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||s.nextTick(o,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(s.nextTick(o,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function i(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function o(e,t){e.emit("error",t)}var s=n(268);e.exports={destroy:r,undestroy:i}},function(e,t,n){"use strict";function r(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function i(e){var t=r(e);if("string"!=typeof t&&(m.isEncoding===b||!b(e)))throw new Error("Unknown encoding: "+e);return t||e}function o(e){this.encoding=i(e);var t;switch(this.encoding){case"utf16le":this.text=h,this.end=p,t=4;break;case"utf8":this.fillLast=c,t=4;break;case"base64":this.text=d,this.end=v,t=3;break;default:return this.write=g,void(this.end=y)}this.lastNeed=0,this.lastTotal=0,this.lastChar=m.allocUnsafe(t)}function s(e){return e<=127?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function a(e,t,n){var r=t.length-1;if(r=0?(i>0&&(e.lastNeed=i-1),i):--r=0?(i>0&&(e.lastNeed=i-2),i):--r=0?(i>0&&(2===i?i=0:e.lastNeed=i-3),i):0))}function u(e,t,n){if(128!==(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!==(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!==(192&t[2]))return e.lastNeed=2,"�"}}function c(e){var t=this.lastTotal-this.lastNeed,n=u(this,e,t);return void 0!==n?n:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function l(e,t){var n=a(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=n;var r=e.length-(n-this.lastNeed);return e.copy(this.lastChar,0,r),e.toString("utf8",t,r)}function f(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t}function h(e,t){if((e.length-t)%2===0){var n=e.toString("utf16le",t);if(n){var r=n.charCodeAt(n.length-1);if(r>=55296&&r<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],n.slice(0,-1)}return n}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function p(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var n=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,n)}return t}function d(e,t){var n=(e.length-t)%3;return 0===n?e.toString("base64",t):(this.lastNeed=3-n,this.lastTotal=3,1===n?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-n))}function v(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function g(e){return e.toString(this.encoding)}function y(e){return e&&e.length?this.write(e):""}var m=n(271).Buffer,b=m.isEncoding||function(e){switch(e=""+e,e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};t.StringDecoder=o,o.prototype.write=function(e){if(0===e.length)return"";var t,n;if(this.lastNeed){if(t=this.fillLast(e),void 0===t)return"";n=this.lastNeed,this.lastNeed=0}else n=0;return n-1?r:T.nextTick;l.WritableState=c;var B=n(93);B.inherits=n(86);var O={deprecate:n(278)},A=n(270),R=n(271).Buffer,M=i.Uint8Array||function(){},L=n(275);B.inherits(l,A),c.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(c.prototype,"buffer",{get:O.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}();var F;"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(F=Function.prototype[Symbol.hasInstance],Object.defineProperty(l,Symbol.hasInstance,{value:function(e){return!!F.call(this,e)||this===l&&(e&&e._writableState instanceof c)}})):F=function(e){return e instanceof this},l.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},l.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&a(e);return o&&!R.isBuffer(e)&&(e=s(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=u),r.ended?f(this,n):(o||h(this,r,e,n))&&(r.pendingcb++,i=d(this,r,o,e,t,n)),i},l.prototype.cork=function(){var e=this._writableState;e.corked++},l.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||_(this,e))},l.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(l.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),l.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},l.prototype._writev=null,l.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||S(this,r,n)},Object.defineProperty(l.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),l.prototype.destroy=L.destroy,l.prototype._undestroy=L.undestroy,l.prototype._destroy=function(e,t){this.end(),t(e)}}).call(t,n(38),n(39).setImmediate,function(){return this}())},function(e,t){(function(t){function n(e,t){function n(){if(!i){if(r("throwDeprecation"))throw new Error(t);r("traceDeprecation")?console.trace(t):console.warn(t),i=!0}return e.apply(this,arguments)}if(r("noDeprecation"))return e;var i=!1;return n}function r(e){try{if(!t.localStorage)return!1}catch(n){return!1}var r=t.localStorage[e];return null!=r&&"true"===String(r).toLowerCase()}e.exports=n}).call(t,function(){return this}())},function(e,t){function n(){this.cmd=null,this.retain=!1,this.qos=0,this.dup=!1,this.length=-1,this.topic=null,this.payload=null}e.exports=n},function(e,t){e.exports.types={0:"reserved",1:"connect",2:"connack",3:"publish",4:"puback",5:"pubrec",6:"pubrel",7:"pubcomp",8:"subscribe",9:"suback",10:"unsubscribe",11:"unsuback",12:"pingreq",13:"pingresp",14:"disconnect",15:"reserved"},e.exports.codes={};for(var n in e.exports.types){var r=e.exports.types[n];e.exports.codes[r]=n}e.exports.CMD_SHIFT=4,e.exports.CMD_MASK=240,e.exports.DUP_MASK=8,e.exports.QOS_MASK=3,e.exports.QOS_SHIFT=1,e.exports.RETAIN_MASK=1,e.exports.LENGTH_MASK=127,e.exports.LENGTH_FIN_MASK=128,e.exports.SESSIONPRESENT_MASK=1,e.exports.USERNAME_MASK=128,e.exports.PASSWORD_MASK=64,e.exports.WILL_RETAIN_MASK=32,e.exports.WILL_QOS_MASK=24,e.exports.WILL_QOS_SHIFT=3,e.exports.WILL_FLAG_MASK=4,e.exports.CLEAN_SESSION_MASK=2},function(e,t,n){(function(t){"use strict";function r(e){switch(e.cmd){case"connect":return i(e);case"connack":return o(e);case"publish":return s(e);case"puback":case"pubrec":case"pubrel":case"pubcomp":case"unsuback":return a(e);case"subscribe":return u(e);case"suback":return c(e);case"unsubscribe":return l(e);case"pingreq":case"pingresp":case"disconnect":return f(e);default:throw new Error("unknown command")}}function i(e){var e=e||{},n=e.protocolId||"MQTT",r=e.protocolVersion||4,i=e.will,o=e.clean,s=e.keepalive||0,a=e.clientId||"",u=e.username,c=e.password;void 0===o&&(o=!0);var l=0;if(!n||"string"!=typeof n&&!t.isBuffer(n))throw new Error("Invalid protocol id");if(l+=n.length+2,!r||"number"!=typeof r||r>255||r<0)throw new Error("Invalid protocol version");if(l+=1,"string"!=typeof a&&!t.isBuffer(a)||!a&&4!=r||!a&&!o){if(r<4)throw new Error("clientId must be supplied before 3.1.1");if(0==o)throw new Error("clientId must be given if cleanSession set to 0")}else l+=a.length+2;if("number"!=typeof s||s<0||s>65535)throw new Error("Invalid keepalive");if(l+=2,l+=1,i){if("object"!=typeof i)throw new Error("Invalid will");if(!i.topic||"string"!=typeof i.topic)throw new Error("Invalid will topic");if(l+=t.byteLength(i.topic)+2,i.payload&&i.payload){if(!(i.payload.length>=0))throw new Error("Invalid will payload");l+="string"==typeof i.payload?t.byteLength(i.payload)+2:i.payload.length+2}else l+=2}if(u){if(!u.length)throw new Error("Invalid username");l+=t.byteLength(u)+2}if(c){if(!c.length)throw new Error("Invalid password");l+=b(c)+2}var f=new t(1+h(l)+l),v=0;f.writeUInt8(w.codes.connect<0&&(l+=y(c,l,a)),t.isBuffer(s)?g(c,l,s):v(c,l,s),c}function a(e){var e=e||{},n=e.cmd||"puback",r=e.messageId,i=e.dup&&"pubrel"===n?w.DUP_MASK:0,o=0;if("pubrel"===n&&(o=1),"number"!=typeof r)throw new Error("Invalid message id");var s=new t(4),a=0;return s[a++]=w.codes[n]<=0&&e<128?1:e>=128&&e<16384?2:e>=16384&&e<2097152?3:e>=2097152&&e<268435456?4:0}function p(e,t,n){var r=0,i=t;do r=n%128|0,n=n/128|0,n>0&&(r=128|r),e.writeUInt8(r,t++,!0);while(n>0);return t-i}function d(e,n,r){var i=t.byteLength(r);return y(e,n,i),v(e,n+2,r),i+2}function v(e,t,n){e.write(n,t)}function g(e,t,n){return n.copy(e,t),n.length}function y(e,t,n){return e.writeUInt8(n>>8,t,!0),e.writeUInt8(255&n,t+1,!0),2}function m(e,t,n){var r=0;return n&&"string"==typeof n?r+=d(e,t+r,n):n?(r+=y(e,t+r,n.length),r+=g(e,t+r,n)):r+=y(e,t+r,0),r}function b(e){return t.isBuffer(e)?e.length:t.byteLength(e)}var w=n(280),_=new t(0);e.exports=r}).call(t,n(3).Buffer)},function(e,t){"use strict";function n(e,t,n){var r=this;this._callback=e,this._args=n,this._interval=setInterval(e,t,this._args),this.reschedule=function(e){e||(e=r._interval),r._interval&&clearInterval(r._interval),r._interval=setInterval(r._callback,e,r._args)},this.clear=function(){r._interval&&(clearInterval(r._interval),r._interval=void 0)},this.destroy=function(){r._interval&&clearInterval(r._interval),r._callback=void 0,r._interval=void 0,r._args=void 0}}function r(){if("function"!=typeof arguments[0])throw new Error("callback needed");if("number"!=typeof arguments[1])throw new Error("interval needed");var e;if(arguments.length>0){e=new Array(arguments.length-2);for(var t=0;tx)return void setTimeout(l,k,e,t,n);I&&"string"==typeof e&&(e=new i(e,"utf8"));try{m.send(e)}catch(r){return n(r)}n()}function f(e){m.close(),e()}function h(){y.setReadable(E),y.setWritable(E),y.emit("connect")}function p(){y.end(),y.destroy()}function d(e){y.destroy(e)}function v(e){var t=e.data;t=new i(t instanceof ArrayBuffer?new Uint8Array(t):t),E.push(t)}function g(){m.close()}var y,m,b="browser"===t.title,w=!!r.WebSocket,_=b?l:c,E=s.obj(_,f);n&&!Array.isArray(n)&&"object"==typeof n&&(o=n,n=null,("string"==typeof o.protocol||Array.isArray(o.protocol))&&(n=o.protocol)),o||(o={});var x=o.browserBufferSize||524288,k=o.browserBufferTimeout||1e3;"object"==typeof e?m=e:(m=w&&b?new u(e,n):new u(e,n,o),m.binaryType="arraybuffer"),m.readyState===u.OPEN?y=E:(y=a.obj(),m.onopen=h),y.socket=m,m.onclose=p,m.onerror=d,m.onmessage=v,E.on("close",g);var I=o.binary||void 0===o.binary;return y}var s=n(290),a=n(295),u=n(297);e.exports=o}).call(t,n(38),function(){return this}(),n(3).Buffer)},function(e,t,n){(function(t){function r(e){s.call(this,e),this._destroyed=!1}function i(e,t,n){n(null,e)}function o(e){return function(t,n,r){return"function"==typeof t&&(r=n,n=t,t={}),"function"!=typeof n&&(n=i),"function"!=typeof r&&(r=null),e(t,n,r)}}var s=n(291),a=n(84).inherits,u=n(283);a(r,s),r.prototype.destroy=function(e){if(!this._destroyed){this._destroyed=!0;var n=this;t.nextTick(function(){e&&n.emit("error",e),n.emit("close")})}},e.exports=o(function(e,t,n){var i=new r(e);return i._transform=t,n&&(i._flush=n),i}),e.exports.ctor=o(function(e,t,n){function i(t){return this instanceof i?(this.options=u(e,t),void r.call(this,this.options)):new i(t)}return a(i,r),i.prototype._transform=t,n&&(i.prototype._flush=n),i}),e.exports.obj=o(function(e,t,n){var i=new r(u({objectMode:!0,highWaterMark:16},e));return i._transform=t,n&&(i._flush=n),i})}).call(t,n(38))},function(e,t,n){e.exports=n(292).Transform},function(e,t,n){t=e.exports=n(269),t.Stream=t,t.Readable=t,t.Writable=n(277),t.Duplex=n(267),t.Transform=n(293),t.PassThrough=n(294)},function(e,t,n){"use strict";function r(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length0&&void 0!==arguments[0]?arguments[0]:{};return n=(0,h["default"])(this._connectionOpts,n),new d["default"](function(n,r){t.getEndpointConfigs().then(function(i){var o=i.connection;if(void 0!==t._stompConnection)n(t._stompConnection);else try{var s=void 0;if("object"===("undefined"==typeof e?"undefined":c(e))&&""+e=="[object process]")s=t._tls?g["default"].overTCP(o.host,o.protocols.stomp.tlsPort,t._tlsOpts):g["default"].overTCP(o.host,o.protocols.stomp.port);else{var a=t._tls?t._webSocketOpts.tls.protocol:t._webSocketOpts.protocol,u=t._tls?o.protocols.webStomp.tlsPort:o.protocols.webStomp.port,l=a+"://"+o.host+":"+u+"/"+t._webSocketOpts.endpoint,f=new WebSocket(l);s=g["default"].over(f),s.heartbeat.outgoing=1e4,s.heartbeat.incoming=1e4,s.debug=null}var p=(0,h["default"])(t._connectionHeaders,{login:o.deviceId||o.client,passcode:o.secret,host:o.vhost});s.connect(p,function(){t._stompConnection=s,t.emit("connect"),n(t._stompConnection)},function(e){t.emit("error",e),t._stompConnection=void 0,r(e)})}catch(d){r(d)}})["catch"](function(e){r(e)})})}},{key:"isConnected",value:function(){return void 0!==this._stompConnection}},{key:"_subcriptionFor",value:function(e,t){return"/"+e+"/"+this.deviceId()+"."+t}},{key:"_destinationFor",value:function(e,t){return"/"+e+"/"+this.deviceId()+"/"+this.deviceId()+"."+t}},{key:"_autoAck",value:function(e){if(e)switch((0,u["default"])(_[this._protocol].ackTypes,e)||console.error("Wrong acknowledge type"),e){case"client":return!1;default:return!0}return!1}}]),n}(m["default"]);t["default"]=E}).call(t,n(38))},function(e,t,n){var r=n(300),i=n(301);e.exports=r.Stomp,e.exports.overTCP=i.overTCP,e.exports.overWS=i.overWS},function(e,t){(function(){var e,n,r,i,o={}.hasOwnProperty,s=[].slice;e={LF:"\n",NULL:"\0"},r=function(){function t(e,t,n){this.command=e,this.headers=null!=t?t:{},this.body=null!=n?n:""}var n;return t.prototype.toString=function(){var n,r,i,s,a;n=[this.command],s=this.headers["content-length"]===!1,s&&delete this.headers["content-length"],i=this.headers;for(r in i)o.call(i,r)&&(a=i[r],n.push(r+":"+a));return this.body&&!s&&n.push("content-length:"+t.sizeOfUTF8(this.body)),n.push(e.LF+this.body),n.join(e.LF)},t.sizeOfUTF8=function(e){return e?encodeURI(e).match(/%..|./g).length:0},n=function(n){var r,i,o,s,a,u,c,l,f,h,p,d,v,g,y,m,b,w;for(s=n.search(RegExp(""+e.LF+e.LF)),a=n.substring(0,s).split(e.LF),o=a.shift(),u={},w=function(e){return e.replace(/^\s+|\s+$/g,"")},g=a.reverse(),f=0,d=g.length;fm)&&(i=n.charAt(c),i!==e.NULL);c=y<=m?++h:--h)r+=i;return new t(o,u,r)},t.unmarshall=function(t){var r,i,o,s;return i=t.split(RegExp(""+e.NULL+e.LF+"*")),s={frames:[],partial:""},s.frames=function(){var e,t,o,s;for(o=i.slice(0,-1),s=[],e=0,t=o.length;e>> "+i);;){if(!(i.length>this.maxWebSocketFrameSize))return this.ws.send(i);this.ws.send(i.substring(0,this.maxWebSocketFrameSize)),i=i.substring(this.maxWebSocketFrameSize),"function"==typeof this.debug&&this.debug("remaining = "+i.length)}},t.prototype._setupHeartbeat=function(t){var r,o,s,a,u,c;if((r=t.version)===i.VERSIONS.V1_1||r===i.VERSIONS.V1_2)return o=function(){var e,n,r,i;for(r=t["heart-beat"].split(","),i=[],e=0,n=r.length;e>> PING"):void 0}}(this))),0!==this.heartbeat.incoming&&0!==a?(u=Math.max(this.heartbeat.incoming,a),"function"==typeof this.debug&&this.debug("check PONG every "+u+"ms"),this.ponger=i.setInterval(u,function(e){return function(){var t;if(t=n()-e.serverActivity,t>2*u)return"function"==typeof e.debug&&e.debug("did not receive server activity for the last "+t+"ms"),e.ws.close()}}(this))):void 0},t.prototype._parseConnect=function(){var e,t,n,r;switch(e=1<=arguments.length?s.call(arguments,0):[],r={},e.length){case 2:r=e[0],t=e[1];break;case 3:e[1]instanceof Function?(r=e[0],t=e[1],n=e[2]):(r.login=e[0],r.passcode=e[1],t=e[2]);break;case 4:r.login=e[0],r.passcode=e[1],t=e[2],n=e[3];break;default:r.login=e[0],r.passcode=e[1],t=e[2],n=e[3],r.host=e[4]}return[r,t,n]},t.prototype.connect=function(){var t,o,a,u;return t=1<=arguments.length?s.call(arguments,0):[],u=this._parseConnect.apply(this,t),a=u[0],this.connectCallback=u[1],o=u[2],"function"==typeof this.debug&&this.debug("Opening Web Socket..."),this.ws.onmessage=function(t){return function(i){var s,a,u,c,l,f,h,p,d,v,g,y,m;if(c="undefined"!=typeof ArrayBuffer&&i.data instanceof ArrayBuffer?(s=new Uint8Array(i.data),"function"==typeof t.debug?t.debug("--- got data length: "+s.length):void 0,function(){var e,t,n;for(n=[],e=0,t=s.length;e=0.10.0"},homepage:"https://github.com/theturtle32/WebSocket-Node",keywords:["websocket","websockets","socket","networking","comet","push","RFC-6455","realtime","server","client"],license:"Apache-2.0",main:"index",name:"websocket",repository:{type:"git",url:"git+https://github.com/theturtle32/WebSocket-Node.git"},scripts:{gulp:"gulp",install:"(node-gyp rebuild 2> builderror.log) || (exit 0)",test:"faucet test/unit"},version:"1.0.26"}},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function e(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(u){i=!0,o=u}finally{try{!r&&a["return"]&&a["return"]()}finally{if(i)throw o}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=function(){function e(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{};r(this,e),this.body=t.body,this.headers=t.headers;try{var s=this.headers.destination.split("/"),a=s[s.length-1].split("."),u=i(a,2);this.senderId=u[0],this.channelName=u[1]}catch(c){console.error("Wrong routing key format")}this._receiverId=n,this._discardMine=o.discardMine||!1,this._discardFromApi=o.discardFromApi||!1}return o(e,[{key:"blackListed",value:function(){return!(!this._discardMine||this._receiverId!==this.senderId||this.fromApi())||!(!this._discardFromApi||!this.fromApi())}},{key:"fromApi",value:function(){return this.headers&&this.headers[s.fromApiHeader]}}]),e}();t["default"]=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:[],n=arguments[1],r=t.map(function(t){return e._attachStreamHook(t,n)})||[];return r.length>0?f["default"].any(r):f["default"].reject("Missing stream hooks")}},{key:"_attachStreamHook",value:function(e,t){var n=this;return new f["default"](function(r,i){var o=e.deviceId,s=e.channel,a=e.stream,u="boolean"!=typeof e.cache||e.cache;void 0!==a||void 0!==s&&void 0!==o||i("Missing Stream or Device ID and Channel");var l=e.routingKey||n._defaultStreamRoutingKey,f=function(){},h=e.callback||f,p=(new Date).getTime();n._createChannel(""+p).then(function(e){n._amqpChannels[""+p]=e;var i=void 0;if(a)if(n.liveStreamExists(a)||(console.error("Stream "+a+" does not exist"),r(!1)),u){var f=n._cachedStreamQueue(a);i=n._amqpChannels[""+p].checkQueue(f,n._streamQueueArguments).then(function(){return n._amqpChannels[""+p].consume(f,function(e){h(n._parseContent(e.content),e.fields,e.properties)},(0,c["default"])(n._subscribeArgs,t))})}else{var d=n.exchangeName(a,n._liveStreamSuffix),v=n.tempQueue(a,n._liveStreamSuffix,p);i=n._amqpChannels[""+p].checkExchange(d).then(function(){return n._amqpChannels[""+p].assertQueue(v,n._streamQueueArguments)}).then(function(){return n._amqpChannels[""+p].bindQueue(v,d,l)}).then(function(){return n._amqpChannels[""+p].consume(v,function(e){h(n._parseContent(e.content),e.fields,e.properties)},(0,c["default"])(n._subscribeArgs,t))})}else{var g=n.exchangeName(o,s),y=n.tempQueue(o,s,p);i=n._amqpChannels[""+p].checkExchange(g).then(function(){return n._amqpChannels[""+p].assertQueue(y,n._streamQueueArguments)}).then(function(){return n._amqpChannels[""+p].bindQueue(y,g,l)}).then(function(){return n._amqpChannels[""+p].consume(y,function(e){h(n._parseContent(e.content),e.fields,e.properties)},(0,c["default"])(n._subscribeArgs,t))})}return i}).then(function(){r(!0)})["catch"](function(e){i(e)})})}},{key:"_cachedStreamQueue",value:function(e){return this.liveStreamByName(e)+"."+this._liveStreamSuffix}}]),t}(p["default"]);delete v.onReceive,delete v.publish,delete v._routingKeyFor,t["default"]=v},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:[],n=arguments[1];return new f["default"](function(r,i){e.connect().then(function(o){var s=function(){};t.forEach(function(t){var n=t.stream,o=t.deviceId,s=t.channel,a=t.qos,u="boolean"!=typeof t.cache||t.cache;void 0!==n||void 0!==s&&void 0!==o||i("Missing Stream or Device ID and Channel"),n?(e.liveStreamExists(n)||(console.error("Stream "+n+" does not exist"),r(!1)),e._topics[e._streamTopicFor(n)]=u?1:0):e._topics[e._streamChannelTopicFor(o,s)]=a||e._connectionOpts.qos}),o.subscribe(e._topics,(0,c["default"])(e._connectionOpts,n),function(n){n?i(!1):(o.on("message",function(n,r){var i=n.split("/"),o=t.filter(function(t){return e.liveStreamByName(t.stream)===i[0]||t.deviceId===i[0]&&t.channel===i[1]}),a=s;o.length>0&&(a=o[0].callback||s),a(n,e._parseContent(r))}),r(!0))})})["catch"](function(e){i(e)})})}},{key:"_streamChannelTopicFor",value:function(e,t){return e+"/"+t}},{key:"_streamTopicFor",value:function(e){return this.liveStreamByName(e)+"/"+this._liveStreamSuffix}}]),t}(p["default"]);delete d.onReceive,delete d.publish,delete d._topicFor,t["default"]=d},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:[],n=arguments[1],r=t.map(function(t){return e._attachStreamHook(t,n)})||[];return r.length>0?f["default"].any(r):f["default"].reject("Missing stream hooks")}},{key:"unsubscribe",value:function(e,t){var n=this;return new f["default"](function(r,i){if(void 0===n._stompConnection)i("Invalid connection");else{var o=n._topicFor(e,t),s=n._subscriptions[o];s.unsubscribe(o),delete n._subscriptions[o],r(!0)}})}},{key:"disconnect",value:function(){var e=this;return new f["default"](function(t,n){if(void 0===e._stompConnection)n("Invalid connection");else{for(var r in e._subscriptions)r&&e._subscriptions[r].unsubscribe();e._subscriptions={},e._stompConnection.disconnect(function(){e._stompConnection=void 0,t(!0)})["catch"](function(e){n(e)})}})}},{key:"_attachStreamHook",value:function(e,t){var n=this;return t=(0,c["default"])({},t),new f["default"](function(t,r){var i=e.stream,o=e.deviceId,s=e.channel,a="boolean"!=typeof e.cache||e.cache,u=function(){},c=e.callback||u;void 0!==i||void 0!==s&&void 0!==o||r("Missing Stream or Device ID and Channel"),n.connect().then(function(e){var r=void 0,u=void 0;i?(n.liveStreamExists(i)||(console.error("Stream "+i+" does not exist"),t(!1)),a?r=n._cachedStreamTopicFor(i):(r=n._streamTopicFor(i),u=n.tempQueue(i,n._liveStreamSuffix))):(r=n._streamChannelTopicFor(o,s),u=n.tempQueue(o,s));var l={};u&&(l["x-queue-name"]=u);var f=function(e){c(n._parseContent(e.body),e.headers)},h=e.subscribe(r,f,l);n._subscriptions[r]=h,t(!0)})["catch"](function(e){r(e)})})}},{key:"_streamChannelTopicFor",value:function(e,t,n,r){return"/"+(n||this._exchangePrefix)+"/"+e+"."+t+"/"+(r||this._defaultPattern)}},{key:"_cachedStreamTopicFor",value:function(e,t){return"/"+(t||this._existingQueuePrefix)+"/"+this.liveStreamByName(e)+"."+this._liveStreamSuffix}},{key:"_streamTopicFor",value:function(e,t,n){return"/"+(t||this._exchangePrefix)+"/"+this.liveStreamByName(e)+"."+(this._liveStreamSuffix+"/"+(n||this._defaultPattern))}}]),t}(p["default"]);delete v.onReceive,delete v.publish,delete v._subcriptionFor,delete v._destinationFor,t["default"]=v},function(e,t,n,r,i){var o;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(s){"use strict";o=function(e){function t(e,t,n,r){return o.setTimer(function(){e(n,r,t)},t)}var o=n(r),s=n(i);return function(e){function n(e,n,i){t(r,e,n,i)}function r(e,t){t.resolve(e)}function i(e,t,n){var r="undefined"==typeof e?new s("timed out after "+n+"ms"):e;t.reject(r)}return e.prototype.delay=function(e){var t=this._beget();return this._handler.fold(n,e,void 0,t._handler),t},e.prototype.timeout=function(e,n){var r=this._beget(),s=r._handler,a=t(i,e,n,r._handler);return this._handler.visit(s,function(e){o.clearTimer(a),this.resolve(e)},function(e){o.clearTimer(a),this.reject(e)},s.notify),r},e}}.call(t,n,t,e),!(void 0!==o&&(e.exports=o))}(n(44))},function(e,t,n,r){var i;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(o){"use strict";i=function(e){var t=n(r).inspect;return function(e){return e.prototype.inspect=function(){return t(e._handler(this))},e}}.call(t,n,t,e),!(void 0!==i&&(e.exports=i))}(n(44))},function(e,t,n,r,i,o){var s;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -!function(a){"use strict";s=function(e){var t=n(r),s=n(i),a=n(o).asap;return t({scheduler:new s(a)})}.call(t,n,t,e),!(void 0!==s&&(e.exports=s))}(n(44))},function(e,t,n,r,i){(function(e,o){function s(e,n){var r={seen:[],stylize:u};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),y(n)?r.showHidden=n:n&&t._extend(r,n),x(r.showHidden)&&(r.showHidden=!1),x(r.depth)&&(r.depth=2),x(r.colors)&&(r.colors=!1),x(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=a),l(r,e,r.depth)}function a(e,t){var n=s.styles[t];return n?"["+s.colors[n][0]+"m"+e+"["+s.colors[n][1]+"m":e}function u(e,t){return e}function c(e){var t={};return e.forEach(function(e,n){t[e]=!0}),t}function l(e,n,r){if(e.customInspect&&n&&T(n.inspect)&&n.inspect!==t.inspect&&(!n.constructor||n.constructor.prototype!==n)){var i=n.inspect(r,e);return _(i)||(i=l(e,i,r)),i}var o=f(e,n);if(o)return o;var s=Object.keys(n),a=c(s);if(e.showHidden&&(s=Object.getOwnPropertyNames(n)),C(n)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return h(n);if(0===s.length){if(T(n)){var u=n.name?": "+n.name:"";return e.stylize("[Function"+u+"]","special")}if(k(n))return e.stylize(RegExp.prototype.toString.call(n),"regexp");if(S(n))return e.stylize(Date.prototype.toString.call(n),"date");if(C(n))return h(n)}var y="",m=!1,b=["{","}"];if(g(n)&&(m=!0,b=["[","]"]),T(n)){var w=n.name?": "+n.name:"";y=" [Function"+w+"]"}if(k(n)&&(y=" "+RegExp.prototype.toString.call(n)),S(n)&&(y=" "+Date.prototype.toUTCString.call(n)),C(n)&&(y=" "+h(n)),0===s.length&&(!m||0==n.length))return b[0]+y+b[1];if(r<0)return k(n)?e.stylize(RegExp.prototype.toString.call(n),"regexp"):e.stylize("[Object]","special");e.seen.push(n);var E;return E=m?p(e,n,r,a,s):s.map(function(t){return d(e,n,r,a,t,m)}),e.seen.pop(),v(E,y,b)}function f(e,t){if(x(t))return e.stylize("undefined","undefined");if(_(t)){var n="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(n,"string")}return w(t)?e.stylize(""+t,"number"):y(t)?e.stylize(""+t,"boolean"):m(t)?e.stylize("null","null"):void 0}function h(e){return"["+Error.prototype.toString.call(e)+"]"}function p(e,t,n,r,i){for(var o=[],s=0,a=t.length;s-1&&(a=o?a.split("\n").map(function(e){return" "+e}).join("\n").substr(2):"\n"+a.split("\n").map(function(e){return" "+e}).join("\n"))):a=e.stylize("[Circular]","special")),x(s)){if(o&&i.match(/^\d+$/))return a;s=JSON.stringify(""+i),s.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.substr(1,s.length-2),s=e.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=e.stylize(s,"string"))}return s+": "+a}function v(e,t,n){var r=0,i=e.reduce(function(e,t){return r++,t.indexOf("\n")>=0&&r++,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0);return i>60?n[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+n[1]:n[0]+t+" "+e.join(", ")+" "+n[1]}function g(e){return Array.isArray(e)}function y(e){return"boolean"==typeof e}function m(e){return null===e}function b(e){return null==e}function w(e){return"number"==typeof e}function _(e){return"string"==typeof e}function E(e){return"symbol"==typeof e}function x(e){return void 0===e}function k(e){return I(e)&&"[object RegExp]"===U(e)}function I(e){return"object"==typeof e&&null!==e}function S(e){return I(e)&&"[object Date]"===U(e)}function C(e){return I(e)&&("[object Error]"===U(e)||e instanceof Error)}function T(e){return"function"==typeof e}function j(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||"undefined"==typeof e}function U(e){return Object.prototype.toString.call(e)}function B(e){return e<10?"0"+e.toString(10):e.toString(10)}function O(){var e=new Date,t=[B(e.getHours()),B(e.getMinutes()),B(e.getSeconds())].join(":");return[e.getDate(),F[e.getMonth()],t].join(" ")}function A(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var R=/%[sdj%]/g;t.format=function(e){if(!_(e)){for(var t=[],n=0;n=i)return e;switch(e){case"%s":return String(r[n++]);case"%d":return Number(r[n++]);case"%j":try{return JSON.stringify(r[n++])}catch(t){return"[Circular]"}default:return e}}),a=r[n];n0)if(t.ended&&!i){var s=new Error("stream.push() after EOF");e.emit("error",s)}else if(t.endEmitted&&i){var s=new Error("stream.unshift() after end event");e.emit("error",s)}else!t.decoder||i||r||(n=t.decoder.write(n)),i||(t.reading=!1),t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,i?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&v(e)),y(e,t);else i||(t.reading=!1);return l(t)}function l(e){return!e.ended&&(e.needReadable||e.length=R)e=R;else{e--;for(var t=1;t<32;t<<=1)e|=e>>t;e++}return e}function h(e,t){return 0===t.length&&t.ended?0:t.objectMode?0===e?0:1:isNaN(e)||B.isNull(e)?t.flowing&&t.buffer.length?t.buffer[0].length:t.length:e<=0?0:(e>t.highWaterMark&&(t.highWaterMark=f(e)),e>t.length?t.ended?t.length:(t.needReadable=!0,0):e)}function p(e,t){var n=null;return B.isBuffer(t)||B.isString(t)||B.isNullOrUndefined(t)||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function d(e,t){if(t.decoder&&!t.ended){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,v(e)}function v(e){var n=e._readableState;n.needReadable=!1,n.emittedReadable||(A("emitReadable",n.flowing),n.emittedReadable=!0,n.sync?t.nextTick(function(){g(e)}):g(e))}function g(e){A("emit readable"),e.emit("readable"),E(e)}function y(e,n){n.readingMore||(n.readingMore=!0,t.nextTick(function(){m(e,n)}))}function m(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length=i)n=o?r.join(""):T.concat(r,i),r.length=0;else if(e0)throw new Error("endReadable called on non-empty stream");n.endEmitted||(n.ended=!0,t.nextTick(function(){n.endEmitted||0!==n.length||(n.endEmitted=!0,e.readable=!1,e.emit("end"))}))}function I(e,t){for(var n=0,r=e.length;n0)&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return A("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?k(this):v(this),null;if(e=h(e,t),0===e&&t.ended)return 0===t.length&&k(this),null;var r=t.needReadable;A("need readable",r),(0===t.length||t.length-e0?x(e,t):null,B.isNull(i)&&(t.needReadable=!0,e=0),t.length-=e,0!==t.length||t.ended||(t.needReadable=!0),n!==e&&t.ended&&0===t.length&&k(this),B.isNull(i)||this.emit("data",i),i},u.prototype._read=function(e){this.emit("error",new Error("not implemented"))},u.prototype.pipe=function(e,n){function r(e){A("onunpipe"),e===f&&o()}function i(){A("onend"),e.end()}function o(){A("cleanup"),e.removeListener("close",u),e.removeListener("finish",c),e.removeListener("drain",v),e.removeListener("error",a),e.removeListener("unpipe",r),f.removeListener("end",i),f.removeListener("end",o),f.removeListener("data",s),!h.awaitDrain||e._writableState&&!e._writableState.needDrain||v()}function s(t){A("ondata");var n=e.write(t);!1===n&&(A("false write response, pause",f._readableState.awaitDrain),f._readableState.awaitDrain++,f.pause())}function a(t){A("onerror",t),l(),e.removeListener("error",a),0===j.listenerCount(e,"error")&&e.emit("error",t)}function u(){e.removeListener("finish",c),l()}function c(){A("onfinish"),e.removeListener("close",u),l()}function l(){A("unpipe"),f.unpipe(e)}var f=this,h=this._readableState;switch(h.pipesCount){case 0:h.pipes=e;break;case 1:h.pipes=[h.pipes,e];break;default:h.pipes.push(e)}h.pipesCount+=1,A("pipe count=%d opts=%j",h.pipesCount,n);var p=(!n||n.end!==!1)&&e!==t.stdout&&e!==t.stderr,d=p?i:o;h.endEmitted?t.nextTick(d):f.once("end",d),e.on("unpipe",r);var v=b(f);return e.on("drain",v),f.on("data",s),e._events&&e._events.error?C(e._events.error)?e._events.error.unshift(a):e._events.error=[a,e._events.error]:e.on("error",a),e.once("close",u),e.once("finish",c),e.emit("pipe",f),h.flowing||(A("pipe resume"),f.resume()),e},u.prototype.unpipe=function(e){var t=this._readableState;if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this),this);if(!e){var n=t.pipes,r=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var i=0;i1){for(var n=[],r=0;r=0;a--)if(u[a]!==c[a])return!1;for(a=u.length-1;a>=0;a--)if(s=u[a],!p(e[s],t[s],n,r))return!1;return!0}function g(e,t,n){p(e,t,!0)&&f(e,t,n,"notDeepStrictEqual",g)}function y(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(n){}return!Error.isPrototypeOf(t)&&t.call({},e)===!0}function m(e){var t;try{e()}catch(n){t=n}return t}function b(e,t,n,r){var i;if("function"!=typeof t)throw new TypeError('"block" argument must be a function');"string"==typeof n&&(r=n,n=null),i=m(t),r=(n&&n.name?" ("+n.name+").":".")+(r?" "+r:"."),e&&!i&&f(i,n,"Missing expected exception"+r);var o="string"==typeof r,s=!e&&_.isError(i),a=!e&&i&&!n;if((s&&o&&y(i,n)||a)&&f(i,n,"Got unwanted exception"+r),e&&i&&n&&!y(i,n)||!e&&i)throw i}var _=n(122),w=Object.prototype.hasOwnProperty,E=Array.prototype.slice,x=function(){return"foo"===function(){}.name}(),k=e.exports=h,I=/\s*function\s+([^\(\s]*)\s*/;k.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=l(this),this.generatedMessage=!0);var t=e.stackStartFunction||f;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var n=new Error;if(n.stack){var r=n.stack,i=a(t),o=r.indexOf("\n"+i);if(o>=0){var s=r.indexOf("\n",o+1);r=r.substring(s+1)}this.stack=r}}},_.inherits(k.AssertionError,Error),k.fail=f,k.ok=h,k.equal=function(e,t,n){e!=t&&f(e,t,n,"==",k.equal)},k.notEqual=function(e,t,n){e==t&&f(e,t,n,"!=",k.notEqual)},k.deepEqual=function(e,t,n){p(e,t,!1)||f(e,t,n,"deepEqual",k.deepEqual)},k.deepStrictEqual=function(e,t,n){p(e,t,!0)||f(e,t,n,"deepStrictEqual",k.deepStrictEqual)},k.notDeepEqual=function(e,t,n){p(e,t,!1)&&f(e,t,n,"notDeepEqual",k.notDeepEqual)},k.notDeepStrictEqual=g,k.strictEqual=function(e,t,n){e!==t&&f(e,t,n,"===",k.strictEqual)},k.notStrictEqual=function(e,t,n){e===t&&f(e,t,n,"!==",k.notStrictEqual)},k["throws"]=function(e,t,n){b(!0,e,t,n)},k.doesNotThrow=function(e,t,n){b(!1,e,t,n)},k.ifError=function(e){if(e)throw e};var C=Object.keys||function(e){var t=[];for(var n in e)w.call(e,n)&&t.push(n);return t}}).call(t,function(){return this}())},[350,123,124],function(e,t){e.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},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 n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},function(e,t,n){"use strict";function r(e,t){var n=v(e);if(n){var r=n.size,i=n.rest;if(r>t)throw new Error("Frame size exceeds frame max");if(i.length>r){if(i[r]!==p)throw new Error("Invalid frame");return{type:n.type,channel:n.channel,size:r,payload:i.slice(0,r),rest:i.slice(r+1)}}}return!1}var i=n(117),o=i.constants,s=i.decode,a=n(118).Buffer,u=n(126);e.exports.PROTOCOL_HEADER="AMQP"+String.fromCharCode(0,0,9,1);var c=o.FRAME_METHOD,l=o.FRAME_HEARTBEAT,f=o.FRAME_HEADER,h=o.FRAME_BODY,p=o.FRAME_END,d=u.builder(h,"channel:16, size:32, payload:size/binary",p);e.exports.makeBodyFrame=function(e,t){return d({channel:e,size:t.length,payload:t})};var v=u.matcher("type:8","channel:16","size:32","rest/binary");e.exports.parseFrame=r;var g=u.matcher("class:16","_weight:16","size:64","flagsAndfields/binary"),y=u.matcher("id:32, args/binary"),m={channel:0};e.exports.decodeFrame=function(e){var t=e.payload;switch(e.type){case c:var n=y(t),r=n.id,i=s(r,n.args);return{id:r,channel:e.channel,fields:i};case f:var o=g(t),r=o["class"],i=s(r,o.flagsAndfields);return{id:r,channel:e.channel,size:o.size,fields:i};case h:return{channel:e.channel,content:e.payload};case l:return m;default:throw new Error("Unknown frame type "+e.type)}},e.exports.HEARTBEAT_BUF=a.from([o.FRAME_HEARTBEAT,0,0,0,0,0,0,o.FRAME_END]),e.exports.HEARTBEAT=m},function(e,t,n){"use strict";e.exports.parse=n(127).parse,e.exports.match=n(130).match,e.exports.build=n(131).build,e.exports.write=n(131).write,e.exports.matcher=e.exports.compile=n(132).compile,e.exports.builder=n(132).compile_builder},function(e,t,n){"use strict";function r(e){for(var t=o.parse(e),n=0,r=t.length;nk&&(k=E,I=[]),I.push(e))}function i(){var e,t,n,r,i,a;if(i=E,a=E,e=m(),null!==e)if(t=s(),null!==t){for(n=[],r=o();null!==r;)n.push(r),r=o();null!==n?e=[e,t,n]:(e=null,E=a)}else e=null,E=a;else e=null,E=a;return null!==e&&(e=function(e,t,n){return n.unshift(t),n}(i,e[1],e[2])),null===e&&(E=i),e}function o(){var e,n,i,o,a,u;return a=E,u=E,e=m(),null!==e?(44===t.charCodeAt(E)?(n=",",E++):(n=null,0===x&&r('","')),null!==n?(i=m(),null!==i?(o=s(),null!==o?e=[e,n,i,o]:(e=null,E=u)):(e=null,E=u)):(e=null,E=u)):(e=null,E=u),null!==e&&(e=function(e,t){return t}(a,e[3])),null===e&&(E=a),e}function s(){var e,t,n,r,i;return r=E,e=a(),null!==e&&(e=function(e,t){return{string:t}}(r,e)),null===e&&(E=r),null===e&&(r=E,i=E,e=f(),null!==e?(t=p(),t=null!==t?t:"",null!==t?(n=d(),n=null!==n?n:"",null!==n?e=[e,t,n]:(e=null,E=i)):(e=null,E=i)):(e=null,E=i),null!==e&&(e=function(e,t,n,r){return{name:t,size:n,specifiers:r}}(r,e[0],e[1],e[2])),null===e&&(E=r),null===e&&(r=E,i=E,e=h(),null!==e?(t=p(),t=null!==t?t:"",null!==t?(n=d(),n=null!==n?n:"",null!==n?e=[e,t,n]:(e=null,E=i)):(e=null,E=i)):(e=null,E=i),null!==e&&(e=function(e,t,n,r){return{value:t,size:n,specifiers:r}}(r,e[0],e[1],e[2])),null===e&&(E=r))),e}function a(){var e,n,i,o,s;return o=E,s=E,34===t.charCodeAt(E)?(e='"',E++):(e=null,0===x&&r('"\\""')),null!==e?(34===t.charCodeAt(E)?(n='"',E++):(n=null,0===x&&r('"\\""')),null!==n?e=[e,n]:(e=null,E=s)):(e=null,E=s),null!==e&&(e=function(e){return""}(o)),null===e&&(E=o),null===e&&(o=E,s=E,34===t.charCodeAt(E)?(e='"',E++):(e=null,0===x&&r('"\\""')),null!==e?(n=u(),null!==n?(34===t.charCodeAt(E)?(i='"',E++):(i=null,0===x&&r('"\\""')),null!==i?e=[e,n,i]:(e=null,E=s)):(e=null,E=s)):(e=null,E=s),null!==e&&(e=function(e,t){return t}(o,e[1])),null===e&&(E=o)),e}function u(){var e,t,n;if(n=E,t=c(),null!==t)for(e=[];null!==t;)e.push(t),t=c();else e=null;return null!==e&&(e=function(e,t){return t.join("")}(n,e)),null===e&&(E=n),e}function c(){var e,n,i,o,s,a,u;return/^[^"\\\0-\x1F]/.test(t.charAt(E))?(e=t.charAt(E),E++):(e=null,0===x&&r('[^"\\\\\\0-\\x1F]')),null===e&&(a=E,'\\"'===t.substr(E,2)?(e='\\"',E+=2):(e=null,0===x&&r('"\\\\\\""')),null!==e&&(e=function(e){return'"'}(a)),null===e&&(E=a),null===e&&(a=E,"\\\\"===t.substr(E,2)?(e="\\\\",E+=2):(e=null,0===x&&r('"\\\\\\\\"')),null!==e&&(e=function(e){return"\\"}(a)),null===e&&(E=a),null===e&&(a=E,"\\/"===t.substr(E,2)?(e="\\/",E+=2):(e=null,0===x&&r('"\\\\/"')),null!==e&&(e=function(e){return"/"}(a)),null===e&&(E=a),null===e&&(a=E,"\\b"===t.substr(E,2)?(e="\\b",E+=2):(e=null,0===x&&r('"\\\\b"')),null!==e&&(e=function(e){return"\b"}(a)),null===e&&(E=a),null===e&&(a=E,"\\f"===t.substr(E,2)?(e="\\f",E+=2):(e=null,0===x&&r('"\\\\f"')),null!==e&&(e=function(e){return"\f"}(a)),null===e&&(E=a),null===e&&(a=E,"\\n"===t.substr(E,2)?(e="\\n",E+=2):(e=null,0===x&&r('"\\\\n"')),null!==e&&(e=function(e){return"\n"}(a)),null===e&&(E=a),null===e&&(a=E,"\\r"===t.substr(E,2)?(e="\\r",E+=2):(e=null,0===x&&r('"\\\\r"')),null!==e&&(e=function(e){return"\r"}(a)),null===e&&(E=a),null===e&&(a=E,"\\t"===t.substr(E,2)?(e="\\t",E+=2):(e=null,0===x&&r('"\\\\t"')),null!==e&&(e=function(e){return"\t"}(a)),null===e&&(E=a),null===e&&(a=E,u=E,"\\u"===t.substr(E,2)?(e="\\u",E+=2):(e=null,0===x&&r('"\\\\u"')),null!==e?(n=l(),null!==n?(i=l(),null!==i?(o=l(),null!==o?(s=l(),null!==s?e=[e,n,i,o,s]:(e=null,E=u)):(e=null,E=u)):(e=null,E=u)):(e=null,E=u)):(e=null,E=u),null!==e&&(e=function(e,t,n,r,i){return String.fromCharCode(parseInt("0x"+t+n+r+i))}(a,e[1],e[2],e[3],e[4])),null===e&&(E=a)))))))))),e}function l(){var e;return/^[0-9a-fA-F]/.test(t.charAt(E))?(e=t.charAt(E),E++):(e=null,0===x&&r("[0-9a-fA-F]")),e}function f(){var e,n,i,o,s;if(o=E,s=E,/^[_a-zA-Z]/.test(t.charAt(E))?(e=t.charAt(E),E++):(e=null,0===x&&r("[_a-zA-Z]")),null!==e){for(n=[],/^[_a-zA-Z0-9]/.test(t.charAt(E))?(i=t.charAt(E),E++):(i=null,0===x&&r("[_a-zA-Z0-9]"));null!==i;)n.push(i),/^[_a-zA-Z0-9]/.test(t.charAt(E))?(i=t.charAt(E),E++):(i=null,0===x&&r("[_a-zA-Z0-9]"));null!==n?e=[e,n]:(e=null,E=s)}else e=null,E=s;return null!==e&&(e=function(e,t,n){return t+n.join("")}(o,e[0],e[1])),null===e&&(E=o),e}function h(){var e,n,i,o,s;if(o=E,48===t.charCodeAt(E)?(e="0",E++):(e=null,0===x&&r('"0"')),null!==e&&(e=function(e){return 0}(o)),null===e&&(E=o),null===e){if(o=E,s=E,/^[1-9]/.test(t.charAt(E))?(e=t.charAt(E),E++):(e=null,0===x&&r("[1-9]")),null!==e){for(n=[],/^[0-9]/.test(t.charAt(E))?(i=t.charAt(E),E++):(i=null,0===x&&r("[0-9]"));null!==i;)n.push(i),/^[0-9]/.test(t.charAt(E))?(i=t.charAt(E),E++):(i=null,0===x&&r("[0-9]"));null!==n?e=[e,n]:(e=null,E=s)}else e=null,E=s;null!==e&&(e=function(e,t,n){return parseInt(t+n.join(""))}(o,e[0],e[1])),null===e&&(E=o)}return e}function p(){var e,n,i,o;return i=E,o=E,58===t.charCodeAt(E)?(e=":",E++):(e=null,0===x&&r('":"')),null!==e?(n=h(),null!==n?e=[e,n]:(e=null,E=o)):(e=null,E=o),null!==e&&(e=function(e,t){return t}(i,e[1])),null===e&&(E=i),null===e&&(i=E,o=E,58===t.charCodeAt(E)?(e=":",E++):(e=null,0===x&&r('":"')),null!==e?(n=f(),null!==n?e=[e,n]:(e=null,E=o)):(e=null,E=o),null!==e&&(e=function(e,t){return t}(i,e[1])),null===e&&(E=i)),e}function d(){var e,n,i,o,s,a;if(s=E,a=E,47===t.charCodeAt(E)?(e="/",E++):(e=null,0===x&&r('"/"')),null!==e)if(n=g(),null!==n){for(i=[],o=v();null!==o;)i.push(o),o=v();null!==i?e=[e,n,i]:(e=null,E=a)}else e=null,E=a;else e=null,E=a;return null!==e&&(e=function(e,t,n){return n.unshift(t),n}(s,e[1],e[2])),null===e&&(E=s),e}function v(){var e,n,i,o;return i=E,o=E,45===t.charCodeAt(E)?(e="-",E++):(e=null,0===x&&r('"-"')),null!==e?(n=g(),null!==n?e=[e,n]:(e=null,E=o)):(e=null,E=o),null!==e&&(e=function(e,t){return t}(i,e[1])),null===e&&(E=i),e}function g(){var e;return"little"===t.substr(E,6)?(e="little",E+=6):(e=null,0===x&&r('"little"')),null===e&&("big"===t.substr(E,3)?(e="big",E+=3):(e=null,0===x&&r('"big"')),null===e&&("signed"===t.substr(E,6)?(e="signed",E+=6):(e=null,0===x&&r('"signed"')),null===e&&("unsigned"===t.substr(E,8)?(e="unsigned",E+=8):(e=null,0===x&&r('"unsigned"')),null===e&&("integer"===t.substr(E,7)?(e="integer",E+=7):(e=null,0===x&&r('"integer"')),null===e&&("binary"===t.substr(E,6)?(e="binary",E+=6):(e=null,0===x&&r('"binary"')),null===e&&("float"===t.substr(E,5)?(e="float",E+=5):(e=null,0===x&&r('"float"')),null===e&&(e=y()))))))),e}function y(){var e,n,i,o;return i=E,o=E,"unit:"===t.substr(E,5)?(e="unit:",E+=5):(e=null,0===x&&r('"unit:"')),null!==e?(n=h(),null!==n?e=[e,n]:(e=null,E=o)):(e=null,E=o),null!==e&&(e=function(e,t){return"unit:"+t}(i,e[1])),null===e&&(E=i),e}function m(){var e,n;for(e=[],/^[ \t\n]/.test(t.charAt(E))?(n=t.charAt(E),E++):(n=null,0===x&&r("[ \\t\\n]"));null!==n;)e.push(n),/^[ \t\n]/.test(t.charAt(E))?(n=t.charAt(E),E++):(n=null,0===x&&r("[ \\t\\n]"));return e}function b(e){e.sort();for(var t=null,n=[],r=0;rg)&&void(d+=n)}function c(e){l("get_integer"),l(e);var n=e.unit,i=o(e,v),s=i*n,a=d/8;return d+=s,!(s%8>0||d>g)&&r(t,a,s/8,e.bigendian,e.signed)}function f(e){l("get_float"),l(e);var n=e.unit,r=o(e,v),s=r*n,a=d/8;return d+=s,!(d>g)&&i(t,a,s/8,e.bigendian)}function h(e){l("get_binary"),l(e);var n=e.unit,r=o(e,v),i=d/8;if(r===!0)return d=g,t.slice(i);var s=r*n;return!(s%8>0||d+s>g)&&(d+=s,t.slice(i,i+s/8))}function p(e){l("get_string"),l(e);var n=e.value.length,r=d/8;return d+=8*n,!(d>g)&&t.slice(r,r+n).toString("utf8")}for(var d=0,v=s(n),g=8*t.length,y=e.length,m=0;m1?[].join.call(arguments,","):e;var t=p(e);return function(e){return i(t,e)}}}).call(t,n(3).Buffer)},function(e,t,n){(function(t){"use strict";function r(){T=[]}function i(){T.push(_.apply(null,arguments))}function o(){return T.join("\n")}function s(e){return"string"==typeof e.size?_("%s * %d",h(e.size),e.unit):(e.size*e.unit).toString()}function a(e){i("bits = %s;\n",s(e));var t="integer"===e.type?"parse_int":"parse_float",n=e.bigendian,r=e.signed;i("byteoffset = offset / 8; offset += bits"),i("if (offset > binsize) { return false; }"),i("else { result = %s(bin, byteoffset, bits / 8, %s, %s); }",t,n,r)}function u(e){i("byteoffset = offset / 8;"),e.size===!0?(i("offset = binsize;"),i("result = bin.slice(byteoffset);")):(i("bits = %s;",s(e)),i("offset += bits;"),i("if (offset > binsize) { return false; }"),i("else { result = bin.slice(byteoffset,","byteoffset + bits / 8); }"))}function c(e){i("byteoffset = offset / 8;");var t=e.value.length,n=8*t;i("offset += %d;",n),i("if (offset > binsize) { return false; }"),i("else { result = bin.toString(byteoffset,",_("byteoffset + %d); }",t))}function l(e){if("string"==typeof e.size)i("var skipbits = %s * %d;",h(e.size),e.unit),i("if (offset + skipbits > binsize) { return false; }"),i("else { offset += skipbits; }");else if(e.size===!0)i("if (offset % 8 === 0) { offset = binsize; }"),i("else { return false; }");else{var t=e.unit*e.size;i("if (offset + %d > binsize) { return false; }",t),i("else { offset += %d; }",t)}}function f(e){if("_"===e.name)l(e);else{switch(e.type){case"integer":case"float":a(e);break;case"binary":u(e);break;case"string":c(e)}if(i("if (result === false) return false;"),e.name)i("else if (%s !== undefined) {",h(e.name)),i("if (%s != result) return false;",h(e.name)),i("}"),i("else %s = result;",h(e.name));else{var t=JSON.stringify(e.value);i("else if (result != %s) return false;",t)}}}function h(e){return"var_"+e}function p(e){for(var t={},n=0;n0)for(var a=0;a0,"Expect some new streams to remain"),this.oldStreams=this.oldStreams.concat(this.newStreams),this.newStreams=[]),this.blocked=!t}},i.prototype._scheduleRead=function(){var e=this;e.scheduledRead||(s(function(){e.scheduledRead=!1,e._readIncoming()}),e.scheduledRead=!0)},i.prototype.pipeFrom=function(e){function t(){i.newStreams.push(e),i._scheduleRead()}function n(){e.removeListener("readable",t),e.removeListener("error",n),e.removeListener("end",n),e.removeListener("unpipeFrom",r)}function r(e){e===i&&n()}var i=this;e.on("unpipeFrom",r),e.on("end",n),e.on("error",n),e.on("readable",t)},i.prototype.unpipeFrom=function(e){e.emit("unpipeFrom",this)},e.exports.Mux=i}).call(t,n(57).setImmediate,n(52))},function(e,t,n){function r(){i.call(this)}e.exports=r;var i=n(138).EventEmitter,o=n(135);o(r,i),r.Readable=n(139),r.Writable=n(149),r.Duplex=n(150),r.Transform=n(151),r.PassThrough=n(152),r.Stream=r,r.prototype.pipe=function(e,t){function n(t){e.writable&&!1===e.write(t)&&c.pause&&c.pause()}function r(){c.readable&&c.resume&&c.resume()}function o(){l||(l=!0,e.end())}function s(){l||(l=!0,"function"==typeof e.destroy&&e.destroy())}function a(e){if(u(),0===i.listenerCount(this,"error"))throw e}function u(){c.removeListener("data",n),e.removeListener("drain",r),c.removeListener("end",o),c.removeListener("close",s),c.removeListener("error",a),e.removeListener("error",a),c.removeListener("end",u),c.removeListener("close",u),e.removeListener("close",u)}var c=this;c.on("data",n),e.on("drain",r),e._isStdio||t&&t.end===!1||(c.on("end",o),c.on("close",s));var l=!1;return c.on("error",a),e.on("error",a),c.on("end",u),c.on("close",u),e.on("close",u),e.emit("pipe",c),e}},function(e,t){function n(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}function r(e){return"function"==typeof e}function i(e){return"number"==typeof e}function o(e){return"object"==typeof e&&null!==e}function s(e){return void 0===e}e.exports=n,n.EventEmitter=n,n.prototype._events=void 0,n.prototype._maxListeners=void 0,n.defaultMaxListeners=10,n.prototype.setMaxListeners=function(e){if(!i(e)||e<0||isNaN(e))throw TypeError("n must be a positive number");return this._maxListeners=e,this},n.prototype.emit=function(e){var t,n,i,a,u,c;if(this._events||(this._events={}),"error"===e&&(!this._events.error||o(this._events.error)&&!this._events.error.length)){if(t=arguments[1],t instanceof Error)throw t;var l=new Error('Uncaught, unspecified "error" event. ('+t+")");throw l.context=t,l}if(n=this._events[e],s(n))return!1;if(r(n))switch(arguments.length){case 1:n.call(this);break;case 2:n.call(this,arguments[1]);break;case 3:n.call(this,arguments[1],arguments[2]);break;default:a=Array.prototype.slice.call(arguments,1),n.apply(this,a)}else if(o(n))for(a=Array.prototype.slice.call(arguments,1),c=n.slice(),i=c.length,u=0;u0&&this._events[e].length>i&&(this._events[e].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[e].length),"function"==typeof console.trace&&console.trace())),this},n.prototype.on=n.prototype.addListener,n.prototype.once=function(e,t){function n(){this.removeListener(e,n),i||(i=!0,t.apply(this,arguments))}if(!r(t))throw TypeError("listener must be a function");var i=!1;return n.listener=t,this.on(e,n),this},n.prototype.removeListener=function(e,t){var n,i,s,a;if(!r(t))throw TypeError("listener must be a function");if(!this._events||!this._events[e])return this;if(n=this._events[e],s=n.length,i=-1,n===t||r(n.listener)&&n.listener===t)delete this._events[e],this._events.removeListener&&this.emit("removeListener",e,t);else if(o(n)){for(a=s;a-- >0;)if(n[a]===t||n[a].listener&&n[a].listener===t){i=a;break}if(i<0)return this;1===n.length?(n.length=0,delete this._events[e]):n.splice(i,1),this._events.removeListener&&this.emit("removeListener",e,t)}return this},n.prototype.removeAllListeners=function(e){var t,n;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[e]&&delete this._events[e],this;if(0===arguments.length){for(t in this._events)"removeListener"!==t&&this.removeAllListeners(t);return this.removeAllListeners("removeListener"),this._events={},this}if(n=this._events[e],r(n))this.removeListener(e,n);else if(n)for(;n.length;)this.removeListener(e,n[n.length-1]);return delete this._events[e],this},n.prototype.listeners=function(e){var t;return t=this._events&&this._events[e]?r(this._events[e])?[this._events[e]]:this._events[e].slice():[]},n.prototype.listenerCount=function(e){if(this._events){var t=this._events[e];if(r(t))return 1;if(t)return t.length}return 0},n.listenerCount=function(e,t){return e.listenerCount(t)}},function(e,t,n){(function(r){t=e.exports=n(140),t.Stream=n(137),t.Readable=t,t.Writable=n(145),t.Duplex=n(144),t.Transform=n(147),t.PassThrough=n(148),r.browser||"disable"!=={NODE_ENV:"production"}.READABLE_STREAM||(e.exports=n(137))}).call(t,n(52))},[351,141,143,144,144],function(e,t){e.exports=Array.isArray||function(e){return"[object Array]"==Object.prototype.toString.call(e)}},function(e,t,n){(function(e){function n(e){return Array.isArray?Array.isArray(e):"[object Array]"===g(e)}function r(e){return"boolean"==typeof e}function i(e){return null===e}function o(e){return null==e}function s(e){return"number"==typeof e}function a(e){return"string"==typeof e}function u(e){return"symbol"==typeof e}function c(e){return void 0===e}function l(e){return"[object RegExp]"===g(e)}function f(e){return"object"==typeof e&&null!==e}function h(e){return"[object Date]"===g(e)}function p(e){return"[object Error]"===g(e)||e instanceof Error}function d(e){return"function"==typeof e}function v(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||"undefined"==typeof e}function g(e){return Object.prototype.toString.call(e)}t.isArray=n,t.isBoolean=r,t.isNull=i,t.isNullOrUndefined=o,t.isNumber=s,t.isString=a,t.isSymbol=u,t.isUndefined=c,t.isRegExp=l,t.isObject=f,t.isDate=h,t.isError=p,t.isFunction=d,t.isPrimitive=v,t.isBuffer=e.isBuffer}).call(t,n(3).Buffer)},91,[352,140,145],[353,144,144],function(e,t,n){function r(e){if(e&&!u(e))throw new Error("Unknown encoding: "+e)}function i(e){return e.toString(this.encoding)}function o(e){this.charReceived=e.length%2,this.charLength=this.charReceived?2:0}function s(e){this.charReceived=e.length%3,this.charLength=this.charReceived?3:0}var a=n(3).Buffer,u=a.isEncoding||function(e){switch(e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}},c=t.StringDecoder=function(e){switch(this.encoding=(e||"utf8").toLowerCase().replace(/[-_]/,""),r(e),this.encoding){ +case"utf8":this.surrogateSize=3;break;case"ucs2":case"utf16le":this.surrogateSize=2,this.detectIncompleteChar=o;break;case"base64":this.surrogateSize=3,this.detectIncompleteChar=s;break;default:return void(this.write=i)}this.charBuffer=new a(6),this.charReceived=0,this.charLength=0};c.prototype.write=function(e){for(var t="";this.charLength;){var n=e.length>=this.charLength-this.charReceived?this.charLength-this.charReceived:e.length;if(e.copy(this.charBuffer,this.charReceived,0,n),this.charReceived+=n,this.charReceived=55296&&r<=56319)){if(this.charReceived=this.charLength=0,0===e.length)return t;break}this.charLength+=this.surrogateSize,t=""}this.detectIncompleteChar(e);var i=e.length;this.charLength&&(e.copy(this.charBuffer,0,e.length-this.charReceived,i),i-=this.charReceived),t+=e.toString(this.encoding,0,i);var i=t.length-1,r=t.charCodeAt(i);if(r>=55296&&r<=56319){var o=this.surrogateSize;return this.charLength+=o,this.charReceived+=o,this.charBuffer.copy(this.charBuffer,o,0,o),e.copy(this.charBuffer,0,0,o),t.substring(0,i)}return t},c.prototype.detectIncompleteChar=function(e){for(var t=e.length>=3?3:e.length;t>0;t--){var n=e[e.length-t];if(1==t&&n>>5==6){this.charLength=2;break}if(t<=2&&n>>4==14){this.charLength=3;break}if(t<=3&&n>>3==30){this.charLength=4;break}}this.charReceived=t},c.prototype.end=function(e){var t="";if(e&&e.length&&(t=this.write(e)),this.charReceived){var n=this.charReceived,r=this.charBuffer,i=this.encoding;t+=r.slice(0,n).toString(i)}return t}},[354,144],[355,147],function(e,t,n){e.exports=n(145)},[356,144],function(e,t,n){e.exports=n(147)},[357,148],[356,154],[352,155,158],[351,156,157,154,154],141,91,[353,154,154],function(e,t,n){"use strict";function r(t,n,r){function i(){return r()?(c=0,!0):++c<2}o.call(this),this.interval=t;var s=t*e.exports.UNITS_TO_MS,a=this.emit.bind(this,"beat"),u=this.emit.bind(this,"timeout");this.sendTimer=setInterval(this.runHeartbeat.bind(this,n,a),s/2);var c=0;this.recvTimer=setInterval(this.runHeartbeat.bind(this,i,u),s)}var i=n(133).inherits,o=n(138).EventEmitter;e.exports.UNITS_TO_MS=1e3,i(r,o),e.exports.Heart=r,r.prototype.clear=function(){clearInterval(this.sendTimer),clearInterval(this.recvTimer)},r.prototype.runHeartbeat=function(e,t){e()||t()}},function(e,t,n){"use strict";var r=n(117),i=n(133).format,o=(n(133).inherits,n(125).HEARTBEAT);e.exports.closeMessage=function(e){var t=e.fields.replyCode;return i('%d (%s) with message "%s"',t,r.constant_strs[t],e.fields.replyText)},e.exports.methodName=function(e){return r.info(e).name},e.exports.inspect=function(e,t){if(e===o)return"";if(e.id){var n=r.info(e.id);return i("<%s channel:%d%s>",n.name,e.channel,t?" "+JSON.stringify(e.fields,void 0,2):"")}return i("",e.channel,e.size)}},function(e,t){"use strict";function n(e){if(e){var t=Math.ceil(e/32);this.words=new Array(t)}else this.words=[];this.wordsInUse=0}function r(e){return Math.floor(e/32)}function i(e){if(0===e)return 32;var t,n=31;return t=e<<16,0!=t&&(n-=16,e=t),t=e<<8,0!=t&&(n-=8,e=t),t=e<<4,0!=t&&(n-=4,e=t),t=e<<2,0!=t&&(n-=2,e=t),n-(e<<1>>>31)}var o=n.prototype;o.ensureSize=function(e){var t=this.words.length;t=this.wordsInUse&&(this.ensureSize(t+1),this.wordsInUse=t+1);var n=1<=this.wordsInUse)){var n=~(1<=this.wordsInUse)return!1;var n=1<=this.wordsInUse)return-1;for(var n=this.words[t]&4294967295<=this.wordsInUse)return e;for(var n=~this.words[t]&4294967295<=0.8 <=9"},dependencies:{bitsyntax:"~0.0.4",bluebird:"^3.4.6","buffer-more-ints":"0.0.2","readable-stream":"1.x >=1.1.9","safe-buffer":"^5.0.1"},devDependencies:{mocha:"~1",claire:"0.4.1","uglify-js":"2.4.x",istanbul:"0.1.x"},scripts:{test:"make test",prepublish:"make"},keywords:["AMQP","AMQP 0-9-1","RabbitMQ"],author:"Michael Bridgen ",license:"MIT"}},function(e,t){},function(e,t,n){"use strict";function r(e){if(!(this instanceof r))return new r(e);c.call(this),this.connection=e;var t=this;["error","close","blocked","unblocked"].forEach(function(n){e.on(n,t.emit.bind(t,n))})}function i(e){l.call(this,e),this.on("delivery",this.handleDelivery.bind(this)),this.on("cancel",this.handleCancel.bind(this))}function o(e){i.call(this,e)}var s=n(117),a=n(50),u=n(133).inherits,c=n(138).EventEmitter,l=n(170).BaseChannel,f=n(170).acceptMessage,h=n(171);u(r,c),e.exports.ChannelModel=r;var p=r.prototype;p.close=function(){return a.fromCallback(this.connection.close.bind(this.connection))},u(i,l),e.exports.Channel=i,p.createChannel=function(){var e=new i(this.connection);return e.open().then(function(t){return e})};var d=i.prototype;d.rpc=function(e,t,n){var r=this;return a.fromCallback(function(i){return r._rpc(e,t,n,i)}).then(function(e){return e.fields})},d.open=function(){return a["try"](this.allocate.bind(this)).then(function(e){return e.rpc(s.ChannelOpen,{outOfBand:""},s.ChannelOpenOk)})},d.close=function(){var e=this;return a.fromCallback(function(t){return e.closeBecause("Goodbye",s.constants.REPLY_SUCCESS,t)})},d.assertQueue=function(e,t){return this.rpc(s.QueueDeclare,h.assertQueue(e,t),s.QueueDeclareOk)},d.checkQueue=function(e){return this.rpc(s.QueueDeclare,h.checkQueue(e),s.QueueDeclareOk)},d.deleteQueue=function(e,t){return this.rpc(s.QueueDelete,h.deleteQueue(e,t),s.QueueDeleteOk)},d.purgeQueue=function(e){return this.rpc(s.QueuePurge,h.purgeQueue(e),s.QueuePurgeOk)},d.bindQueue=function(e,t,n,r){return this.rpc(s.QueueBind,h.bindQueue(e,t,n,r),s.QueueBindOk)},d.unbindQueue=function(e,t,n,r){return this.rpc(s.QueueUnbind,h.unbindQueue(e,t,n,r),s.QueueUnbindOk)},d.assertExchange=function(e,t,n){return this.rpc(s.ExchangeDeclare,h.assertExchange(e,t,n),s.ExchangeDeclareOk).then(function(t){return{exchange:e}})},d.checkExchange=function(e){return this.rpc(s.ExchangeDeclare,h.checkExchange(e),s.ExchangeDeclareOk)},d.deleteExchange=function(e,t){return this.rpc(s.ExchangeDelete,h.deleteExchange(e,t),s.ExchangeDeleteOk)},d.bindExchange=function(e,t,n,r){return this.rpc(s.ExchangeBind,h.bindExchange(e,t,n,r),s.ExchangeBindOk)},d.unbindExchange=function(e,t,n,r){return this.rpc(s.ExchangeUnbind,h.unbindExchange(e,t,n,r),s.ExchangeUnbindOk)},d.publish=function(e,t,n,r){var i=h.publish(e,t,r);return this.sendMessage(i,i,n)},d.sendToQueue=function(e,t,n){return this.publish("",e,t,n)},d.consume=function(e,t,n){var r=this,i=h.consume(e,n);return a.fromCallback(function(e){r._rpc(s.BasicConsume,i,s.BasicConsumeOk,e)}).then(function(e){return r.registerConsumer(e.fields.consumerTag,t),e.fields})},d.cancel=function(e){var t=this;return a.fromCallback(function(n){t._rpc(s.BasicCancel,h.cancel(e),s.BasicCancelOk,n)}).then(function(n){return t.unregisterConsumer(e),n.fields})},d.get=function(e,t){var n=this,r=h.get(e,t);return a.fromCallback(function(e){return n.sendOrEnqueue(s.BasicGet,r,e)}).then(function(e){if(e.id===s.BasicGetEmpty)return!1;if(e.id===s.BasicGetOk){var t=e.fields;return new a(function(e){n.handleMessage=f(function(n){n.fields=t,e(n)})})}throw new Error("Unexpected response to BasicGet: "+inspect(e))})},d.ack=function(e,t){this.sendImmediately(s.BasicAck,h.ack(e.fields.deliveryTag,t))},d.ackAll=function(){this.sendImmediately(s.BasicAck,h.ack(0,!0))},d.nack=function(e,t,n){this.sendImmediately(s.BasicNack,h.nack(e.fields.deliveryTag,t,n))},d.nackAll=function(e){this.sendImmediately(s.BasicNack,h.nack(0,!0,e))},d.reject=function(e,t){this.sendImmediately(s.BasicReject,h.reject(e.fields.deliveryTag,t))},d.prefetch=d.qos=function(e,t){return this.rpc(s.BasicQos,h.prefetch(e,t),s.BasicQosOk)},d.recover=function(){return this.rpc(s.BasicRecover,h.recover(),s.BasicRecoverOk)},u(o,i),e.exports.ConfirmChannel=o,p.createConfirmChannel=function(){var e=new o(this.connection);return e.open().then(function(t){return e.rpc(s.ConfirmSelect,{nowait:!1},s.ConfirmSelectOk)}).then(function(){return e})};var v=o.prototype;v.publish=function(e,t,n,r,i){return this.pushConfirmCallback(i),d.publish.call(this,e,t,n,r)},v.sendToQueue=function(e,t,n,r){return this.publish("",e,t,n,r)},v.waitForConfirms=function(){var e=[],t=this.unconfirmed;return t.forEach(function(n,r){if(null===n);else{var i=new a(function(e,i){t[r]=function(t){n&&n(t),null===t?e():i(t)}});e.push(i)}}),a.all(e)}},function(e,t,n){"use strict";function r(e){v.call(this),this.connection=e,this.reply=null,this.pending=[],this.lwm=1,this.unconfirmed=[],this.on("ack",this.handleConfirm.bind(this,function(e){e&&e(null)})),this.on("nack",this.handleConfirm.bind(this,function(e){e&&e(new Error("message nacked"))})),this.handleMessage=s}function i(e,t){return function(){throw new y(e,t)}}function o(e,t,n){e.sendImmediately=e.sendOrEnqueue=e.sendMessage=i(t,n)}function s(e){var t;if(e.id===c.BasicDeliver)t="delivery";else{if(e.id!==c.BasicReturn)throw g("Expected BasicDeliver or BasicReturn; got %s",f(e));t="return"}var n=this,r=e.fields;return a(function(e){e.fields=r,n.emit(t,e)})}function a(e){function t(t){if(t.id===c.BasicProperties)return a.properties=t.fields,r=i=t.size,0===r?(a.content=b.alloc(0),e(a),s):n;throw"Expected headers frame after delivery"}function n(t){if(t.content){var u=t.content.length;if(i-=u,0===i)return null!==o?(o.push(t.content),a.content=b.concat(o)):a.content=t.content,e(a),s;if(i<0)throw g("Too much content sent! Expected %d bytes",r);return null!==o?o.push(t.content):o=[t.content],n}throw"Expected content frame after headers"}var r=0,i=0,o=null,a={fields:null,properties:null,content:null};return t}function u(e){r.call(this,e),this.consumers={}}var c=n(117),l=n(160).closeMessage,f=n(160).inspect,h=n(160).methodName,p=n(121),d=n(133).inherits,v=n(138).EventEmitter,g=n(133).format,y=n(165).IllegalOperationError,m=n(165).stackCapture,b=n(118).Buffer;d(r,v),e.exports.Channel=r,e.exports.acceptMessage=a;var _=r.prototype;_.allocate=function(){return this.ch=this.connection.freshChannel(this),this},_.sendImmediately=function(e,t){return this.connection.sendMethod(this.ch,e,t)},_.sendOrEnqueue=function(e,t,n){this.reply?this.pending.push({method:e,fields:t,reply:n}):(p(0===this.pending.length),this.reply=n,this.sendImmediately(e,t))},_.sendMessage=function(e,t,n){return this.connection.sendMessage(this.ch,c.BasicPublish,e,c.BasicProperties,t,n)},_._rpc=function(e,t,n,r){function i(t,i){if(null===t){if(i.id===n)return r(null,i);var s=h(n),a=new Error(g("Expected %s; got %s",s,f(i,!1)));return o.closeWithError(g("Expected %s; got %s",s,h(i.id)),c.constants.UNEXPECTED_FRAME,a),r(a)}if(t instanceof Error)return r(t);var u=(t.fields.classId<<16)+t.fields.methodId,a=e===u?g("Operation failed: %s; %s",h(e),l(t)):g("Channel closed by server: %s",l(t));return r(new Error(a))}var o=this;this.sendOrEnqueue(e,t,i)},_.toClosed=function(e){this._rejectPending(),o(this,"Channel closed",e),this.accept=i("Channel closed",e),this.connection.releaseChannel(this.ch),this.emit("close")},_.toClosing=function(e,t){var n=this.sendImmediately.bind(this);o(this,"Channel closing",e),this.accept=function(e){if(e.id===c.ChannelCloseOk){t&&t();var r=m("ChannelCloseOk frame received");this.toClosed(r)}else e.id===c.ChannelClose&&n(c.ChannelCloseOk,{})}},_._rejectPending=function(){function e(e){e(new Error("Channel ended, no reply will be forthcoming"))}null!==this.reply&&e(this.reply),this.reply=null;for(var t;t=this.pending.shift();)e(t.reply);this.pending=null},_.closeBecause=function(e,t,n){this.sendImmediately(c.ChannelClose,{replyText:e,replyCode:t,methodId:0,classId:0});var r=m("closeBecause called: "+e);this.toClosing(r,n)},_.closeWithError=function(e,t,n){var r=this;this.closeBecause(e,t,function(){n.code=t,r.emit("error",n)})},_.acceptMessageFrame=function(e){try{this.handleMessage=this.handleMessage(e)}catch(t){"string"==typeof t?this.closeWithError(t,c.constants.UNEXPECTED_FRAME,new Error(t)):t instanceof Error?this.closeWithError("Error while processing message",c.constants.INTERNAL_ERROR,t):this.closeWithError("Internal error while processing message",c.constants.INTERNAL_ERROR,new Error(t.toString()))}},_.handleConfirm=function(e,t){var n=t.deliveryTag,r=t.multiple;if(r){var i=this.unconfirmed.splice(0,n-this.lwm+1);this.lwm=n+1,i.forEach(e)}else{var o;if(n===this.lwm)for(o=this.unconfirmed.shift(),this.lwm++;null===this.unconfirmed[0];)this.unconfirmed.shift(),this.lwm++;else o=this.unconfirmed[n-this.lwm],this.unconfirmed[n-this.lwm]=null;e(o)}},_.pushConfirmCallback=function(e){this.unconfirmed.push(e||!1)},_.accept=function(e){switch(e.id){case void 0:case c.BasicDeliver:case c.BasicReturn:case c.BasicProperties:return this.acceptMessageFrame(e);case c.BasicAck:return this.emit("ack",e.fields);case c.BasicNack:return this.emit("nack",e.fields);case c.BasicCancel:return this.emit("cancel",e.fields);case c.ChannelClose:if(this.reply){var t=this.reply;this.reply=null,t(e)}var n="Channel closed by server: "+l(e);this.sendImmediately(c.ChannelCloseOk,{});var r=new Error(n);r.code=e.fields.replyCode,this.emit("error",r);var i=m(n);return void this.toClosed(i);case c.BasicFlow:return this.closeWithError("Flow not implemented",c.constants.NOT_IMPLEMENTED,new Error("Flow not implemented"));default:var t=this.reply;if(this.reply=null,this.pending.length>0){var o=this.pending.shift();this.reply=o.reply,this.sendImmediately(o.method,o.fields)}return t(null,e)}},_.onBufferDrain=function(){this.emit("drain")},d(u,r),e.exports.BaseChannel=u,u.prototype.registerConsumer=function(e,t){this.consumers[e]=t},u.prototype.unregisterConsumer=function(e){delete this.consumers[e]},u.prototype.dispatchMessage=function(e,t){var n=e.consumerTag,r=this.consumers[n];if(r)return r(t);throw new Error("Unknown consumer: "+n)},u.prototype.handleDelivery=function(e){return this.dispatchMessage(e.fields,e)},u.prototype.handleCancel=function(e){return this.dispatchMessage(e,null)}},function(e,t){"use strict";function n(e,t,n){void 0!=n&&(e[t]=n)}var r=Object.freeze({}),i={};i.assertQueue=function(e,t){e=e||"",t=t||r;var i=Object.create(t.arguments||null);return n(i,"x-expires",t.expires),n(i,"x-message-ttl",t.messageTtl),n(i,"x-dead-letter-exchange",t.deadLetterExchange),n(i,"x-dead-letter-routing-key",t.deadLetterRoutingKey),n(i,"x-max-length",t.maxLength),n(i,"x-max-priority",t.maxPriority),{queue:e,exclusive:!!t.exclusive,durable:void 0===t.durable||t.durable,autoDelete:!!t.autoDelete,arguments:i,passive:!1,ticket:0,nowait:!1}},i.checkQueue=function(e){return{queue:e,passive:!0,nowait:!1,durable:!0,autoDelete:!1,exclusive:!1,ticket:0}},i.deleteQueue=function(e,t){return t=t||r,{queue:e,ifUnused:!!t.ifUnused,ifEmpty:!!t.ifEmpty,ticket:0,nowait:!1}},i.purgeQueue=function(e){return{queue:e,ticket:0,nowait:!1}},i.bindQueue=function(e,t,n,r){return{queue:e,exchange:t,routingKey:n,arguments:r,ticket:0,nowait:!1}},i.unbindQueue=function(e,t,n,r){return{queue:e,exchange:t,routingKey:n,arguments:r,ticket:0,nowait:!1}},i.assertExchange=function(e,t,i){i=i||r;var o=Object.create(i.arguments||null);return n(o,"alternate-exchange",i.alternateExchange),{exchange:e,ticket:0,type:t,passive:!1,durable:void 0===i.durable||i.durable,autoDelete:!!i.autoDelete,internal:!!i.internal,nowait:!1,arguments:o}},i.checkExchange=function(e){return{exchange:e,passive:!0,nowait:!1,durable:!0,internal:!1,type:"",autoDelete:!1,ticket:0}},i.deleteExchange=function(e,t){return t=t||r,{exchange:e,ifUnused:!!t.ifUnused,ticket:0,nowait:!1}},i.bindExchange=function(e,t,n,r){return{source:t,destination:e,routingKey:n,arguments:r,ticket:0,nowait:!1}},i.unbindExchange=function(e,t,n,r){return{source:t,destination:e,routingKey:n,arguments:r,ticket:0,nowait:!1}},i.publish=function(e,t,i){function o(e){return void 0===e?void 0:Array.isArray(e)?e.map(String):[String(e)]}i=i||r;var s=Object.create(i.headers||null);n(s,"CC",o(i.CC)),n(s,"BCC",o(i.BCC));var a;void 0!==i.persistent?a=i.persistent?2:1:"number"==typeof i.deliveryMode?a=i.deliveryMode:i.deliveryMode&&(a=2);var u=i.expiration;return void 0!==u&&(u=u.toString()),{exchange:e,routingKey:t,mandatory:!!i.mandatory,immediate:!1,ticket:void 0,contentType:i.contentType,contentEncoding:i.contentEncoding,headers:s,deliveryMode:a,priority:i.priority,correlationId:i.correlationId,replyTo:i.replyTo,expiration:u,messageId:i.messageId,timestamp:i.timestamp,type:i.type,userId:i.userId,appId:i.appId,clusterId:void 0}},i.consume=function(e,t){t=t||r;var i=Object.create(t.arguments||null);return n(i,"x-priority",t.priority),{ticket:0,queue:e,consumerTag:t.consumerTag||"",noLocal:!!t.noLocal,noAck:!!t.noAck,exclusive:!!t.exclusive,nowait:!1,arguments:i}},i.cancel=function(e){return{consumerTag:e,nowait:!1}},i.get=function(e,t){return t=t||r,{ticket:0,queue:e,noAck:!!t.noAck}},i.ack=function(e,t){return{deliveryTag:e,multiple:!!t}},i.nack=function(e,t,n){return{deliveryTag:e,multiple:!!t,requeue:void 0===n||n}},i.reject=function(e,t){return{deliveryTag:e,requeue:void 0===t||t}},i.prefetch=function(e,t){return{prefetchCount:e||0,prefetchSize:0,global:!!t}},i.recover=function(){return{requeue:!0}},e.exports=Object.freeze(i)},function(e,t,n){(function(e){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(173),u=r(a),c=n(264),l=r(c),f=function(){function e(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};i(this,n);var t=o(this,(n.__proto__||Object.getPrototypeOf(n)).call(this));return t._connectionParams=(0,v["default"])({},b["default"].camelizeKeys(e)),t._endpointConfigs=void 0,t._endpoint=(0,v["default"])(C.endpoint,t._connectionParams.endpoint),t._deviceKey=t._connectionParams.deviceKey,t._channels=t._connectionParams.channels,t._deviceId=t._connectionParams.deviceId,t._client=t._connectionParams.client,t._secret=t._connectionParams.secret,t._host=t._connectionParams.host,t._port=t._connectionParams.port,t._vhost=t._connectionParams.vhost,t._protocol=C.protocol,t._inboxTopic=t._connectionParams.inputTopic||C.inboxTopic,t._liveStreamSuffix=C.liveStreamSuffix,t._tempQueueSuffix=C.tempQueueSuffix,t._liveStreams=[],t._tls=t._connectionParams.tls||!1,t._tlsOpts={},t._connectionParams.cert&&(t._tlsOpts.cert=p["default"].readFileSync(t._connectionParams.cert)),t._connectionParams.key&&(t._tlsOpts.key=p["default"].readFileSync(t._connectionParams.key)),t._connectionParams.passphrase&&(t._tlsOpts.passphrase=t._connectionParams.passphrase),t._connectionParams.ca&&(Array.isArray(t._connectionParams.ca)?t._tlsOpts.ca=t._connectionParams.ca.map(function(e){return p["default"].readFileSync(e)}):t._tlsOpts.ca=[p["default"].readFileSync(t._connectionParams.ca)]),t._connectionParams.pfx&&(t._tlsOpts.pfx=p["default"].readFileSync(t._connectionParams.pfx)),t._connectionParams.disableCertCheck?t._tlsOpts.rejectUnauthorized=!1:t._tlsOpts.rejectUnauthorized=!0,t._tlsOpts.secureProtocol=t._connectionParams.secureProtocol||C.tls.secureProtocol,t}return s(n,t),f(n,[{key:"getEndpointConfigs",value:function(){var e=this;return new w["default"](function(t,n){if(void 0!==e._endpointConfigs&&t(e._endpointConfigs),e._deviceId&&e._secret||e._deviceKey){var r=e._generateHostname(),i=x["default"].resolve(r,e._endpoint.deviceConfigurationsPath);if(e._deviceKey){var o={url:i,method:"get",responseType:"json",headers:{"Device-Key":e._deviceKey,"Content-Type":"application/json"}};(0,y["default"])(o).then(function(n){e._endpointConfigs=b["default"].camelizeKeys(n.data),e._connectionParams=e._endpointConfigs.connection,t(e._endpointConfigs)})["catch"](function(e){n(e)})}else e._deviceId&&e._secret&&e._host&&e._port&&e._vhost&&(e._connectionParams.protocols={},e._tls?e._connectionParams.protocols[e._protocol]={tlsPort:e._port}:e._connectionParams.protocols[e._protocol]={port:e._port},e._endpointConfigs={connection:e._connectionParams,channels:[]},t(e._endpointConfigs))}else if(e._client&&e._secret)if(e._host&&e._port&&e._vhost)e._connectionParams.protocols={},e._tls?e._connectionParams.protocols[e._protocol]={tlsPort:e._port}:e._connectionParams.protocols[e._protocol]={port:e._port},e._endpointConfigs={connection:e._connectionParams,liveStreams:[]},t(e._endpointConfigs);else{var s=e._generateHostname(),a=x["default"].resolve(s,e._endpoint.liveStreamKeyConfigurationsPath),u={url:a,method:"get",responseType:"json",headers:{"Live-Stream-Key-Client":e._client,"Live-Stream-Key-Secret":e._secret,"Content-Type":"application/json"}};(0,y["default"])(u).then(function(n){e._endpointConfigs=b["default"].camelizeKeys(n.data),e._connectionParams=e._endpointConfigs.connection,e._liveStreams=e._endpointConfigs.liveStreams||[],t(e._endpointConfigs)})["catch"](function(e){n(e)})}else n("Missing Device Key or wrong connection parameters")})}},{key:"channels",value:function(){return this._endpointConfigs.channels?(this._channels=this._endpointConfigs.channels.map(function(e){return e.name}),this._channels||[]):[]}},{key:"deviceId",value:function(){return this._deviceId=this._deviceId||this._connectionParams.deviceId,this._deviceId}},{key:"liveStreamByName",value:function(e){var t=(0,u["default"])(this._liveStreams,function(t){return t.name===e});return t.length>0?t[0].id||e:e}},{key:"liveStreamExists",value:function(e){var t=(0,u["default"])(this._liveStreams,function(t){return t.name===e});return t.length>0}},{key:"tempQueue",value:function(e,t,n){var r=n||(new Date).getTime(),i=this._connectionParams.client||this._connectionParams.deviceId;return r+"-"+i+"-"+(this.exchangeName(e,t)+".")+(""+this._tempQueueSuffix)}},{key:"exchangeName",value:function(e,t){return e&&t?this.liveStreamByName(e)+"."+t:""+t}},{key:"_encapsulateContent",value:function(e){var t=e;try{t=JSON.stringify(e)}catch(n){t=e}return t}},{key:"_generateHostname",value:function(){if(this._endpoint.url)return this._endpoint.url;var e=this._endpoint.host+":"+this._endpoint.port,t=this._tls?this._endpoint.secureProtocol:this._endpoint.protocol;return(0,l["default"])(e,t)||(e=t+"://"+e),e}},{key:"_parseContent",value:function(t){var n=t;e.isBuffer(n)&&(n=n.toString("utf-8"));var r=void 0;try{r=JSON.parse(n)}catch(i){r=n}return r}}]),n}(I["default"]);t["default"]=S}).call(t,n(3).Buffer)},function(e,t,n){function r(e,t){var n=a(e)?i:o;return n(e,s(t,3))}var i=n(174),o=n(175),s=n(181),a=n(23);e.exports=r},function(e,t){function n(e,t){for(var n=-1,r=null==e?0:e.length,i=0,o=[];++n-1}var i=n(188);e.exports=r},function(e,t,n){function r(e,t){var n=this.__data__,r=i(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}var i=n(188);e.exports=r},function(e,t,n){function r(){this.__data__=new i,this.size=0}var i=n(185);e.exports=r},function(e,t){function n(e){var t=this.__data__,n=t["delete"](e);return this.size=t.size,n}e.exports=n},function(e,t){function n(e){return this.__data__.get(e)}e.exports=n},function(e,t){function n(e){return this.__data__.has(e)}e.exports=n},function(e,t,n){function r(e,t){var n=this.__data__;if(n instanceof i){var r=n.__data__;if(!o||r.lengthh))return!1;var d=l.get(e);if(d&&l.get(t))return d==t;var v=-1,g=!0,y=n&u?new i:void 0;for(l.set(e,t),l.set(t,e);++v=t?e:t)),e}e.exports=n},function(e,t,n){e.exports=n(267)},function(e,t,n){"use strict";function r(e){var t=new s(e),n=o(s.prototype.request,t);return i.extend(n,s.prototype,t),i.extend(n,t),n}var i=n(268),o=n(269),s=n(271),a=n(272),u=r(a);u.Axios=s,u.create=function(e){return r(i.merge(a,e))},u.Cancel=n(289),u.CancelToken=n(290),u.isCancel=n(286),u.all=function(e){return Promise.all(e)},u.spread=n(291),e.exports=u,e.exports["default"]=u},function(e,t,n){"use strict";function r(e){return"[object Array]"===k.call(e)}function i(e){return"[object ArrayBuffer]"===k.call(e)}function o(e){return"undefined"!=typeof FormData&&e instanceof FormData}function s(e){var t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer}function a(e){return"string"==typeof e}function u(e){return"number"==typeof e}function c(e){return"undefined"==typeof e}function l(e){return null!==e&&"object"==typeof e}function f(e){return"[object Date]"===k.call(e)}function h(e){return"[object File]"===k.call(e)}function p(e){return"[object Blob]"===k.call(e)}function d(e){return"[object Function]"===k.call(e)}function v(e){return l(e)&&d(e.pipe)}function g(e){return"undefined"!=typeof URLSearchParams&&e instanceof URLSearchParams}function y(e){return e.replace(/^\s*/,"").replace(/\s*$/,"")}function m(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product)&&("undefined"!=typeof window&&"undefined"!=typeof document)}function b(e,t){if(null!==e&&"undefined"!=typeof e)if("object"!=typeof e&&(e=[e]),r(e))for(var n=0,i=e.length;n + * @license MIT + */ +e.exports=function(e){return null!=e&&(n(e)||r(e)||!!e._isBuffer)}},function(e,t,n){"use strict";function r(e){this.defaults=e,this.interceptors={request:new s,response:new s}}var i=n(272),o=n(268),s=n(283),a=n(284);r.prototype.request=function(e){"string"==typeof e&&(e=o.merge({url:arguments[0]},arguments[1])),e=o.merge(i,{method:"get"},this.defaults,e),e.method=e.method.toLowerCase();var t=[a,void 0],n=Promise.resolve(e);for(this.interceptors.request.forEach(function(e){t.unshift(e.fulfilled,e.rejected)}),this.interceptors.response.forEach(function(e){t.push(e.fulfilled,e.rejected)});t.length;)n=n.then(t.shift(),t.shift());return n},o.forEach(["delete","get","head","options"],function(e){r.prototype[e]=function(t,n){return this.request(o.merge(n||{},{method:e,url:t}))}}),o.forEach(["post","put","patch"],function(e){r.prototype[e]=function(t,n,r){return this.request(o.merge(r||{},{method:e,url:t,data:n}))}}),e.exports=r},function(e,t,n){(function(t){"use strict";function r(e,t){!o.isUndefined(e)&&o.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}function i(){var e;return"undefined"!=typeof XMLHttpRequest?e=n(274):"undefined"!=typeof t&&(e=n(274)),e}var o=n(268),s=n(273),a={"Content-Type":"application/x-www-form-urlencoded"},u={adapter:i(),transformRequest:[function(e,t){return s(t,"Content-Type"),o.isFormData(e)||o.isArrayBuffer(e)||o.isBuffer(e)||o.isStream(e)||o.isFile(e)||o.isBlob(e)?e:o.isArrayBufferView(e)?e.buffer:o.isURLSearchParams(e)?(r(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):o.isObject(e)?(r(t,"application/json;charset=utf-8"),JSON.stringify(e)):e}],transformResponse:[function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(t){}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,validateStatus:function(e){return e>=200&&e<300}};u.headers={common:{Accept:"application/json, text/plain, */*"}},o.forEach(["delete","get","head"],function(e){u.headers[e]={}}),o.forEach(["post","put","patch"],function(e){u.headers[e]=o.merge(a)}),e.exports=u}).call(t,n(52))},function(e,t,n){"use strict";var r=n(268);e.exports=function(e,t){r.forEach(e,function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])})}},function(e,t,n){"use strict";var r=n(268),i=n(275),o=n(278),s=n(279),a=n(280),u=n(276),c="undefined"!=typeof window&&window.btoa&&window.btoa.bind(window)||n(281);e.exports=function(e){return new Promise(function(t,l){var f=e.data,h=e.headers;r.isFormData(f)&&delete h["Content-Type"];var p=new XMLHttpRequest,d="onreadystatechange",v=!1;if("undefined"==typeof window||!window.XDomainRequest||"withCredentials"in p||a(e.url)||(p=new window.XDomainRequest,d="onload",v=!0,p.onprogress=function(){},p.ontimeout=function(){}),e.auth){var g=e.auth.username||"",y=e.auth.password||"";h.Authorization="Basic "+c(g+":"+y)}if(p.open(e.method.toUpperCase(),o(e.url,e.params,e.paramsSerializer),!0),p.timeout=e.timeout,p[d]=function(){if(p&&(4===p.readyState||v)&&(0!==p.status||p.responseURL&&0===p.responseURL.indexOf("file:"))){var n="getAllResponseHeaders"in p?s(p.getAllResponseHeaders()):null,r=e.responseType&&"text"!==e.responseType?p.response:p.responseText,o={data:r,status:1223===p.status?204:p.status,statusText:1223===p.status?"No Content":p.statusText,headers:n,config:e,request:p};i(t,l,o),p=null}},p.onerror=function(){l(u("Network Error",e,null,p)),p=null},p.ontimeout=function(){l(u("timeout of "+e.timeout+"ms exceeded",e,"ECONNABORTED",p)),p=null},r.isStandardBrowserEnv()){var m=n(282),b=(e.withCredentials||a(e.url))&&e.xsrfCookieName?m.read(e.xsrfCookieName):void 0;b&&(h[e.xsrfHeaderName]=b)}if("setRequestHeader"in p&&r.forEach(h,function(e,t){"undefined"==typeof f&&"content-type"===t.toLowerCase()?delete h[t]:p.setRequestHeader(t,e)}),e.withCredentials&&(p.withCredentials=!0),e.responseType)try{p.responseType=e.responseType}catch(_){if("json"!==e.responseType)throw _}"function"==typeof e.onDownloadProgress&&p.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&p.upload&&p.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then(function(e){p&&(p.abort(),l(e),p=null)}),void 0===f&&(f=null),p.send(f)})}},function(e,t,n){"use strict";var r=n(276);e.exports=function(e,t,n){var i=n.config.validateStatus;n.status&&i&&!i(n.status)?t(r("Request failed with status code "+n.status,n.config,null,n.request,n)):e(n)}},function(e,t,n){"use strict";var r=n(277);e.exports=function(e,t,n,i,o){var s=new Error(e);return r(s,t,n,i,o)}},function(e,t){"use strict";e.exports=function(e,t,n,r,i){return e.config=t,n&&(e.code=n),e.request=r,e.response=i,e}},function(e,t,n){"use strict";function r(e){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var i=n(268);e.exports=function(e,t,n){if(!t)return e;var o;if(n)o=n(t);else if(i.isURLSearchParams(t))o=t.toString();else{var s=[];i.forEach(t,function(e,t){null!==e&&"undefined"!=typeof e&&(i.isArray(e)?t+="[]":e=[e],i.forEach(e,function(e){i.isDate(e)?e=e.toISOString():i.isObject(e)&&(e=JSON.stringify(e)),s.push(r(t)+"="+r(e))}))}),o=s.join("&")}return o&&(e+=(e.indexOf("?")===-1?"?":"&")+o),e}},function(e,t,n){"use strict";var r=n(268),i=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];e.exports=function(e){var t,n,o,s={};return e?(r.forEach(e.split("\n"),function(e){if(o=e.indexOf(":"),t=r.trim(e.substr(0,o)).toLowerCase(),n=r.trim(e.substr(o+1)),t){if(s[t]&&i.indexOf(t)>=0)return;"set-cookie"===t?s[t]=(s[t]?s[t]:[]).concat([n]):s[t]=s[t]?s[t]+", "+n:n}}),s):s}},function(e,t,n){"use strict";var r=n(268);e.exports=r.isStandardBrowserEnv()?function(){function e(e){var t=e;return n&&(i.setAttribute("href",t),t=i.href),i.setAttribute("href",t),{href:i.href,protocol:i.protocol?i.protocol.replace(/:$/,""):"",host:i.host,search:i.search?i.search.replace(/^\?/,""):"",hash:i.hash?i.hash.replace(/^#/,""):"",hostname:i.hostname,port:i.port,pathname:"/"===i.pathname.charAt(0)?i.pathname:"/"+i.pathname}}var t,n=/(msie|trident)/i.test(navigator.userAgent),i=document.createElement("a");return t=e(window.location.href),function(n){var i=r.isString(n)?e(n):n;return i.protocol===t.protocol&&i.host===t.host}}():function(){return function(){return!0}}()},function(e,t){"use strict";function n(){this.message="String contains an invalid character"}function r(e){for(var t,r,o=String(e),s="",a=0,u=i;o.charAt(0|a)||(u="=",a%1);s+=u.charAt(63&t>>8-a%1*8)){if(r=o.charCodeAt(a+=.75),r>255)throw new n;t=t<<8|r}return s}var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";n.prototype=new Error,n.prototype.code=5,n.prototype.name="InvalidCharacterError",e.exports=r},function(e,t,n){"use strict";var r=n(268);e.exports=r.isStandardBrowserEnv()?function(){return{write:function(e,t,n,i,o,s){var a=[];a.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),r.isString(i)&&a.push("path="+i),r.isString(o)&&a.push("domain="+o),s===!0&&a.push("secure"),document.cookie=a.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()},function(e,t,n){"use strict";function r(){this.handlers=[]}var i=n(268);r.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},r.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},r.prototype.forEach=function(e){i.forEach(this.handlers,function(t){null!==t&&e(t)})},e.exports=r},function(e,t,n){"use strict";function r(e){e.cancelToken&&e.cancelToken.throwIfRequested()}var i=n(268),o=n(285),s=n(286),a=n(272),u=n(287),c=n(288);e.exports=function(e){r(e),e.baseURL&&!u(e.url)&&(e.url=c(e.baseURL,e.url)),e.headers=e.headers||{},e.data=o(e.data,e.headers,e.transformRequest),e.headers=i.merge(e.headers.common||{},e.headers[e.method]||{},e.headers||{}),i.forEach(["delete","get","head","post","put","patch","common"],function(t){delete e.headers[t]});var t=e.adapter||a.adapter;return t(e).then(function(t){return r(e),t.data=o(t.data,t.headers,e.transformResponse),t},function(t){return s(t)||(r(e),t&&t.response&&(t.response.data=o(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)})}},function(e,t,n){"use strict";var r=n(268);e.exports=function(e,t,n){return r.forEach(n,function(n){e=n(e,t)}),e}},function(e,t){"use strict";e.exports=function(e){return!(!e||!e.__CANCEL__)}},function(e,t){"use strict";e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},function(e,t){"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},function(e,t){"use strict";function n(e){this.message=e}n.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},n.prototype.__CANCEL__=!0,e.exports=n},function(e,t,n){"use strict";function r(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise(function(e){t=e});var n=this;e(function(e){n.reason||(n.reason=new i(e),t(n.reason))})}var i=n(289);r.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},r.source=function(){var e,t=new r(function(t){e=t});return{token:t,cancel:e}},e.exports=r},function(e,t){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},function(e,t,n){var r,i;!function(o){var s=function(e,t,n){if(!p(t)||v(t)||g(t)||y(t)||h(t))return t;var r,i=0,o=0;if(d(t))for(r=[],o=t.length;i2&&void 0!==arguments[2]?arguments[2]:{};r(this,e),this.content=t.content,this.fields=t.fields,this.properties=t.properties;try{var s=this.fields.routingKey.split("."),a=i(s,2);this.senderId=a[0],this.channelName=a[1]}catch(u){console.error("Wrong routing key format")}this._receiverId=n,this._discardMine=o.discardMine||!1,this._discardFromApi=o.discardFromApi||!1}return o(e,[{key:"blackListed",value:function(){return!(!this._discardMine||this._receiverId!==this.senderId||this.fromApi())||!(!this._discardFromApi||!this.fromApi())}},{key:"fromApi",value:function(){return this.properties.headers&&this.properties.headers[s.fromApiHeader]}}]),e}();t["default"]=a},function(e,t,n){(function(e){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(296),u=r(a),c=function(){function e(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};return t=(0,f["default"])(this._connectionOpts,t),new p["default"](function(n,r){e.getEndpointConfigs().then(function(i){var o=i.connection;if(void 0!==e._mqttConnection)n(e._mqttConnection);else try{var s={host:o.host,port:e._tls?o.protocols.mqtt.tlsPort:o.protocols.mqtt.port,username:o.vhost+":"+(o.deviceId||o.client),password:o.secret,clientId:o.deviceId||o.client,connectionTimeout:t.connectionTimeout||e._connectionTimeout};e._tls&&(s=(0,f["default"])(s,e._tlsOpts));var a=v["default"].connect(s);a.on("error",function(t){e.emit("error",t),r(t)}),a.on("close",function(t){r(t),e.emit("close",t),e._mqttConnection=void 0}),e._mqttConnection=a,e.emit("connect"),n(e._mqttConnection)}catch(u){r(u)}})["catch"](function(e){r(e)})})}},{key:"isConnected",value:function(){return void 0!==this._mqttConnection}},{key:"_topicFor",value:function(e){return this.deviceId()+"/"+e}}]),n}(y["default"]);t["default"]=b}).call(t,n(3).Buffer)},function(e,t,n){function r(e){if(null==e)return!0;if(u(e)&&(a(e)||"string"==typeof e||"function"==typeof e.splice||c(e)||f(e)||s(e)))return!e.length;var t=o(e);if(t==h||t==p)return!e.size;if(l(e))return!i(e).length;for(var n in e)if(v.call(e,n))return!1;return!0}var i=n(45),o=n(238),s=n(35),a=n(23),u=n(12),c=n(37),l=n(46),f=n(41),h="[object Map]",p="[object Set]",d=Object.prototype,v=d.hasOwnProperty;e.exports=r},function(e,t,n){(function(t){"use strict";function r(e){var t;e.auth&&(t=e.auth.match(/^(.+):(.+)$/),t?(e.username=t[1],e.password=t[2]):e.username=e.auth)}function i(e,t){function n(e){return t.servers&&(e._reconnectCount&&e._reconnectCount!==t.servers.length||(e._reconnectCount=0),t.host=t.servers[e._reconnectCount].host,t.port=t.servers[e._reconnectCount].port,t.protocol=t.servers[e._reconnectCount].protocol?t.servers[e._reconnectCount].protocol:t.defaultProtocol,t.hostname=t.host,e._reconnectCount++),c[t.protocol](e,t)}if("object"!=typeof e||t||(t=e,e=null),t=t||{},e){var i=a.parse(e,!0);if(null!=i.port&&(i.port=Number(i.port)),t=u(i,t),null===t.protocol)throw new Error("Missing protocol");t.protocol=t.protocol.replace(/:$/,"")}if(r(t),t.query&&"string"==typeof t.query.clientId&&(t.clientId=t.query.clientId),t.cert&&t.key){if(!t.protocol)throw new Error("Missing secure protocol key");if(["mqtts","wss","wxs"].indexOf(t.protocol)===-1)switch(t.protocol){case"mqtt":t.protocol="mqtts";break;case"ws":t.protocol="wss";break;case"wx":t.protocol="wxs";break;default:throw new Error('Unknown protocol for secure connection: "'+t.protocol+'"!')}}if(!c[t.protocol]){var s=["mqtts","wss"].indexOf(t.protocol)!==-1;t.protocol=["mqtt","mqtts","ws","wss","wx","wxs"].filter(function(e,t){return(!s||t%2!==0)&&"function"==typeof c[e]})[0]}if(t.clean===!1&&!t.clientId)throw new Error("Missing clientId for unclean clients");return t.protocol&&(t.defaultProtocol=t.protocol),new o(n,t)}var o=n(298),s=n(299),a=n(110),u=n(300),c={};"browser"!==t.title?(c.mqtt=n(329),c.tcp=n(329),c.ssl=n(331),c.tls=n(331),c.mqtts=n(331)):(c.wx=n(333),c.wxs=n(333)),c.ws=n(338),c.wss=n(338),e.exports=i,e.exports.connect=i,e.exports.MqttClient=o,e.exports.Store=s}).call(t,n(52))},function(e,t,n){(function(t,r){"use strict";function i(){return"mqttjs_"+Math.random().toString(16).substr(2,8)}function o(e,t,n){e.emit("packetsend",t);var r=p.writeToStream(t,e.stream);!r&&n?e.stream.once("drain",n):n&&n()}function s(e){e&&Object.keys(e).forEach(function(t){"function"==typeof e[t]&&(e[t](new Error("Connection closed")),delete e[t])})}function a(e,t,n){e.outgoingStore.put(t,function(r){return r?n&&n(r):void o(e,t,n)})}function u(){}function c(e,t){var n,r=this;if(!(this instanceof c))return new c(e,t);this.options=t||{};for(n in _)"undefined"==typeof this.options[n]?this.options[n]=_[n]:this.options[n]=t[n];this.options.clientId="string"==typeof this.options.clientId?this.options.clientId:i(),this.streamBuilder=e,this.outgoingStore=this.options.outgoingStore||new f,this.incomingStore=this.options.incomingStore||new f,this.queueQoSZero=void 0===this.options.queueQoSZero||this.options.queueQoSZero,this._resubscribeTopics={},this.messageIdToTopic={},this.pingTimer=null,this.connected=!1,this.disconnecting=!1,this.queue=[],this.connackTimer=null,this.reconnectTimer=null,this.nextId=Math.floor(65535*Math.random()),this.outgoing={},this.on("connect",function(){if(!this.disconnected){this.connected=!0;var e=null;e=this.outgoingStore.createStream(),e.once("readable",function(){function t(){var n,i=e.read(1);i&&(!r.disconnecting&&!r.reconnectTimer&&r.options.reconnectPeriod>0?(e.read(0),n=r.outgoing[i.messageId],r.outgoing[i.messageId]=function(e,r){n&&n(e,r),t()},r._sendPacket(i)):e.destroy&&e.destroy())}t()}).on("error",this.emit.bind(this,"error"))}}),this.on("close",function(){this.connected=!1,clearTimeout(this.connackTimer)}),this.on("connect",this._setupPingTimer),this.on("connect",function(){function e(){var n=t.shift(),i=null;n&&(i=n.packet,r._sendPacket(i,function(t){n.cb&&n.cb(t),e()}))}var t=this.queue;e()});var o=!0;this.on("connect",function(){!o&&this.options.clean&&Object.keys(this._resubscribeTopics).length>0&&(this.options.resubscribe?(this._resubscribeTopics.resubscribe=!0,this.subscribe(this._resubscribeTopics)):this._resubscribeTopics={}),o=!1}),this.on("close",function(){null!==r.pingTimer&&(r.pingTimer.clear(),r.pingTimer=null)}),this.on("close",this._setupReconnect),l.EventEmitter.call(this),this._setupStream()}var l=n(138),f=n(299),h=n(315),p=n(318),d=n(301).Writable,v=n(135),g=n(327),y=n(328),m=n(300),b=t.setImmediate||function(e){r.nextTick(e)},_={keepalive:60,reschedulePings:!0,protocolId:"MQTT",protocolVersion:4,reconnectPeriod:1e3,connectTimeout:3e4,clean:!0,resubscribe:!0};v(c,l.EventEmitter),c.prototype._setupStream=function(){function e(){r.nextTick(t)}function t(){var t=l.shift(),n=c;t?i._handlePacket(t,e):(c=null,n())}var n,i=this,s=new d,a=p.parser(this.options),c=null,l=[];this._clearReconnect(),this.stream=this.streamBuilder(this),a.on("packet",function(e){l.push(e)}),s._write=function(e,n,r){c=r,a.parse(e),t()},this.stream.pipe(s),this.stream.on("error",u),h(this.stream,this.emit.bind(this,"close")),n=Object.create(this.options),n.cmd="connect",o(this,n),a.on("error",this.emit.bind(this,"error")),this.stream.setMaxListeners(1e3),clearTimeout(this.connackTimer),this.connackTimer=setTimeout(function(){i._cleanUp(!0)},this.options.connectTimeout)},c.prototype._handlePacket=function(e,t){switch(this.emit("packetreceive",e),e.cmd){case"publish":this._handlePublish(e,t);break;case"puback":case"pubrec":case"pubcomp":case"suback":case"unsuback":this._handleAck(e),t();break;case"pubrel":this._handlePubrel(e,t);break;case"connack":this._handleConnack(e),t();break;case"pingresp":this._handlePingresp(e),t()}},c.prototype._checkDisconnecting=function(e){return this.disconnecting&&(e?e(new Error("client disconnecting")):this.emit("error",new Error("client disconnecting"))),this.disconnecting},c.prototype.publish=function(e,t,n,r){var i;"function"==typeof n&&(r=n,n=null);var o={qos:0,retain:!1,dup:!1};if(n=m(o,n),this._checkDisconnecting(r))return this;switch(i={cmd:"publish",topic:e,payload:t,qos:n.qos,retain:n.retain,messageId:this._nextId(),dup:n.dup},n.qos){case 1:case 2:this.outgoing[i.messageId]=r||u,this._sendPacket(i);break;default:this._sendPacket(i,r)}return this},c.prototype.subscribe=function(){var e,t,n=Array.prototype.slice.call(arguments),r=[],i=n.shift(),o=i.resubscribe,s=n.pop()||u,a=n.pop(),c=this;if(delete i.resubscribe,"string"==typeof i&&(i=[i]),"function"!=typeof s&&(a=s,s=u),t=y.validateTopics(i),null!==t)return b(s,new Error("Invalid topic "+t)),this;if(this._checkDisconnecting(s))return this;var l={qos:0};if(a=m(l,a),Array.isArray(i)?i.forEach(function(e){(c._resubscribeTopics[e]0&&(c._resubscribeTopics[e.topic]=e.qos,f.push(e.topic))}),c.messageIdToTopic[e.messageId]=f}return this.outgoing[e.messageId]=function(e,t){if(!e)for(var n=t.granted,i=0;i0?this.once("outgoingEmpty",setTimeout.bind(null,r,10)):r(),this)},c.prototype.removeOutgoingMessage=function(e){var t=this.outgoing[e];return delete this.outgoing[e],this.outgoingStore.del({messageId:e},function(){t(new Error("Message removed"))}),this},c.prototype.reconnect=function(e){var t=this,n=function(){e?(t.options.incomingStore=e.incomingStore,t.options.outgoingStore=e.outgoingStore):(t.options.incomingStore=null,t.options.outgoingStore=null),t.incomingStore=t.options.incomingStore||new f,t.outgoingStore=t.options.outgoingStore||new f,t.disconnecting=!1,t.disconnected=!1,t._deferredReconnect=null,t._reconnect()};return this.disconnecting&&!this.disconnected?this._deferredReconnect=n:n(),this},c.prototype._reconnect=function(){this.emit("reconnect"),this._setupStream()},c.prototype._setupReconnect=function(){var e=this;!e.disconnecting&&!e.reconnectTimer&&e.options.reconnectPeriod>0&&(this.reconnecting||(this.emit("offline"),this.reconnecting=!0),e.reconnectTimer=setInterval(function(){e._reconnect()},e.options.reconnectPeriod))},c.prototype._clearReconnect=function(){this.reconnectTimer&&(clearInterval(this.reconnectTimer),this.reconnectTimer=null)},c.prototype._cleanUp=function(e,t){t&&this.stream.on("close",t),e?(0===this.options.reconnectPeriod&&this.options.clean&&s(this.outgoing),this.stream.destroy()):this._sendPacket({cmd:"disconnect"},b.bind(null,this.stream.end.bind(this.stream))),this.disconnecting||(this._clearReconnect(),this._setupReconnect()),null!==this.pingTimer&&(this.pingTimer.clear(),this.pingTimer=null),t&&!this.connected&&(this.stream.removeListener("close",t),t())},c.prototype._sendPacket=function(e,t){if(!this.connected)return void(0===(e.qos||0)&&this.queueQoSZero||"publish"!==e.cmd?this.queue.push({packet:e,cb:t}):e.qos>0?(t=this.outgoing[e.messageId],this.outgoingStore.put(e,function(e){if(e)return t&&t(e)})):t&&t(new Error("No connection to broker")));if(this._shiftPingInterval(),"publish"!==e.cmd)return void o(this,e,t);switch(e.qos){case 2:case 1:a(this,e,t);break;case 0:default:o(this,e,t)}},c.prototype._setupPingTimer=function(){var e=this;!this.pingTimer&&this.options.keepalive&&(this.pingResp=!0,this.pingTimer=g(function(){e._checkPing()},1e3*this.options.keepalive))},c.prototype._shiftPingInterval=function(){this.pingTimer&&this.options.keepalive&&this.options.reschedulePings&&this.pingTimer.reschedule(1e3*this.options.keepalive)},c.prototype._checkPing=function(){this.pingResp?(this.pingResp=!1,this._sendPacket({cmd:"pingreq"})):this._cleanUp(!0)},c.prototype._handlePingresp=function(){this.pingResp=!0},c.prototype._handleConnack=function(e){var t=e.returnCode,n=["","Unacceptable protocol version","Identifier rejected","Server unavailable","Bad username or password","Not authorized"];if(clearTimeout(this.connackTimer),0===t)this.reconnecting=!1,this.emit("connect",e);else if(t>0){var r=new Error("Connection refused: "+n[t]);r.code=t,this.emit("error",r)}},c.prototype._handlePublish=function(e,t){var n=e.topic.toString(),r=e.payload,i=e.qos,o=e.messageId,s=this;switch(i){case 2:this.incomingStore.put(e,function(){s._sendPacket({cmd:"pubrec",messageId:o},t)});break;case 1:this.emit("message",n,r,e),this.handleMessage(e,function(e){return e?t&&t(e):void s._sendPacket({cmd:"puback",messageId:o},t)});break;case 0:this.emit("message",n,r,e),this.handleMessage(e,t)}},c.prototype.handleMessage=function(e,t){t()},c.prototype._handleAck=function(e){var t=e.messageId,n=e.cmd,r=null,i=this.outgoing[t],o=this;if(i){switch(n){case"pubcomp":case"puback":delete this.outgoing[t],this.outgoingStore.del(e,i);break;case"pubrec":r={cmd:"pubrel",qos:2,messageId:t},this._sendPacket(r);break;case"suback":if(delete this.outgoing[t],1===e.granted.length&&0!==(128&e.granted[0])){var s=this.messageIdToTopic[t];s&&s.forEach(function(e){delete o._resubscribeTopics[e]})}i(null,e);break;case"unsuback":delete this.outgoing[t],i(null);break;default:o.emit("error",new Error("unrecognized packet type"))}this.disconnecting&&0===Object.keys(this.outgoing).length&&this.emit("outgoingEmpty")}},c.prototype._handlePubrel=function(e,t){var n=e.messageId,r=this,i={cmd:"pubcomp",messageId:n};r.incomingStore.get(e,function(n,o){n||"pubrel"===o.cmd?r._sendPacket(i,t):(r.emit("message",o.topic,o.payload,o),r.incomingStore.put(e),r.handleMessage(o,function(e){return e?t&&t(e):void r._sendPacket(i,t)}))})},c.prototype._nextId=function(){var e=this.nextId++;return 65535===e&&(this.nextId=1),e},c.prototype.getLastMessageId=function(){return 1===this.nextId?65535:this.nextId-1},e.exports=c}).call(t,function(){return this}(),n(52))},function(e,t,n){(function(t){"use strict";function r(e){return this instanceof r?(this.options=e||{},this.options=i(a,e),void(this._inflights={})):new r(e)}var i=n(300),o=n(301).Readable,s={objectMode:!0},a={clean:!0};r.prototype.put=function(e,t){return this._inflights[e.messageId]=e,t&&t(),this},r.prototype.createStream=function(){var e=new o(s),n=this._inflights,r=Object.keys(this._inflights),i=!1,a=0;return e._read=function(){!i&&a0?("string"==typeof t||s.objectMode||Object.getPrototypeOf(t)===L.prototype||(t=i(t)),r?s.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):l(e,s,t,!0):s.ended?e.emit("error",new Error("stream.push() after EOF")):(s.reading=!1,s.decoder&&!n?(t=s.decoder.write(t),s.objectMode||0!==t.length?l(e,s,t,!1):m(e,s)):l(e,s,t,!1))):r||(s.reading=!1)}return h(s)}function l(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&g(e)),m(e,t)}function f(e,t){var n;return o(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function h(e){return!e.ended&&(e.needReadable||e.length=K?e=K:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function d(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!==e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=p(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function v(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,g(e)}}function g(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(q("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?j.nextTick(y,e):y(e))}function y(e){q("emit readable"),e.emit("readable"),k(e)}function m(e,t){t.readingMore||(t.readingMore=!0,j.nextTick(b,e,t))}function b(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=C(e,t.buffer,t.decoder),n}function C(e,t,n){var r;return eo.length?o.length:e;if(i+=s===o.length?o:o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function T(e,t){var n=L.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function B(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,j.nextTick(U,t,e))}function U(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function O(e,t){for(var n=0,r=e.length;n=t.highWaterMark||t.ended))return q("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?B(this):g(this),null;if(e=d(e,t),0===e&&t.ended)return 0===t.length&&B(this),null;var r=t.needReadable;q("need readable",r),(0===t.length||t.length-e0?I(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&B(this)),null!==i&&this.emit("data",i),i},u.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},u.prototype.pipe=function(e,t){function n(e,t){q("onunpipe"),e===h&&t&&t.hasUnpiped===!1&&(t.hasUnpiped=!0,o())}function i(){q("onend"),e.end()}function o(){q("cleanup"),e.removeListener("close",c),e.removeListener("finish",l),e.removeListener("drain",g),e.removeListener("error",u),e.removeListener("unpipe",n),h.removeListener("end",i),h.removeListener("end",f),h.removeListener("data",a),y=!0,!p.awaitDrain||e._writableState&&!e._writableState.needDrain||g()}function a(t){q("ondata"),m=!1;var n=e.write(t);!1!==n||m||((1===p.pipesCount&&p.pipes===e||p.pipesCount>1&&O(p.pipes,e)!==-1)&&!y&&(q("false write response, pause",h._readableState.awaitDrain),h._readableState.awaitDrain++,m=!0),h.pause())}function u(t){q("onerror",t),f(),e.removeListener("error",u),0===F(e,"error")&&e.emit("error",t)}function c(){e.removeListener("finish",l),f()}function l(){q("onfinish"),e.removeListener("close",c),f()}function f(){q("unpipe"),h.unpipe(e)}var h=this,p=this._readableState;switch(p.pipesCount){case 0:p.pipes=e;break;case 1:p.pipes=[p.pipes,e];break;default:p.pipes.push(e)}p.pipesCount+=1,q("pipe count=%d opts=%j",p.pipesCount,t);var d=(!t||t.end!==!1)&&e!==r.stdout&&e!==r.stderr,v=d?i:f;p.endEmitted?j.nextTick(v):h.once("end",v),e.on("unpipe",n);var g=_(h);e.on("drain",g);var y=!1,m=!1;return h.on("data",a),s(e,"error",u),e.once("close",c),e.once("finish",l),e.emit("pipe",h),p.flowing||(q("pipe resume"),h.resume()),e},u.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o0?this.tail.next=t:this.head=t,this.tail=t,++this.length},e.prototype.unshift=function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length},e.prototype.shift=function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}},e.prototype.clear=function(){this.head=this.tail=null,this.length=0},e.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,n=""+t.data;t=t.next;)n+=e+t.data;return n},e.prototype.concat=function(e){if(0===this.length)return o.alloc(0);if(1===this.length)return this.head.data;for(var t=o.allocUnsafe(e>>>0),n=this.head,r=0;n;)i(n.data,t,r),r+=n.data.length,n=n.next;return t},e}(),s&&s.inspect&&s.inspect.custom&&(e.exports.prototype[s.inspect.custom]=function(){var e=s.inspect({length:this.length});return this.constructor.name+" "+e})},91,function(e,t,n){"use strict";function r(e,t){var n=this,r=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return r||i?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||s.nextTick(o,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(s.nextTick(o,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function i(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function o(e,t){e.emit("error",t)}var s=n(303);e.exports={destroy:r,undestroy:i}},function(e,t,n){"use strict";function r(e){return this instanceof r?(c.call(this,e),l.call(this,e),e&&e.readable===!1&&(this.readable=!1),e&&e.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,e&&e.allowHalfOpen===!1&&(this.allowHalfOpen=!1),void this.once("end",i)):new r(e)}function i(){this.allowHalfOpen||this._writableState.ended||s.nextTick(o,this)}function o(e){e.end()}var s=n(303),a=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=r;var u=n(142);u.inherits=n(135);var c=n(302),l=n(310);u.inherits(r,c);for(var f=a(l.prototype),h=0;h-1?r:T.nextTick;l.WritableState=c;var O=n(142);O.inherits=n(135);var j={deprecate:n(311)},A=n(304),R=n(118).Buffer,F=i.Uint8Array||function(){},P=n(308);O.inherits(l,A),c.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(c.prototype,"buffer",{get:j.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}();var L;"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(L=Function.prototype[Symbol.hasInstance],Object.defineProperty(l,Symbol.hasInstance,{value:function(e){return!!L.call(this,e)||this===l&&(e&&e._writableState instanceof c)}})):L=function(e){return e instanceof this},l.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},l.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&a(e);return o&&!R.isBuffer(e)&&(e=s(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=u),r.ended?f(this,n):(o||h(this,r,e,n))&&(r.pendingcb++,i=d(this,r,o,e,t,n)),i},l.prototype.cork=function(){var e=this._writableState;e.corked++},l.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||w(this,e))},l.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(l.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),l.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},l.prototype._writev=null,l.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||C(this,r,n)},Object.defineProperty(l.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),l.prototype.destroy=P.destroy,l.prototype._undestroy=P.undestroy,l.prototype._destroy=function(e,t){this.end(),t(e)}}).call(t,n(52),n(57).setImmediate,function(){return this}())},function(e,t){(function(t){function n(e,t){function n(){if(!i){if(r("throwDeprecation"))throw new Error(t);r("traceDeprecation")?console.trace(t):console.warn(t),i=!0}return e.apply(this,arguments)}if(r("noDeprecation"))return e;var i=!1;return n}function r(e){try{if(!t.localStorage)return!1}catch(n){return!1}var r=t.localStorage[e];return null!=r&&"true"===String(r).toLowerCase()}e.exports=n}).call(t,function(){return this}())},function(e,t,n){"use strict";function r(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function i(e){var t=r(e);if("string"!=typeof t&&(m.isEncoding===b||!b(e)))throw new Error("Unknown encoding: "+e);return t||e}function o(e){this.encoding=i(e);var t;switch(this.encoding){case"utf16le":this.text=h,this.end=p,t=4;break;case"utf8":this.fillLast=c,t=4;break;case"base64":this.text=d,this.end=v,t=3;break;default:return this.write=g,void(this.end=y)}this.lastNeed=0,this.lastTotal=0,this.lastChar=m.allocUnsafe(t)}function s(e){return e<=127?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function a(e,t,n){var r=t.length-1;if(r=0?(i>0&&(e.lastNeed=i-1),i):--r=0?(i>0&&(e.lastNeed=i-2),i):--r=0?(i>0&&(2===i?i=0:e.lastNeed=i-3),i):0))}function u(e,t,n){if(128!==(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!==(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!==(192&t[2]))return e.lastNeed=2,"�"}}function c(e){var t=this.lastTotal-this.lastNeed,n=u(this,e,t);return void 0!==n?n:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function l(e,t){var n=a(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=n;var r=e.length-(n-this.lastNeed);return e.copy(this.lastChar,0,r),e.toString("utf8",t,r)}function f(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t}function h(e,t){if((e.length-t)%2===0){var n=e.toString("utf16le",t);if(n){var r=n.charCodeAt(n.length-1);if(r>=55296&&r<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],n.slice(0,-1)}return n}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function p(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var n=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,n)}return t}function d(e,t){var n=(e.length-t)%3;return 0===n?e.toString("base64",t):(this.lastNeed=3-n,this.lastTotal=3,1===n?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-n))}function v(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function g(e){return e.toString(this.encoding)}function y(e){return e&&e.length?this.write(e):""}var m=n(118).Buffer,b=m.isEncoding||function(e){switch(e=""+e,e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};t.StringDecoder=o,o.prototype.write=function(e){if(0===e.length)return"";var t,n;if(this.lastNeed){if(t=this.fillLast(e),void 0===t)return"";n=this.lastNeed,this.lastNeed=0}else n=0;return n0)&&this[this._states[this._stateCounter]]()&&!this.error;)this._stateCounter++,this._stateCounter>=this._states.length&&(this._stateCounter=0);return this._list.length},r.prototype._parseHeader=function(){var e=this._list.readUInt8(0);return this.packet.cmd=u.types[e>>u.CMD_SHIFT],this.packet.retain=0!==(e&u.RETAIN_MASK),this.packet.qos=e>>u.QOS_SHIFT&u.QOS_MASK,this.packet.dup=0!==(e&u.DUP_MASK),this._list.consume(1),!0},r.prototype._parseLength=function(){for(var e,t=0,n=1,r=0,i=!0;t<5&&(e=this._list.readUInt8(t++),r+=n*(e&u.LENGTH_MASK),n*=128,0!==(e&u.LENGTH_FIN_MASK));)if(this._list.length<=t){i=!1;break}return i&&(this.packet.length=r,this._list.consume(t)),i},r.prototype._parsePayload=function(){var e=!1;if(0===this.packet.length||this._list.length>=this.packet.length){switch(this._pos=0,this.packet.cmd){case"connect":this._parseConnect();break;case"connack":this._parseConnack();break;case"publish":this._parsePublish();break;case"puback":case"pubrec":case"pubrel":case"pubcomp":this._parseMessageId();break;case"subscribe":this._parseSubscribe();break;case"suback":this._parseSuback(); +break;case"unsubscribe":this._parseUnsubscribe();break;case"unsuback":this._parseUnsuback();break;case"pingreq":case"pingresp":case"disconnect":break;default:this._emitError(new Error("Not supported"))}e=!0}return e},r.prototype._parseConnect=function(){var e,t,n,r,i,o,s={},a=this.packet;if(e=this._parseString(),null===e)return this._emitError(new Error("Cannot parse protocolId"));if("MQTT"!==e&&"MQIsdp"!==e)return this._emitError(new Error("Invalid protocolId"));if(a.protocolId=e,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(a.protocolVersion=this._list.readUInt8(this._pos),3!==a.protocolVersion&&4!==a.protocolVersion)return this._emitError(new Error("Invalid protocol version"));if(this._pos++,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(s.username=this._list.readUInt8(this._pos)&u.USERNAME_MASK,s.password=this._list.readUInt8(this._pos)&u.PASSWORD_MASK,s.will=this._list.readUInt8(this._pos)&u.WILL_FLAG_MASK,s.will&&(a.will={},a.will.retain=0!==(this._list.readUInt8(this._pos)&u.WILL_RETAIN_MASK),a.will.qos=(this._list.readUInt8(this._pos)&u.WILL_QOS_MASK)>>u.WILL_QOS_SHIFT),a.clean=0!==(this._list.readUInt8(this._pos)&u.CLEAN_SESSION_MASK),this._pos++,a.keepalive=this._parseNum(),a.keepalive===-1)return this._emitError(new Error("Packet too short"));if(t=this._parseString(),null===t)return this._emitError(new Error("Packet too short"));if(a.clientId=t,s.will){if(n=this._parseString(),null===n)return this._emitError(new Error("Cannot parse will topic"));if(a.will.topic=n,r=this._parseBuffer(),null===r)return this._emitError(new Error("Cannot parse will payload"));a.will.payload=r}if(s.username){if(o=this._parseString(),null===o)return this._emitError(new Error("Cannot parse username"));a.username=o}if(s.password){if(i=this._parseBuffer(),null===i)return this._emitError(new Error("Cannot parse password"));a.password=i}return a},r.prototype._parseConnack=function(){var e=this.packet;return this._list.length<2?null:(e.sessionPresent=!!(this._list.readUInt8(this._pos++)&u.SESSIONPRESENT_MASK),e.returnCode=this._list.readUInt8(this._pos),e.returnCode===-1?this._emitError(new Error("Cannot parse return code")):void 0)},r.prototype._parsePublish=function(){var e=this.packet;return e.topic=this._parseString(),null===e.topic?this._emitError(new Error("Cannot parse topic")):void(e.qos>0&&!this._parseMessageId()||(e.payload=this._list.slice(this._pos,e.length)))},r.prototype._parseSubscribe=function(){var e,t,n=this.packet;if(1!==n.qos)return this._emitError(new Error("Wrong subscribe header"));if(n.subscriptions=[],this._parseMessageId())for(;this._posthis._list.length||r>this.packet.length?null:(t=this._list.toString("utf8",this._pos,r),this._pos+=n,t)},r.prototype._parseBuffer=function(){var e,t=this._parseNum(),n=t+this._pos;return t===-1||n>this._list.length||n>this.packet.length?null:(e=this._list.slice(this._pos,n),this._pos+=t,e)},r.prototype._parseNum=function(){if(this._list.length-this._pos<2)return-1;var e=this._list.readUInt16BE(this._pos);return this._pos+=2,e},r.prototype._newPacket=function(){return this.packet&&(this._list.consume(this.packet.length),this.emit("packet",this.packet)),this.packet=new a,!0},r.prototype._emitError=function(e){this.error=e,this.emit("error",e)},e.exports=r},function(e,t,n){function r(e){if(!(this instanceof r))return new r(e);if(this._bufs=[],this.length=0,"function"==typeof e){this._callback=e;var t=function(e){this._callback&&(this._callback(e),this._callback=null)}.bind(this);this.on("pipe",function(e){e.on("error",t)}),this.on("unpipe",function(e){e.removeListener("error",t)})}else this.append(e);i.call(this)}var i=n(321),o=n(133),s=n(118).Buffer;o.inherits(r,i),r.prototype._offset=function(e){var t,n=0,r=0;if(0===e)return[0,0];for(;rthis.length)&&(r=this.length),n>=this.length)return e||s.alloc(0);if(r<=0)return e||s.alloc(0);var i,o,a=!!e,u=this._offset(n),c=r-n,l=c,f=a&&t||0,h=u[1];if(0===n&&r==this.length){if(!a)return 1===this._bufs.length?this._bufs[0]:s.concat(this._bufs,this.length);for(o=0;oi)){this._bufs[o].copy(e,f,h,h+l);break}this._bufs[o].copy(e,f,h),f+=i,l-=i,h&&(h=0)}return e},r.prototype.shallowSlice=function(e,t){e=e||0,t=t||this.length,e<0&&(e+=this.length),t<0&&(t+=this.length);var n=this._offset(e),i=this._offset(t),o=this._bufs.slice(n[0],i[0]+1);return 0==i[1]?o.pop():o[o.length-1]=o[o.length-1].slice(0,i[1]),0!=n[1]&&(o[0]=o[0].slice(n[1])),new r(o)},r.prototype.toString=function(e,t,n){return this.slice(t,n).toString(e)},r.prototype.consume=function(e){for(;this._bufs.length;){if(!(e>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(e),this.length-=e;break}e-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},r.prototype.duplicate=function(){for(var e=0,t=new r;e65535||a%1!==0)return t.emit("error",new Error("Invalid keepalive")),!1;if(f+=2,f+=1,o){if("object"!=typeof o)return t.emit("error",new Error("Invalid will")),!1;if(!o.topic||"string"!=typeof o.topic)return t.emit("error",new Error("Invalid will topic")),!1;if(f+=x.byteLength(o.topic)+2,o.payload&&o.payload){if(!(o.payload.length>=0))return t.emit("error",new Error("Invalid will payload")),!1;f+="string"==typeof o.payload?x.byteLength(o.payload)+2:o.payload.length+2}else f+=2}var h=!1;if(null!=c){if(!w(c))return t.emit("error",new Error("Invalid username")),!1;h=!0,f+=x.byteLength(c)+2}if(null!=l){if(!h)return t.emit("error",new Error("Username is required to use password")),!1;if(!w(l))return t.emit("error",new Error("Invalid password")),!1;f+=_(l)+2}t.write(E.CONNECT_HEADER),v(t,f),b(t,r),t.write(4===i?E.VERSION4:E.VERSION3);var p=0;return p|=null!=c?E.USERNAME_MASK:0,p|=null!=l?E.PASSWORD_MASK:0,p|=o&&o.retain?E.WILL_RETAIN_MASK:0,p|=o&&o.qos?o.qos<0&&O(t,a),t.write(s))}function u(e,t){var n=e||{},r=n.cmd||"puback",i=n.messageId,o=n.dup&&"pubrel"===r?E.DUP_MASK:0,s=0;return"pubrel"===r&&(s=1),"number"!=typeof i?(t.emit("error",new Error("Invalid messageId")),!1):(t.write(E.ACKS[r][s][o][0]),v(t,2),O(t,i))}function c(e,t){var n=e||{},r=n.dup?E.DUP_MASK:0,i=n.messageId,o=n.subscriptions,s=0;if("number"!=typeof i)return t.emit("error",new Error("Invalid messageId")),!1;if(s+=2,"object"!=typeof o||!o.length)return t.emit("error",new Error("Invalid subscriptions")),!1;for(var a=0;a=0&&e<128?1:e>=128&&e<16384?2:e>=16384&&e<2097152?3:e>=2097152&&e<268435456?4:0}function d(e){var t=0,n=0,r=x.allocUnsafe(p(e));do t=e%128|0,e=e/128|0,e>0&&(t=128|t),r.writeUInt8(t,n++);while(e>0);return r}function v(e,t){var n=A[t];n||(n=d(t),t<16384&&(A[t]=n)),e.write(n)}function g(e,t){var n=x.byteLength(t);O(e,n),e.write(t,"utf8")}function y(e,t){return e.write(T[t])}function m(e,t){return e.write(B(t))}function b(e,t){"string"==typeof t?g(e,t):t?(O(e,t.length),e.write(t)):O(e,0)}function _(e){return e?e instanceof x?e.length:x.byteLength(e):0}function w(e){return"string"==typeof e||e instanceof x}var E=n(323),x=n(118).Buffer,k=x.allocUnsafe(0),I=x.from([0]),C=n(326),S=n(303).nextTick,T=C.cache,B=C.generateNumber,U=C.generateCache,O=y,j=!0;Object.defineProperty(r,"cacheNumbers",{get:function(){return O===y},set:function(e){e?(T&&0!==Object.keys(T).length||(j=!0),O=y):(j=!1,O=m)}});var A={};e.exports=r},function(e,t,n){"use strict";function r(e){var t=o.allocUnsafe(2);return t.writeUInt8(e>>8,0),t.writeUInt8(255&e,1),t}function i(){for(var e=0;e0){e=new Array(arguments.length-2);for(var t=0;tk)return void setTimeout(l,I,e,t,n);C&&"string"==typeof e&&(e=c.from(e,"utf8"));try{b.send(e)}catch(r){return n(r)}n()}function f(e){b.close(),e()}function h(){m.setReadable(x),m.setWritable(x),m.emit("connect")}function p(){m.end(),m.destroy()}function d(e){m.destroy(e)}function v(e){var t=e.data;t=t instanceof ArrayBuffer?c.from(t):c.from(t,"utf8"),x.push(t)}function g(){b.close()}function y(e,t){for(var n=new Array(e.length),r=0;r0&&void 0!==arguments[0]?arguments[0]:{};return n=(0,h["default"])(this._connectionOpts,n),new d["default"](function(n,r){t.getEndpointConfigs().then(function(i){var o=i.connection;if(void 0!==t._stompConnection)n(t._stompConnection);else try{var s=void 0;if("object"===("undefined"==typeof e?"undefined":c(e))&&""+e=="[object process]")s=t._tls?g["default"].overTCP(o.host,o.protocols.stomp.tlsPort,t._tlsOpts):g["default"].overTCP(o.host,o.protocols.stomp.port);else{var a=t._tls?t._webSocketOpts.tls.protocol:t._webSocketOpts.protocol,u=t._tls?o.protocols.webStomp.tlsPort:o.protocols.webStomp.port,l=a+"://"+o.host+":"+u+"/"+t._webSocketOpts.endpoint,f=new WebSocket(l);s=g["default"].over(f),s.heartbeat.outgoing=1e4,s.heartbeat.incoming=1e4,s.debug=null}var p=(0,h["default"])(t._connectionHeaders,{login:o.deviceId||o.client,passcode:o.secret,host:o.vhost});s.connect(p,function(){t._stompConnection=s,t.emit("connect"),n(t._stompConnection)},function(e){t.emit("error",e),t._stompConnection=void 0,r(e)})}catch(d){r(d)}})["catch"](function(e){r(e)})})}},{key:"isConnected",value:function(){return void 0!==this._stompConnection}},{key:"_subcriptionFor",value:function(e,t){return"/"+e+"/"+this.deviceId()+"."+t}},{key:"_destinationFor",value:function(e,t){return"/"+e+"/"+this.deviceId()+"/"+this.deviceId()+"."+t}},{key:"_autoAck",value:function(e){if(e)switch((0,u["default"])(w[this._protocol].ackTypes,e)||console.error("Wrong acknowledge type"),e){case"client":return!1;default:return!0}return!1}}]),n}(m["default"]);t["default"]=E}).call(t,n(52))},function(e,t,n){var r=n(341),i=n(342);e.exports=r.Stomp,e.exports.overTCP=i.overTCP,e.exports.overWS=i.overWS},function(e,t){(function(){var e,n,r,i,o={}.hasOwnProperty,s=[].slice;e={LF:"\n",NULL:"\0"},r=function(){function t(e,t,n){this.command=e,this.headers=null!=t?t:{},this.body=null!=n?n:""}var n;return t.prototype.toString=function(){var n,r,i,s,a;n=[this.command],s=this.headers["content-length"]===!1,s&&delete this.headers["content-length"],i=this.headers;for(r in i)o.call(i,r)&&(a=i[r],n.push(r+":"+a));return this.body&&!s&&n.push("content-length:"+t.sizeOfUTF8(this.body)),n.push(e.LF+this.body),n.join(e.LF)},t.sizeOfUTF8=function(e){return e?encodeURI(e).match(/%..|./g).length:0},n=function(n){var r,i,o,s,a,u,c,l,f,h,p,d,v,g,y,m,b,_;for(s=n.search(RegExp(""+e.LF+e.LF)),a=n.substring(0,s).split(e.LF),o=a.shift(),u={},_=function(e){return e.replace(/^\s+|\s+$/g,"")},g=a.reverse(),f=0,d=g.length;fm)&&(i=n.charAt(c),i!==e.NULL);c=y<=m?++h:--h)r+=i;return new t(o,u,r)},t.unmarshall=function(t){var r,i,o,s;return i=t.split(RegExp(""+e.NULL+e.LF+"*")),s={frames:[],partial:""},s.frames=function(){var e,t,o,s;for(o=i.slice(0,-1),s=[],e=0,t=o.length;e>> "+i);;){if(!(i.length>this.maxWebSocketFrameSize))return this.ws.send(i);this.ws.send(i.substring(0,this.maxWebSocketFrameSize)),i=i.substring(this.maxWebSocketFrameSize),"function"==typeof this.debug&&this.debug("remaining = "+i.length)}},t.prototype._setupHeartbeat=function(t){var r,o,s,a,u,c;if((r=t.version)===i.VERSIONS.V1_1||r===i.VERSIONS.V1_2)return o=function(){var e,n,r,i;for(r=t["heart-beat"].split(","),i=[],e=0,n=r.length;e>> PING"):void 0}}(this))),0!==this.heartbeat.incoming&&0!==a?(u=Math.max(this.heartbeat.incoming,a),"function"==typeof this.debug&&this.debug("check PONG every "+u+"ms"),this.ponger=i.setInterval(u,function(e){return function(){var t;if(t=n()-e.serverActivity,t>2*u)return"function"==typeof e.debug&&e.debug("did not receive server activity for the last "+t+"ms"),e.ws.close()}}(this))):void 0},t.prototype._parseConnect=function(){var e,t,n,r;switch(e=1<=arguments.length?s.call(arguments,0):[],r={},e.length){case 2:r=e[0],t=e[1];break;case 3:e[1]instanceof Function?(r=e[0],t=e[1],n=e[2]):(r.login=e[0],r.passcode=e[1],t=e[2]);break;case 4:r.login=e[0],r.passcode=e[1],t=e[2],n=e[3];break;default:r.login=e[0],r.passcode=e[1],t=e[2],n=e[3],r.host=e[4]}return[r,t,n]},t.prototype.connect=function(){var t,o,a,u;return t=1<=arguments.length?s.call(arguments,0):[],u=this._parseConnect.apply(this,t),a=u[0],this.connectCallback=u[1],o=u[2],"function"==typeof this.debug&&this.debug("Opening Web Socket..."),this.ws.onmessage=function(t){return function(i){var s,a,u,c,l,f,h,p,d,v,g,y,m;if(c="undefined"!=typeof ArrayBuffer&&i.data instanceof ArrayBuffer?(s=new Uint8Array(i.data),"function"==typeof t.debug?t.debug("--- got data length: "+s.length):void 0,function(){var e,t,n;for(n=[],e=0,t=s.length;e (https://www.worlize.com/)",contributors:["Iñaki Baz Castillo (http://dev.sipdoc.net)"],version:"1.0.26",repository:{type:"git",url:"https://github.com/theturtle32/WebSocket-Node.git"},homepage:"https://github.com/theturtle32/WebSocket-Node",engines:{node:">=0.10.0"},dependencies:{debug:"^2.2.0",nan:"^2.3.3","typedarray-to-buffer":"^3.1.2",yaeti:"^0.0.6"},devDependencies:{"buffer-equal":"^1.0.0",faucet:"^0.0.1",gulp:"git+https://github.com/gulpjs/gulp.git#4.0","gulp-jshint":"^2.0.4","jshint-stylish":"^2.2.1",jshint:"^2.0.0",tape:"^4.0.1"},config:{verbose:!1},scripts:{install:"(node-gyp rebuild 2> builderror.log) || (exit 0)",test:"faucet test/unit",gulp:"gulp"},main:"index",directories:{lib:"./lib"},browser:"lib/browser.js",license:"Apache-2.0"}},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function e(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(u){i=!0,o=u}finally{try{!r&&a["return"]&&a["return"]()}finally{if(i)throw o}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=function(){function e(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{};r(this,e),this.body=t.body,this.headers=t.headers;try{var s=this.headers.destination.split("/"),a=s[s.length-1].split("."),u=i(a,2);this.senderId=u[0],this.channelName=u[1]}catch(c){console.error("Wrong routing key format")}this._receiverId=n,this._discardMine=o.discardMine||!1,this._discardFromApi=o.discardFromApi||!1}return o(e,[{key:"blackListed",value:function(){return!(!this._discardMine||this._receiverId!==this.senderId||this.fromApi())||!(!this._discardFromApi||!this.fromApi())}},{key:"fromApi",value:function(){return this.headers&&this.headers[s.fromApiHeader]}}]),e}();t["default"]=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:[],n=arguments[1],r=t.map(function(t){return e._attachStreamHook(t,n)})||[];return r.length>0?f["default"].any(r):f["default"].reject("Missing stream hooks")}},{key:"_attachStreamHook",value:function(e,t){var n=this;return new f["default"](function(r,i){var o=e.deviceId,s=e.channel,a=e.stream,u="boolean"!=typeof e.cache||e.cache;void 0!==a||void 0!==s&&void 0!==o||i("Missing Stream or Device ID and Channel");var l=e.routingKey||n._defaultStreamRoutingKey,f=function(){},h=e.callback||f,p=(new Date).getTime();n._createChannel(""+p).then(function(e){n._amqpChannels[""+p]=e;var i=void 0;if(a)if(n.liveStreamExists(a)||(console.error("Stream "+a+" does not exist"),r(!1)),u){var f=n._cachedStreamQueue(a);i=n._amqpChannels[""+p].checkQueue(f,n._streamQueueArguments).then(function(){return n._amqpChannels[""+p].consume(f,function(e){h(n._parseContent(e.content),e.fields,e.properties)},(0,c["default"])(n._subscribeArgs,t))})}else{var d=n.exchangeName(a,n._liveStreamSuffix),v=n.tempQueue(a,n._liveStreamSuffix,p);i=n._amqpChannels[""+p].checkExchange(d).then(function(){return n._amqpChannels[""+p].assertQueue(v,n._streamQueueArguments)}).then(function(){return n._amqpChannels[""+p].bindQueue(v,d,l)}).then(function(){return n._amqpChannels[""+p].consume(v,function(e){h(n._parseContent(e.content),e.fields,e.properties)},(0,c["default"])(n._subscribeArgs,t))})}else{var g=n.exchangeName(o,s),y=n.tempQueue(o,s,p);i=n._amqpChannels[""+p].checkExchange(g).then(function(){return n._amqpChannels[""+p].assertQueue(y,n._streamQueueArguments)}).then(function(){return n._amqpChannels[""+p].bindQueue(y,g,l)}).then(function(){return n._amqpChannels[""+p].consume(y,function(e){h(n._parseContent(e.content),e.fields,e.properties)},(0,c["default"])(n._subscribeArgs,t))})}return i}).then(function(){r(!0)})["catch"](function(e){i(e)})})}},{key:"_cachedStreamQueue",value:function(e){return this.liveStreamByName(e)+"."+this._liveStreamSuffix}}]),t}(p["default"]);delete v.onReceive,delete v.publish,delete v._routingKeyFor,t["default"]=v},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:[],n=arguments[1];return new f["default"](function(r,i){e.connect().then(function(o){var s=function(){};t.forEach(function(t){var n=t.stream,o=t.deviceId,s=t.channel,a=t.qos,u="boolean"!=typeof t.cache||t.cache;void 0!==n||void 0!==s&&void 0!==o||i("Missing Stream or Device ID and Channel"),n?(e.liveStreamExists(n)||(console.error("Stream "+n+" does not exist"),r(!1)),e._topics[e._streamTopicFor(n)]=u?1:0):e._topics[e._streamChannelTopicFor(o,s)]=a||e._connectionOpts.qos}),o.subscribe(e._topics,(0,c["default"])(e._connectionOpts,n),function(n){n?i(!1):(o.on("message",function(n,r){var i=n.split("/"),o=t.filter(function(t){return e.liveStreamByName(t.stream)===i[0]||t.deviceId===i[0]&&t.channel===i[1]}),a=s;o.length>0&&(a=o[0].callback||s),a(n,e._parseContent(r))}),r(!0))})})["catch"](function(e){i(e)})})}},{key:"_streamChannelTopicFor",value:function(e,t){return e+"/"+t}},{key:"_streamTopicFor",value:function(e){return this.liveStreamByName(e)+"/"+this._liveStreamSuffix}}]),t}(p["default"]);delete d.onReceive,delete d.publish,delete d._topicFor,t["default"]=d},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:[],n=arguments[1],r=t.map(function(t){return e._attachStreamHook(t,n)})||[];return r.length>0?f["default"].any(r):f["default"].reject("Missing stream hooks")}},{key:"unsubscribe",value:function(e,t){var n=this;return new f["default"](function(r,i){if(void 0===n._stompConnection)i("Invalid connection");else{var o=n._topicFor(e,t),s=n._subscriptions[o];s.unsubscribe(o),delete n._subscriptions[o],r(!0)}})}},{key:"disconnect",value:function(){var e=this;return new f["default"](function(t,n){if(void 0===e._stompConnection)n("Invalid connection");else{for(var r in e._subscriptions)r&&e._subscriptions[r].unsubscribe();e._subscriptions={},e._stompConnection.disconnect(function(){e._stompConnection=void 0,t(!0)})["catch"](function(e){n(e)})}})}},{key:"_attachStreamHook",value:function(e,t){var n=this;return t=(0,c["default"])({},t),new f["default"](function(t,r){var i=e.stream,o=e.deviceId,s=e.channel,a="boolean"!=typeof e.cache||e.cache,u=function(){},c=e.callback||u;void 0!==i||void 0!==s&&void 0!==o||r("Missing Stream or Device ID and Channel"),n.connect().then(function(e){var r=void 0,u=void 0;i?(n.liveStreamExists(i)||(console.error("Stream "+i+" does not exist"),t(!1)),a?r=n._cachedStreamTopicFor(i):(r=n._streamTopicFor(i),u=n.tempQueue(i,n._liveStreamSuffix))):(r=n._streamChannelTopicFor(o,s),u=n.tempQueue(o,s));var l={};u&&(l["x-queue-name"]=u);var f=function(e){c(n._parseContent(e.body),e.headers)},h=e.subscribe(r,f,l);n._subscriptions[r]=h,t(!0)})["catch"](function(e){r(e)})})}},{key:"_streamChannelTopicFor",value:function(e,t,n,r){return"/"+(n||this._exchangePrefix)+"/"+e+"."+t+"/"+(r||this._defaultPattern)}},{key:"_cachedStreamTopicFor",value:function(e,t){return"/"+(t||this._existingQueuePrefix)+"/"+this.liveStreamByName(e)+"."+this._liveStreamSuffix}},{key:"_streamTopicFor",value:function(e,t,n){return"/"+(t||this._exchangePrefix)+"/"+this.liveStreamByName(e)+"."+(this._liveStreamSuffix+"/"+(n||this._defaultPattern))}}]),t}(p["default"]);delete v.onReceive,delete v.publish,delete v._subcriptionFor,delete v._destinationFor,t["default"]=v},function(e,t,n,r,i){(function(e,o){function s(e,n){var r={seen:[],stylize:u};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),y(n)?r.showHidden=n:n&&t._extend(r,n),x(r.showHidden)&&(r.showHidden=!1),x(r.depth)&&(r.depth=2),x(r.colors)&&(r.colors=!1),x(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=a),l(r,e,r.depth)}function a(e,t){var n=s.styles[t];return n?"["+s.colors[n][0]+"m"+e+"["+s.colors[n][1]+"m":e}function u(e,t){return e}function c(e){var t={};return e.forEach(function(e,n){t[e]=!0}),t}function l(e,n,r){if(e.customInspect&&n&&T(n.inspect)&&n.inspect!==t.inspect&&(!n.constructor||n.constructor.prototype!==n)){var i=n.inspect(r,e);return w(i)||(i=l(e,i,r)),i}var o=f(e,n);if(o)return o;var s=Object.keys(n),a=c(s);if(e.showHidden&&(s=Object.getOwnPropertyNames(n)),S(n)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return h(n);if(0===s.length){if(T(n)){var u=n.name?": "+n.name:"";return e.stylize("[Function"+u+"]","special")}if(k(n))return e.stylize(RegExp.prototype.toString.call(n),"regexp");if(C(n))return e.stylize(Date.prototype.toString.call(n),"date");if(S(n))return h(n)}var y="",m=!1,b=["{","}"];if(g(n)&&(m=!0,b=["[","]"]),T(n)){var _=n.name?": "+n.name:"";y=" [Function"+_+"]"}if(k(n)&&(y=" "+RegExp.prototype.toString.call(n)),C(n)&&(y=" "+Date.prototype.toUTCString.call(n)),S(n)&&(y=" "+h(n)),0===s.length&&(!m||0==n.length))return b[0]+y+b[1];if(r<0)return k(n)?e.stylize(RegExp.prototype.toString.call(n),"regexp"):e.stylize("[Object]","special");e.seen.push(n);var E;return E=m?p(e,n,r,a,s):s.map(function(t){return d(e,n,r,a,t,m)}),e.seen.pop(),v(E,y,b)}function f(e,t){if(x(t))return e.stylize("undefined","undefined");if(w(t)){var n="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(n,"string")}return _(t)?e.stylize(""+t,"number"):y(t)?e.stylize(""+t,"boolean"):m(t)?e.stylize("null","null"):void 0}function h(e){return"["+Error.prototype.toString.call(e)+"]"}function p(e,t,n,r,i){for(var o=[],s=0,a=t.length;s-1&&(a=o?a.split("\n").map(function(e){return" "+e}).join("\n").substr(2):"\n"+a.split("\n").map(function(e){return" "+e}).join("\n"))):a=e.stylize("[Circular]","special")),x(s)){if(o&&i.match(/^\d+$/))return a;s=JSON.stringify(""+i),s.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.substr(1,s.length-2),s=e.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=e.stylize(s,"string"))}return s+": "+a}function v(e,t,n){var r=0,i=e.reduce(function(e,t){return r++,t.indexOf("\n")>=0&&r++,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0);return i>60?n[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+n[1]:n[0]+t+" "+e.join(", ")+" "+n[1]}function g(e){return Array.isArray(e)}function y(e){return"boolean"==typeof e}function m(e){return null===e}function b(e){return null==e}function _(e){return"number"==typeof e}function w(e){return"string"==typeof e}function E(e){return"symbol"==typeof e}function x(e){return void 0===e}function k(e){return I(e)&&"[object RegExp]"===U(e)}function I(e){return"object"==typeof e&&null!==e}function C(e){return I(e)&&"[object Date]"===U(e)}function S(e){return I(e)&&("[object Error]"===U(e)||e instanceof Error)}function T(e){return"function"==typeof e}function B(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||"undefined"==typeof e}function U(e){return Object.prototype.toString.call(e)}function O(e){return e<10?"0"+e.toString(10):e.toString(10)}function j(){var e=new Date,t=[O(e.getHours()),O(e.getMinutes()),O(e.getSeconds())].join(":");return[e.getDate(),L[e.getMonth()],t].join(" ")}function A(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var R=/%[sdj%]/g;t.format=function(e){if(!w(e)){for(var t=[],n=0;n=i)return e;switch(e){case"%s":return String(r[n++]);case"%d":return Number(r[n++]);case"%j":try{return JSON.stringify(r[n++])}catch(t){return"[Circular]"}default:return e}}),a=r[n];n0)if(t.ended&&!i){var s=new Error("stream.push() after EOF");e.emit("error",s)}else if(t.endEmitted&&i){var s=new Error("stream.unshift() after end event");e.emit("error",s)}else!t.decoder||i||r||(n=t.decoder.write(n)),i||(t.reading=!1),t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,i?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&v(e)),y(e,t);else i||(t.reading=!1);return l(t)}function l(e){return!e.ended&&(e.needReadable||e.length=R)e=R;else{e--;for(var t=1;t<32;t<<=1)e|=e>>t;e++}return e}function h(e,t){return 0===t.length&&t.ended?0:t.objectMode?0===e?0:1:isNaN(e)||O.isNull(e)?t.flowing&&t.buffer.length?t.buffer[0].length:t.length:e<=0?0:(e>t.highWaterMark&&(t.highWaterMark=f(e)),e>t.length?t.ended?t.length:(t.needReadable=!0,0):e)}function p(e,t){var n=null;return O.isBuffer(t)||O.isString(t)||O.isNullOrUndefined(t)||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function d(e,t){if(t.decoder&&!t.ended){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,v(e)}function v(e){var n=e._readableState;n.needReadable=!1,n.emittedReadable||(A("emitReadable",n.flowing),n.emittedReadable=!0,n.sync?t.nextTick(function(){g(e)}):g(e))}function g(e){A("emit readable"),e.emit("readable"),E(e)}function y(e,n){n.readingMore||(n.readingMore=!0,t.nextTick(function(){m(e,n)}))}function m(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length=i)n=o?r.join(""):T.concat(r,i),r.length=0;else if(e0)throw new Error("endReadable called on non-empty stream");n.endEmitted||(n.ended=!0,t.nextTick(function(){n.endEmitted||0!==n.length||(n.endEmitted=!0,e.readable=!1,e.emit("end"))}))}function I(e,t){for(var n=0,r=e.length;n0)&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return A("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?k(this):v(this),null;if(e=h(e,t),0===e&&t.ended)return 0===t.length&&k(this),null;var r=t.needReadable;A("need readable",r),(0===t.length||t.length-e0?x(e,t):null,O.isNull(i)&&(t.needReadable=!0,e=0),t.length-=e,0!==t.length||t.ended||(t.needReadable=!0),n!==e&&t.ended&&0===t.length&&k(this),O.isNull(i)||this.emit("data",i),i},u.prototype._read=function(e){this.emit("error",new Error("not implemented"))},u.prototype.pipe=function(e,n){function r(e){A("onunpipe"),e===f&&o()}function i(){A("onend"),e.end()}function o(){A("cleanup"),e.removeListener("close",u),e.removeListener("finish",c),e.removeListener("drain",v),e.removeListener("error",a),e.removeListener("unpipe",r),f.removeListener("end",i),f.removeListener("end",o),f.removeListener("data",s),!h.awaitDrain||e._writableState&&!e._writableState.needDrain||v()}function s(t){A("ondata");var n=e.write(t);!1===n&&(A("false write response, pause",f._readableState.awaitDrain),f._readableState.awaitDrain++,f.pause())}function a(t){A("onerror",t),l(),e.removeListener("error",a),0===B.listenerCount(e,"error")&&e.emit("error",t)}function u(){ +e.removeListener("finish",c),l()}function c(){A("onfinish"),e.removeListener("close",u),l()}function l(){A("unpipe"),f.unpipe(e)}var f=this,h=this._readableState;switch(h.pipesCount){case 0:h.pipes=e;break;case 1:h.pipes=[h.pipes,e];break;default:h.pipes.push(e)}h.pipesCount+=1,A("pipe count=%d opts=%j",h.pipesCount,n);var p=(!n||n.end!==!1)&&e!==t.stdout&&e!==t.stderr,d=p?i:o;h.endEmitted?t.nextTick(d):f.once("end",d),e.on("unpipe",r);var v=b(f);return e.on("drain",v),f.on("data",s),e._events&&e._events.error?S(e._events.error)?e._events.error.unshift(a):e._events.error=[a,e._events.error]:e.on("error",a),e.once("close",u),e.once("finish",c),e.emit("pipe",f),h.flowing||(A("pipe resume"),f.resume()),e},u.prototype.unpipe=function(e){var t=this._readableState;if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this),this);if(!e){var n=t.pipes,r=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var i=0;i1){for(var n=[],r=0;r {\n this._createChannel('input', opts).then((ch) => {\n return when.all([\n ch.checkQueue(`${this.deviceId()}.${this._inboxTopic}`, this._inputQueueArgs),\n ch.consume(`${this.deviceId()}.${this._inboxTopic}`, (message) => {\n // Create message object\n const amqpMessage = new AmqpMessage(message, this._deviceId, opts);\n const ackNeeded = this._autoAck(opts.ack);\n // Check if should be accepted or not\n if (amqpMessage.blackListed()) {\n if (ackNeeded) { ch.nack(message, opts.allUpTo, opts.requeue); }\n return;\n }\n // Call message callback\n callback(this._parseContent(amqpMessage.content), amqpMessage.fields, amqpMessage.properties);\n // Check if ACK is needed\n if (ackNeeded) { ch.ack(message, opts.allUpTo); }\n }, opts)\n ]);\n }).then((res) => {\n resolve(res);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Publish a message on a specific channel\n *\n * @param {String} channel - channel name on which you want to publish a message\n * @param {Object} message - the message payload\n * @param {Object} opts - publication options\n * @return promise containing the result of the subscription\n */\n publish(channel, message, opts = {}) {\n opts = merge(this._publishArgs, opts);\n return new Promise((resolve, reject) => {\n this._createChannel('output', opts).then((ch) => {\n const bufferedMessage = new Buffer(this._encapsulateContent(message));\n const promises = [\n ch.checkExchange(this.deviceId()),\n ch.publish(this.deviceId(), this._routingKeyFor(channel), bufferedMessage, opts)\n ];\n if (opts.withConfirm === true) {\n promises.push(ch.waitForConfirms());\n }\n return when.all(promises);\n }).then((res) => {\n resolve(res);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Destroy the connection between the amqp client and broker\n *\n * @return a promise containing the result of the operation\n */\n disconnect() {\n return new Promise((resolve, reject) => {\n if (this._amqpConnection === undefined) {\n reject('Not Connected');\n } else {\n this._amqpConnection.close().then(() => {\n this._amqpConnection = undefined;\n this._amqpChannels = {};\n this.emit('disconnect');\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n }\n });\n }\n\n /**\n * Establish an amqp connection with the broker\n * using configurations retrieved from the endpoint.\n * If the connnection already exists, returns the current connnection\n *\n * @return a promise containing current connection\n */\n connect(opts = {}) {\n let connectionOpts = merge(this._connectionOpts, opts);\n\n return new Promise((resolve, reject) => {\n this.getEndpointConfigs().then((endpointConfigs) => {\n const connectionParams = endpointConfigs.connection;\n if (this._amqpConnection !== undefined) {\n resolve(this._amqpConnection);\n } else {\n let connectionString = '';\n if (this._tls) {\n connectionString = `${this._tlsProtocol}://${connectionParams.deviceId || connectionParams.client}:` +\n `${connectionParams.secret}@${connectionParams.host}:` +\n `${connectionParams.protocols.amqp.tlsPort}/${connectionParams.vhost.replace('/', '%2f')}`;\n connectionOpts = merge(connectionOpts, this._tlsOpts);\n } else {\n connectionString = `${this._protocol}://${connectionParams.deviceId || connectionParams.client}:` +\n `${connectionParams.secret}@${connectionParams.host}:` +\n `${connectionParams.protocols.amqp.port}/${connectionParams.vhost.replace('/', '%2f')}`;\n }\n amqp.connect(connectionString, connectionOpts).then((conn) => {\n conn.on('error', (err) => {\n this.emit('error', err);\n reject(err);\n });\n conn.on('close', (err) => {\n this.emit('close', err);\n this._amqpConnection = undefined;\n });\n conn.on('blocked', (reason) => {\n this.emit('blocked', reason);\n console.warn(reason); // eslint-disable-line no-console\n });\n conn.on('unblocked', (reason) => {\n this.emit('unblocked', reason);\n console.warn(reason); // eslint-disable-line no-console\n });\n this._amqpConnection = conn;\n this.emit('connect');\n resolve(this._amqpConnection);\n }).catch((reason) => {\n reject(reason);\n });\n }\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n isConnected() {\n return (this._amqpConnection !== undefined);\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Creates a channel on current connection\n *\n * @private\n * @param {String} channelName - indicates the channel name\n * @param {Object} opts - channel options\n * @return a promise containing the current channel\n */\n _createChannel(channelName, opts = {}) {\n channelName = `${channelName}${(opts.withConfirm === true) ? 'WithConfirm' : ''}`;\n return new Promise((resolve, reject) => {\n if (this._amqpChannels[channelName]) {\n resolve(this._amqpChannels[channelName]);\n } else {\n this.connect().then((conn) => {\n if (opts.withConfirm === true) {\n return conn.createConfirmChannel();\n } else {\n return conn.createChannel();\n }\n }).then((ch) => {\n this._amqpChannels[channelName] = ch;\n resolve(ch);\n }).catch((reason) => {\n reject(reason);\n });\n }\n });\n }\n\n /**\n * Close a channel on current connection\n *\n * @private\n * @param {String} channelName - indicates if the channel is input or output\n * @return a promise containing the result of the operation\n */\n _closeChannel(channelName, opts = {}) {\n channelName = `${channelName}${(opts.withConfirm === true) ? 'WithConfirm' : ''}`;\n return new Promise((resolve, reject) => {\n const ch = this._amqpChannels[channelName];\n if (ch === undefined) {\n reject('Invalid Channel Object');\n } else {\n ch.close().then(() => {\n this._amqpChannels[channelName] = undefined;\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n }\n });\n }\n\n /**\n * Generate the routing key for a specific channel\n *\n * @private\n * @param {String} channel - channel name on which you want to publish a message\n * @return a string that represents the routing key for that channel\n */\n _routingKeyFor(channel) {\n return `${this.deviceId()}.${channel}`;\n }\n\n /**\n * Check if the SDK have to automatically ack messages\n *\n * @private\n * @param {String} ack - the ack type, it should be 'manual' or 'auto'\n * @return boolean - true if messages have to be autoacked, false otherwise\n */\n _autoAck(ack) {\n if (ack) {\n if (!_.includes(CONFIG[this._protocol].ackTypes, ack)) {\n console.error('Wrong acknowledge type'); // eslint-disable-line no-console\n }\n switch (ack) {\n case 'auto':\n return true;\n default:\n return false;\n }\n }\n return true;\n }\n\n}\n\nexport default AmqpClient;\n"],"sourceRoot":"./src"} \ No newline at end of file +{"version":3,"sources":["protocols/amqpClient.js"],"names":["CONFIG","require","AmqpClient","opts","_amqpConnection","undefined","_amqpChannels","amqpOptions","amqp","_protocol","protocol","_tlsProtocol","tls","_inputQueueArgs","inputQueueArgs","_deviceExchangeArgs","deviceExchangeArgs","_subscribeArgs","subscribeArgs","_publishArgs","publishArgs","_connectionOpts","connectionOpts","callback","noAck","ack","Promise","resolve","reject","_createChannel","then","ch","when","all","checkQueue","deviceId","_inboxTopic","consume","message","amqpMessage","AmqpMessage","_deviceId","ackNeeded","_autoAck","blackListed","nack","allUpTo","requeue","_parseContent","content","fields","properties","res","catch","reason","channel","bufferedMessage","Buffer","_encapsulateContent","promises","checkExchange","publish","_routingKeyFor","withConfirm","push","waitForConfirms","close","emit","getEndpointConfigs","endpointConfigs","connectionParams","connection","connectionString","_tls","client","secret","host","protocols","tlsPort","vhost","replace","_tlsOpts","port","connect","conn","on","err","console","warn","channelName","createConfirmChannel","createChannel","ackTypes","error","SpaceBunny"],"mappings":"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","file":"amqpClient.js","sourcesContent":["/**\n * A module that exports an AmqpClient client\n * which inherits from the SpaceBunny base client\n * @module AmqpClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\nimport when from 'when';\nimport _ from 'lodash';\n\n// Import amqplib\nimport amqp from 'amqplib';\n\n// Import SpaceBunny main module from which AmqpClient inherits\nimport SpaceBunny from '../spacebunny';\nimport AmqpMessage from '../messages/amqpMessage';\nconst CONFIG = require('../../config/constants').CONFIG;\n\nclass AmqpClient extends SpaceBunny {\n\n /**\n * @constructor\n * @param {Object} opts - options must contain Device-Key or connection options\n * (deviceId and secret) for devices.\n */\n constructor(opts) {\n super(opts);\n this._amqpConnection = undefined;\n this._amqpChannels = {};\n const amqpOptions = CONFIG.amqp;\n this._protocol = amqpOptions.protocol;\n this._tlsProtocol = amqpOptions.tls.protocol;\n this._inputQueueArgs = amqpOptions.inputQueueArgs;\n this._deviceExchangeArgs = amqpOptions.deviceExchangeArgs;\n this._subscribeArgs = amqpOptions.subscribeArgs;\n this._publishArgs = amqpOptions.publishArgs;\n this._connectionOpts = amqpOptions.connectionOpts;\n }\n\n /**\n * Subscribe to input channel\n *\n * @param {function} callback - function called every time a message is received\n * passing the current message as argument\n * @param {Object} options - subscription options\n * @return promise containing the result of the subscription\n */\n onReceive(callback, opts) {\n opts = merge(this._subscribeArgs, opts);\n opts.noAck = (opts.ack === null);\n // Receive messages from imput queue\n return new Promise((resolve, reject) => {\n this._createChannel('input', opts).then((ch) => {\n return when.all([\n ch.checkQueue(`${this.deviceId()}.${this._inboxTopic}`, this._inputQueueArgs),\n ch.consume(`${this.deviceId()}.${this._inboxTopic}`, (message) => {\n // Create message object\n const amqpMessage = new AmqpMessage(message, this._deviceId, opts);\n const ackNeeded = this._autoAck(opts.ack);\n // Check if should be accepted or not\n if (amqpMessage.blackListed()) {\n if (ackNeeded) { ch.nack(message, opts.allUpTo, opts.requeue); }\n return;\n }\n // Call message callback\n callback(this._parseContent(amqpMessage.content), amqpMessage.fields, amqpMessage.properties);\n // Check if ACK is needed\n if (ackNeeded) { ch.ack(message, opts.allUpTo); }\n }, opts)\n ]);\n }).then((res) => {\n resolve(res);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Publish a message on a specific channel\n *\n * @param {String} channel - channel name on which you want to publish a message\n * @param {Object} message - the message payload\n * @param {Object} opts - publication options\n * @return promise containing the result of the subscription\n */\n publish(channel, message, opts = {}) {\n opts = merge(this._publishArgs, opts);\n return new Promise((resolve, reject) => {\n this._createChannel('output', opts).then((ch) => {\n const bufferedMessage = new Buffer(this._encapsulateContent(message));\n const promises = [\n ch.checkExchange(this.deviceId()),\n ch.publish(this.deviceId(), this._routingKeyFor(channel), bufferedMessage, opts)\n ];\n if (opts.withConfirm === true) {\n promises.push(ch.waitForConfirms());\n }\n return when.all(promises);\n }).then((res) => {\n resolve(res);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Destroy the connection between the amqp client and broker\n *\n * @return a promise containing the result of the operation\n */\n disconnect() {\n return new Promise((resolve, reject) => {\n if (this._amqpConnection === undefined) {\n reject('Not Connected');\n } else {\n this._amqpConnection.close().then(() => {\n this._amqpConnection = undefined;\n this._amqpChannels = {};\n this.emit('disconnect');\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n }\n });\n }\n\n /**\n * Establish an amqp connection with the broker\n * using configurations retrieved from the endpoint.\n * If the connnection already exists, returns the current connnection\n *\n * @return a promise containing current connection\n */\n connect(opts = {}) {\n let connectionOpts = merge(this._connectionOpts, opts);\n\n return new Promise((resolve, reject) => {\n this.getEndpointConfigs().then((endpointConfigs) => {\n const connectionParams = endpointConfigs.connection;\n if (this._amqpConnection !== undefined) {\n resolve(this._amqpConnection);\n } else {\n let connectionString = '';\n if (this._tls) {\n connectionString = `${this._tlsProtocol}://${connectionParams.deviceId || connectionParams.client}:` +\n `${connectionParams.secret}@${connectionParams.host}:` +\n `${connectionParams.protocols.amqp.tlsPort}/${connectionParams.vhost.replace('/', '%2f')}`;\n connectionOpts = merge(connectionOpts, this._tlsOpts);\n } else {\n connectionString = `${this._protocol}://${connectionParams.deviceId || connectionParams.client}:` +\n `${connectionParams.secret}@${connectionParams.host}:` +\n `${connectionParams.protocols.amqp.port}/${connectionParams.vhost.replace('/', '%2f')}`;\n }\n return amqp.connect(connectionString, connectionOpts).then((conn) => {\n conn.on('error', (err) => {\n this.emit('error', err);\n reject(err);\n });\n conn.on('close', (err) => {\n this.emit('close', err);\n this._amqpConnection = undefined;\n });\n conn.on('blocked', (reason) => {\n this.emit('blocked', reason);\n console.warn(reason); // eslint-disable-line no-console\n });\n conn.on('unblocked', (reason) => {\n this.emit('unblocked', reason);\n console.warn(reason); // eslint-disable-line no-console\n });\n this._amqpConnection = conn;\n this.emit('connect');\n resolve(this._amqpConnection);\n }).catch((reason) => {\n reject(reason);\n });\n }\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n isConnected() {\n return (this._amqpConnection !== undefined);\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Creates a channel on current connection\n *\n * @private\n * @param {String} channelName - indicates the channel name\n * @param {Object} opts - channel options\n * @return a promise containing the current channel\n */\n _createChannel(channelName, opts = {}) {\n channelName = `${channelName}${(opts.withConfirm === true) ? 'WithConfirm' : ''}`;\n return new Promise((resolve, reject) => {\n if (this._amqpChannels[channelName]) {\n resolve(this._amqpChannels[channelName]);\n } else {\n this.connect().then((conn) => {\n if (opts.withConfirm === true) {\n return conn.createConfirmChannel();\n } else {\n return conn.createChannel();\n }\n }).then((ch) => {\n this._amqpChannels[channelName] = ch;\n resolve(ch);\n }).catch((reason) => {\n reject(reason);\n });\n }\n });\n }\n\n /**\n * Close a channel on current connection\n *\n * @private\n * @param {String} channelName - indicates if the channel is input or output\n * @return a promise containing the result of the operation\n */\n _closeChannel(channelName, opts = {}) {\n channelName = `${channelName}${(opts.withConfirm === true) ? 'WithConfirm' : ''}`;\n return new Promise((resolve, reject) => {\n const ch = this._amqpChannels[channelName];\n if (ch === undefined) {\n reject('Invalid Channel Object');\n } else {\n ch.close().then(() => {\n this._amqpChannels[channelName] = undefined;\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n }\n });\n }\n\n /**\n * Generate the routing key for a specific channel\n *\n * @private\n * @param {String} channel - channel name on which you want to publish a message\n * @return a string that represents the routing key for that channel\n */\n _routingKeyFor(channel) {\n return `${this.deviceId()}.${channel}`;\n }\n\n /**\n * Check if the SDK have to automatically ack messages\n *\n * @private\n * @param {String} ack - the ack type, it should be 'manual' or 'auto'\n * @return boolean - true if messages have to be autoacked, false otherwise\n */\n _autoAck(ack) {\n if (ack) {\n if (!_.includes(CONFIG[this._protocol].ackTypes, ack)) {\n console.error('Wrong acknowledge type'); // eslint-disable-line no-console\n }\n switch (ack) {\n case 'auto':\n return true;\n default:\n return false;\n }\n }\n return true;\n }\n\n}\n\nexport default AmqpClient;\n"],"sourceRoot":"../src"} \ No newline at end of file diff --git a/lib/protocols/amqpStreamClient.js b/lib/protocols/amqpStreamClient.js index 020aaae..7668c50 100644 --- a/lib/protocols/amqpStreamClient.js +++ b/lib/protocols/amqpStreamClient.js @@ -93,6 +93,8 @@ var AmqpStreamClient = function (_AmqpClient) { * * @private * @param {Object} streamHook - Object containit hook info + * { stream: {String}, callback: {func}} + * or * { deviceId: {String}, channel: {String}, callback: {func}} * @param {Object} opts - connection options * @return a promise containing current connection diff --git a/lib/protocols/amqpStreamClient.js.map b/lib/protocols/amqpStreamClient.js.map index d389620..6cf580d 100644 --- a/lib/protocols/amqpStreamClient.js.map +++ b/lib/protocols/amqpStreamClient.js.map @@ -1 +1 @@ -{"version":3,"sources":["protocols/amqpStreamClient.js"],"names":["CONFIG","require","AmqpStreamClient","opts","amqpStreamOptions","amqp","stream","_defaultStreamRoutingKey","defaultStreamRoutingKey","_streamQueueArguments","streamQueueArguments","streamHooks","promises","map","streamHook","_attachStreamHook","length","Promise","any","reject","resolve","deviceId","channel","cache","undefined","routingKey","emptyFunction","callback","currentTime","Date","getTime","_createChannel","then","ch","_amqpChannels","promisesChain","liveStreamExists","console","error","cachedStreamQueue","_cachedStreamQueue","checkQueue","consume","message","_parseContent","content","fields","properties","_subscribeArgs","streamExchange","exchangeName","_liveStreamSuffix","streamChannelQueue","tempQueue","checkExchange","assertQueue","bindQueue","channelExchangeName","catch","reason","streamName","liveStreamByName","AmqpClient","onReceive","publish","_routingKeyFor"],"mappings":"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","file":"protocols/amqpStreamClient.js","sourcesContent":["/**\n * A module that exports an AmqpStreamClient client\n * which inherits from the Amqp base client\n * @module AmqpStreamClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\n\n// Import AmqpClient module from which AmqpStreamClient inherits\nimport AmqpClient from './amqpClient';\n\nconst CONFIG = require('../../config/constants').CONFIG;\n\nclass AmqpStreamClient extends AmqpClient {\n\n /**\n * @constructor\n * @param {Object} opts - options must contain client and secret for access keys\n */\n constructor(opts) {\n super(opts);\n const amqpStreamOptions = CONFIG.amqp.stream;\n this._defaultStreamRoutingKey = amqpStreamOptions.defaultStreamRoutingKey;\n this._streamQueueArguments = amqpStreamOptions.streamQueueArguments;\n }\n\n /**\n * Subscribe to multiple stream hooks\n *\n * @param {Array} streamHooks - Array of objects. Each objects containing\n * { deviceId: {string}, channel: {string}, callback: {func} }\n * @param {Object} options - subscription options\n * @return promise containing the result of multiple subscriptions\n */\n streamFrom(streamHooks = [], opts) {\n const promises = streamHooks.map((streamHook) => {\n return this._attachStreamHook(streamHook, opts);\n }) || [];\n if (promises.length > 0) {\n return Promise.any(promises);\n } else {\n return Promise.reject('Missing stream hooks');\n }\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Start consuming messages from a device's channel\n * It generates an auto delete queue from which consume\n * and binds it to the channel exchange\n *\n * @private\n * @param {Object} streamHook - Object containit hook info\n * { deviceId: {String}, channel: {String}, callback: {func}}\n * @param {Object} opts - connection options\n * @return a promise containing current connection\n */\n _attachStreamHook(streamHook, opts) {\n // Receive messages from imput queue\n return new Promise((resolve, reject) => {\n const deviceId = streamHook.deviceId;\n const channel = streamHook.channel;\n const stream = streamHook.stream;\n const cache = (typeof(streamHook.cache) !== 'boolean') ? true : streamHook.cache;\n if (stream === undefined && (channel === undefined || deviceId === undefined)) {\n reject('Missing Stream or Device ID and Channel');\n }\n const routingKey = streamHook.routingKey || this._defaultStreamRoutingKey;\n const emptyFunction = function () { return undefined; };\n const callback = streamHook.callback || emptyFunction;\n\n const currentTime = new Date().getTime();\n this._createChannel(`${currentTime}`).then((ch) => {\n this._amqpChannels[`${currentTime}`] = ch;\n let promisesChain = undefined;\n // if current hook is a stream\n // checks the existence of the stream queue and starts consuming\n if (stream) {\n if (!this.liveStreamExists(stream)) {\n console.error(`Stream ${stream} does not exist`); // eslint-disable-line no-console\n resolve(false);\n }\n if (cache) {\n // Cached streams are connected to the existing live stream queue\n const cachedStreamQueue = this._cachedStreamQueue(stream);\n promisesChain = this._amqpChannels[`${currentTime}`]\n .checkQueue(cachedStreamQueue, this._streamQueueArguments).then(() => {\n return this._amqpChannels[`${currentTime}`].consume(cachedStreamQueue, (message) => {\n // Call message callback\n callback(this._parseContent(message.content), message.fields, message.properties);\n }, merge(this._subscribeArgs, opts));\n });\n } else {\n // Uncached streams are connected to the stream exchange and create a temp queue\n const streamExchange = this.exchangeName(stream, this._liveStreamSuffix);\n const streamChannelQueue = this.tempQueue(stream, this._liveStreamSuffix, currentTime);\n promisesChain = this._amqpChannels[`${currentTime}`].checkExchange(streamExchange).then(() => {\n return this._amqpChannels[`${currentTime}`].assertQueue(streamChannelQueue, this._streamQueueArguments);\n }).then(() => {\n return this._amqpChannels[`${currentTime}`].bindQueue(streamChannelQueue, streamExchange, routingKey);\n }).then(() => {\n return this._amqpChannels[`${currentTime}`].consume(streamChannelQueue, (message) => {\n callback(this._parseContent(message.content), message.fields, message.properties);\n }, merge(this._subscribeArgs, opts));\n });\n }\n } else {\n // else if current hook is channel (or a couple deviceId, channel)\n // creates a temp queue, binds to channel exchange and starts consuming\n const channelExchangeName = this.exchangeName(deviceId, channel);\n const streamChannelQueue = this.tempQueue(deviceId, channel, currentTime);\n promisesChain = this._amqpChannels[`${currentTime}`].checkExchange(channelExchangeName).then(() => {\n return this._amqpChannels[`${currentTime}`].assertQueue(streamChannelQueue, this._streamQueueArguments);\n }).then(() => {\n return this._amqpChannels[`${currentTime}`].bindQueue(streamChannelQueue, channelExchangeName, routingKey);\n }).then(() => {\n return this._amqpChannels[`${currentTime}`].consume(streamChannelQueue, (message) => {\n callback(this._parseContent(message.content), message.fields, message.properties);\n }, merge(this._subscribeArgs, opts));\n });\n }\n return promisesChain;\n }).then(() => {\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Generate the exchange name for a device's channel\n *\n * @private\n * @param {String} streamName - stream name from which you want to stream\n * @return a string that represents the stream queue\n */\n _cachedStreamQueue(streamName) {\n return `${this.liveStreamByName(streamName)}.${this._liveStreamSuffix}`;\n }\n\n}\n\n// Remove unwanted methods inherited from AmqpClient\ndelete AmqpStreamClient.onReceive;\ndelete AmqpStreamClient.publish;\ndelete AmqpStreamClient._routingKeyFor;\n\nexport default AmqpStreamClient;\n"],"sourceRoot":"./src"} \ No newline at end of file +{"version":3,"sources":["protocols/amqpStreamClient.js"],"names":["CONFIG","require","AmqpStreamClient","opts","amqpStreamOptions","amqp","stream","_defaultStreamRoutingKey","defaultStreamRoutingKey","_streamQueueArguments","streamQueueArguments","streamHooks","promises","map","streamHook","_attachStreamHook","length","Promise","any","reject","resolve","deviceId","channel","cache","undefined","routingKey","emptyFunction","callback","currentTime","Date","getTime","_createChannel","then","ch","_amqpChannels","promisesChain","liveStreamExists","console","error","cachedStreamQueue","_cachedStreamQueue","checkQueue","consume","message","_parseContent","content","fields","properties","_subscribeArgs","streamExchange","exchangeName","_liveStreamSuffix","streamChannelQueue","tempQueue","checkExchange","assertQueue","bindQueue","channelExchangeName","catch","reason","streamName","liveStreamByName","AmqpClient","onReceive","publish","_routingKeyFor"],"mappings":"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","file":"amqpStreamClient.js","sourcesContent":["/**\n * A module that exports an AmqpStreamClient client\n * which inherits from the Amqp base client\n * @module AmqpStreamClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\n\n// Import AmqpClient module from which AmqpStreamClient inherits\nimport AmqpClient from './amqpClient';\n\nconst CONFIG = require('../../config/constants').CONFIG;\n\nclass AmqpStreamClient extends AmqpClient {\n\n /**\n * @constructor\n * @param {Object} opts - options must contain client and secret for access keys\n */\n constructor(opts) {\n super(opts);\n const amqpStreamOptions = CONFIG.amqp.stream;\n this._defaultStreamRoutingKey = amqpStreamOptions.defaultStreamRoutingKey;\n this._streamQueueArguments = amqpStreamOptions.streamQueueArguments;\n }\n\n /**\n * Subscribe to multiple stream hooks\n *\n * @param {Array} streamHooks - Array of objects. Each objects containing\n * { deviceId: {string}, channel: {string}, callback: {func} }\n * @param {Object} options - subscription options\n * @return promise containing the result of multiple subscriptions\n */\n streamFrom(streamHooks = [], opts) {\n const promises = streamHooks.map((streamHook) => {\n return this._attachStreamHook(streamHook, opts);\n }) || [];\n if (promises.length > 0) {\n return Promise.any(promises);\n } else {\n return Promise.reject('Missing stream hooks');\n }\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Start consuming messages from a device's channel\n * It generates an auto delete queue from which consume\n * and binds it to the channel exchange\n *\n * @private\n * @param {Object} streamHook - Object containit hook info\n * { stream: {String}, callback: {func}}\n * or\n * { deviceId: {String}, channel: {String}, callback: {func}}\n * @param {Object} opts - connection options\n * @return a promise containing current connection\n */\n _attachStreamHook(streamHook, opts) {\n // Receive messages from imput queue\n return new Promise((resolve, reject) => {\n const deviceId = streamHook.deviceId;\n const channel = streamHook.channel;\n const stream = streamHook.stream;\n const cache = (typeof(streamHook.cache) !== 'boolean') ? true : streamHook.cache;\n if (stream === undefined && (channel === undefined || deviceId === undefined)) {\n reject('Missing Stream or Device ID and Channel');\n }\n const routingKey = streamHook.routingKey || this._defaultStreamRoutingKey;\n const emptyFunction = function () { return undefined; };\n const callback = streamHook.callback || emptyFunction;\n\n const currentTime = new Date().getTime();\n this._createChannel(`${currentTime}`).then((ch) => {\n this._amqpChannels[`${currentTime}`] = ch;\n let promisesChain = undefined;\n // if current hook is a stream\n // checks the existence of the stream queue and starts consuming\n if (stream) {\n if (!this.liveStreamExists(stream)) {\n console.error(`Stream ${stream} does not exist`); // eslint-disable-line no-console\n resolve(false);\n }\n if (cache) {\n // Cached streams are connected to the existing live stream queue\n const cachedStreamQueue = this._cachedStreamQueue(stream);\n promisesChain = this._amqpChannels[`${currentTime}`]\n .checkQueue(cachedStreamQueue, this._streamQueueArguments).then(() => {\n return this._amqpChannels[`${currentTime}`].consume(cachedStreamQueue, (message) => {\n // Call message callback\n callback(this._parseContent(message.content), message.fields, message.properties);\n }, merge(this._subscribeArgs, opts));\n });\n } else {\n // Uncached streams are connected to the stream exchange and create a temp queue\n const streamExchange = this.exchangeName(stream, this._liveStreamSuffix);\n const streamChannelQueue = this.tempQueue(stream, this._liveStreamSuffix, currentTime);\n promisesChain = this._amqpChannels[`${currentTime}`].checkExchange(streamExchange).then(() => {\n return this._amqpChannels[`${currentTime}`].assertQueue(streamChannelQueue, this._streamQueueArguments);\n }).then(() => {\n return this._amqpChannels[`${currentTime}`].bindQueue(streamChannelQueue, streamExchange, routingKey);\n }).then(() => {\n return this._amqpChannels[`${currentTime}`].consume(streamChannelQueue, (message) => {\n callback(this._parseContent(message.content), message.fields, message.properties);\n }, merge(this._subscribeArgs, opts));\n });\n }\n } else {\n // else if current hook is channel (or a couple deviceId, channel)\n // creates a temp queue, binds to channel exchange and starts consuming\n const channelExchangeName = this.exchangeName(deviceId, channel);\n const streamChannelQueue = this.tempQueue(deviceId, channel, currentTime);\n promisesChain = this._amqpChannels[`${currentTime}`].checkExchange(channelExchangeName).then(() => {\n return this._amqpChannels[`${currentTime}`].assertQueue(streamChannelQueue, this._streamQueueArguments);\n }).then(() => {\n return this._amqpChannels[`${currentTime}`].bindQueue(streamChannelQueue, channelExchangeName, routingKey);\n }).then(() => {\n return this._amqpChannels[`${currentTime}`].consume(streamChannelQueue, (message) => {\n callback(this._parseContent(message.content), message.fields, message.properties);\n }, merge(this._subscribeArgs, opts));\n });\n }\n return promisesChain;\n }).then(() => {\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Generate the exchange name for a device's channel\n *\n * @private\n * @param {String} streamName - stream name from which you want to stream\n * @return a string that represents the stream queue\n */\n _cachedStreamQueue(streamName) {\n return `${this.liveStreamByName(streamName)}.${this._liveStreamSuffix}`;\n }\n\n}\n\n// Remove unwanted methods inherited from AmqpClient\ndelete AmqpStreamClient.onReceive;\ndelete AmqpStreamClient.publish;\ndelete AmqpStreamClient._routingKeyFor;\n\nexport default AmqpStreamClient;\n"],"sourceRoot":"../src"} \ No newline at end of file diff --git a/lib/protocols/mqttClient.js.map b/lib/protocols/mqttClient.js.map index 0c0dc28..3fafc70 100644 --- a/lib/protocols/mqttClient.js.map +++ b/lib/protocols/mqttClient.js.map @@ -1 +1 @@ -{"version":3,"sources":["protocols/mqttClient.js"],"names":["CONFIG","require","MqttClient","opts","_topics","_mqttConnection","undefined","_subscription","mqttOptions","mqtt","_protocol","protocol","_tlsOpts","tls","rejectUnauthorized","_connectionOpts","connection","_connectionTimeout","timeout","callback","Promise","resolve","reject","connect","then","client","_topicFor","_inboxTopic","qos","subscribe","err","on","topic","message","_parseContent","catch","reason","channel","_sendMessage","bufferedMessage","Buffer","_encapsulateContent","publish","connected","topics","unsubscribe","Object","keys","_closeConnection","end","emit","getEndpointConfigs","endpointConfigs","connectionParams","mqttConnectionParams","host","port","_tls","protocols","tlsPort","username","vhost","deviceId","password","secret","clientId","connectionTimeout","SpaceBunny"],"mappings":"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","file":"protocols/mqttClient.js","sourcesContent":["/**\n * A module that exports an MqttClient client\n * which inherits from the SpaceBunny base client\n * @module MqttClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\nimport _ from 'lodash';\n\n// Import mqtt library\nimport mqtt from 'mqtt';\n\n// Import SpaceBunny main module from which MqttClient inherits\nimport SpaceBunny from '../spacebunny';\n\nconst CONFIG = require('../../config/constants').CONFIG;\n\nclass MqttClient extends SpaceBunny {\n\n /**\n * @constructor\n * @param {Object} opts - options must contain Device-Key or connection options\n * (deviceId and secret) for devices.\n */\n constructor(opts) {\n super(opts);\n this._topics = {};\n this._mqttConnection = undefined;\n this._subscription = undefined;\n const mqttOptions = CONFIG.mqtt;\n this._protocol = mqttOptions.protocol;\n this._tlsOpts.protocol = mqttOptions.tls.protocol;\n this._tlsOpts.rejectUnauthorized = mqttOptions.tls.rejectUnauthorized;\n this._connectionOpts = mqttOptions.connection.opts;\n this._connectionTimeout = mqttOptions.connection.timeout;\n }\n\n /**\n * Subscribe to input channel\n *\n * @param {function} callback - function called every time a message is received\n * passing the current message as argument\n * @param {Object} options - subscription options\n * @return promise containing the result of the subscription\n */\n onReceive(callback, opts) {\n opts = merge({}, opts);\n // subscribe for input messages\n return new Promise((resolve, reject) => {\n this.connect().then((client) => {\n this._topics[this._topicFor(this._inboxTopic)] = opts.qos || this._connectionOpts.qos;\n client.subscribe(this._topics, merge(this._connectionOpts, opts), (err) => {\n if (err) {\n reject(false);\n } else {\n client.on('message', (topic, message) => {\n // TODO filterMine and filterWeb\n callback(topic, this._parseContent(message));\n });\n resolve(true);\n }\n });\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Publish a message on a specific channel\n *\n * @param {String} channel - channel name on which you want to publish a message\n * @param {Object/String} message - the message payload\n * @param {Object} opts - publication options\n * @return a promise containing the result of the operation\n */\n publish(channel, message, opts) {\n // Publish message\n return new Promise((resolve, reject) => {\n this.connect().then((client) => {\n const _sendMessage = () => {\n const bufferedMessage = new Buffer(this._encapsulateContent(message));\n client.publish(this._topicFor(channel), bufferedMessage, merge(this._connectionOpts, opts), () => {\n resolve(true);\n });\n };\n if (!client.connected) {\n client.on('connect', () => { _sendMessage(); });\n } else {\n _sendMessage();\n }\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Unsubscribe client from a list of topics\n *\n * @param {Object} topics - list of topics { topic: qos, ... }\n * e.g. { topic_1: 1, topic_2: 0 }\n * @return a promise containing the result of the operation\n */\n unsubscribe(topics) {\n return new Promise((resolve, reject) => {\n try {\n if (_.isEmpty(topics)) {\n resolve(true);\n } else {\n this._mqttConnection.unsubscribe(Object.keys(topics), () => {\n resolve(true);\n });\n }\n } catch (reason) {\n reject(reason);\n }\n });\n }\n\n /**\n * Destroy the connection between the mqtt client and broker\n *\n * @return a promise containing the result of the operation\n */\n disconnect() {\n return new Promise((resolve, reject) => {\n if (this._mqttConnection === undefined) {\n reject('Invalid connection');\n } else {\n const _closeConnection = () => {\n this._mqttConnection.end(true, () => {\n this._mqttConnection = undefined;\n this.emit('disconnect');\n resolve(true);\n });\n };\n try {\n if (_.isEmpty(this._topics)) {\n _closeConnection();\n } else {\n this._mqttConnection.unsubscribe(Object.keys(this._topics), () => {\n _closeConnection();\n });\n }\n } catch (reason) {\n reject(reason);\n }\n }\n });\n }\n\n /**\n * Establish an mqtt connection with the broker.\n * If a connection already exists, returns the current connection\n *\n * @param {Object} opts - connection options\n * @return a promise containing current connection\n */\n connect(opts = {}) {\n opts = merge(this._connectionOpts, opts);\n\n return new Promise((resolve, reject) => {\n this.getEndpointConfigs().then((endpointConfigs) => {\n const connectionParams = endpointConfigs.connection;\n if (this._mqttConnection !== undefined) {\n resolve(this._mqttConnection);\n } else {\n try {\n let mqttConnectionParams = {\n host: connectionParams.host,\n port: (this._tls) ? connectionParams.protocols.mqtt.tlsPort : connectionParams.protocols.mqtt.port,\n username: `${connectionParams.vhost}:${connectionParams.deviceId || connectionParams.client}`,\n password: connectionParams.secret,\n clientId: connectionParams.deviceId || connectionParams.client,\n connectionTimeout: opts.connectionTimeout || this._connectionTimeout\n };\n if (this._tls) {\n mqttConnectionParams = merge(mqttConnectionParams, this._tlsOpts);\n }\n const client = mqtt.connect(mqttConnectionParams);\n client.on('error', (reason) => {\n this.emit('error', reason);\n reject(reason);\n });\n client.on('close', (reason) => {\n reject(reason);\n this.emit('close', reason);\n this._mqttConnection = undefined;\n });\n this._mqttConnection = client;\n this.emit('connect');\n resolve(this._mqttConnection);\n } catch (reason) {\n reject(reason);\n }\n }\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n isConnected() {\n return (this._mqttConnection !== undefined);\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Generate the topic for a specific channel\n *\n * @private\n * @param {String} channel - channel name on which you want to publish a message\n * @return a string that represents the topic name for that channel\n */\n _topicFor(channel) {\n return `${this.deviceId()}/${channel}`;\n }\n}\n\nexport default MqttClient;\n"],"sourceRoot":"./src"} \ No newline at end of file +{"version":3,"sources":["protocols/mqttClient.js"],"names":["CONFIG","require","MqttClient","opts","_topics","_mqttConnection","undefined","_subscription","mqttOptions","mqtt","_protocol","protocol","_tlsOpts","tls","rejectUnauthorized","_connectionOpts","connection","_connectionTimeout","timeout","callback","Promise","resolve","reject","connect","then","client","_topicFor","_inboxTopic","qos","subscribe","err","on","topic","message","_parseContent","catch","reason","channel","_sendMessage","bufferedMessage","Buffer","_encapsulateContent","publish","connected","topics","unsubscribe","Object","keys","_closeConnection","end","emit","getEndpointConfigs","endpointConfigs","connectionParams","mqttConnectionParams","host","port","_tls","protocols","tlsPort","username","vhost","deviceId","password","secret","clientId","connectionTimeout","SpaceBunny"],"mappings":"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","file":"mqttClient.js","sourcesContent":["/**\n * A module that exports an MqttClient client\n * which inherits from the SpaceBunny base client\n * @module MqttClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\nimport _ from 'lodash';\n\n// Import mqtt library\nimport mqtt from 'mqtt';\n\n// Import SpaceBunny main module from which MqttClient inherits\nimport SpaceBunny from '../spacebunny';\n\nconst CONFIG = require('../../config/constants').CONFIG;\n\nclass MqttClient extends SpaceBunny {\n\n /**\n * @constructor\n * @param {Object} opts - options must contain Device-Key or connection options\n * (deviceId and secret) for devices.\n */\n constructor(opts) {\n super(opts);\n this._topics = {};\n this._mqttConnection = undefined;\n this._subscription = undefined;\n const mqttOptions = CONFIG.mqtt;\n this._protocol = mqttOptions.protocol;\n this._tlsOpts.protocol = mqttOptions.tls.protocol;\n this._tlsOpts.rejectUnauthorized = mqttOptions.tls.rejectUnauthorized;\n this._connectionOpts = mqttOptions.connection.opts;\n this._connectionTimeout = mqttOptions.connection.timeout;\n }\n\n /**\n * Subscribe to input channel\n *\n * @param {function} callback - function called every time a message is received\n * passing the current message as argument\n * @param {Object} options - subscription options\n * @return promise containing the result of the subscription\n */\n onReceive(callback, opts) {\n opts = merge({}, opts);\n // subscribe for input messages\n return new Promise((resolve, reject) => {\n this.connect().then((client) => {\n this._topics[this._topicFor(this._inboxTopic)] = opts.qos || this._connectionOpts.qos;\n client.subscribe(this._topics, merge(this._connectionOpts, opts), (err) => {\n if (err) {\n reject(false);\n } else {\n client.on('message', (topic, message) => {\n // TODO filterMine and filterWeb\n callback(topic, this._parseContent(message));\n });\n resolve(true);\n }\n });\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Publish a message on a specific channel\n *\n * @param {String} channel - channel name on which you want to publish a message\n * @param {Object/String} message - the message payload\n * @param {Object} opts - publication options\n * @return a promise containing the result of the operation\n */\n publish(channel, message, opts) {\n // Publish message\n return new Promise((resolve, reject) => {\n this.connect().then((client) => {\n const _sendMessage = () => {\n const bufferedMessage = new Buffer(this._encapsulateContent(message));\n client.publish(this._topicFor(channel), bufferedMessage, merge(this._connectionOpts, opts), () => {\n resolve(true);\n });\n };\n if (!client.connected) {\n client.on('connect', () => { _sendMessage(); });\n } else {\n _sendMessage();\n }\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Unsubscribe client from a list of topics\n *\n * @param {Object} topics - list of topics { topic: qos, ... }\n * e.g. { topic_1: 1, topic_2: 0 }\n * @return a promise containing the result of the operation\n */\n unsubscribe(topics) {\n return new Promise((resolve, reject) => {\n try {\n if (_.isEmpty(topics)) {\n resolve(true);\n } else {\n this._mqttConnection.unsubscribe(Object.keys(topics), () => {\n resolve(true);\n });\n }\n } catch (reason) {\n reject(reason);\n }\n });\n }\n\n /**\n * Destroy the connection between the mqtt client and broker\n *\n * @return a promise containing the result of the operation\n */\n disconnect() {\n return new Promise((resolve, reject) => {\n if (this._mqttConnection === undefined) {\n reject('Invalid connection');\n } else {\n const _closeConnection = () => {\n this._mqttConnection.end(true, () => {\n this._mqttConnection = undefined;\n this.emit('disconnect');\n resolve(true);\n });\n };\n try {\n if (_.isEmpty(this._topics)) {\n _closeConnection();\n } else {\n this._mqttConnection.unsubscribe(Object.keys(this._topics), () => {\n _closeConnection();\n });\n }\n } catch (reason) {\n reject(reason);\n }\n }\n });\n }\n\n /**\n * Establish an mqtt connection with the broker.\n * If a connection already exists, returns the current connection\n *\n * @param {Object} opts - connection options\n * @return a promise containing current connection\n */\n connect(opts = {}) {\n opts = merge(this._connectionOpts, opts);\n\n return new Promise((resolve, reject) => {\n this.getEndpointConfigs().then((endpointConfigs) => {\n const connectionParams = endpointConfigs.connection;\n if (this._mqttConnection !== undefined) {\n resolve(this._mqttConnection);\n } else {\n try {\n let mqttConnectionParams = {\n host: connectionParams.host,\n port: (this._tls) ? connectionParams.protocols.mqtt.tlsPort : connectionParams.protocols.mqtt.port,\n username: `${connectionParams.vhost}:${connectionParams.deviceId || connectionParams.client}`,\n password: connectionParams.secret,\n clientId: connectionParams.deviceId || connectionParams.client,\n connectionTimeout: opts.connectionTimeout || this._connectionTimeout\n };\n if (this._tls) {\n mqttConnectionParams = merge(mqttConnectionParams, this._tlsOpts);\n }\n const client = mqtt.connect(mqttConnectionParams);\n client.on('error', (reason) => {\n this.emit('error', reason);\n reject(reason);\n });\n client.on('close', (reason) => {\n reject(reason);\n this.emit('close', reason);\n this._mqttConnection = undefined;\n });\n this._mqttConnection = client;\n this.emit('connect');\n resolve(this._mqttConnection);\n } catch (reason) {\n reject(reason);\n }\n }\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n isConnected() {\n return (this._mqttConnection !== undefined);\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Generate the topic for a specific channel\n *\n * @private\n * @param {String} channel - channel name on which you want to publish a message\n * @return a string that represents the topic name for that channel\n */\n _topicFor(channel) {\n return `${this.deviceId()}/${channel}`;\n }\n}\n\nexport default MqttClient;\n"],"sourceRoot":"../src"} \ No newline at end of file diff --git a/lib/protocols/mqttStreamClient.js.map b/lib/protocols/mqttStreamClient.js.map index d60baf7..3cf9ef8 100644 --- a/lib/protocols/mqttStreamClient.js.map +++ b/lib/protocols/mqttStreamClient.js.map @@ -1 +1 @@ -{"version":3,"sources":["protocols/mqttStreamClient.js"],"names":["MqttStreamClient","streamHooks","opts","Promise","resolve","reject","connect","then","mqttClient","emptyFunction","undefined","forEach","streamHook","stream","deviceId","channel","qos","cache","liveStreamExists","console","error","_topics","_streamTopicFor","_streamChannelTopicFor","_connectionOpts","subscribe","err","on","topic","message","splitted","split","streams","filter","liveStreamByName","callback","length","_parseContent","catch","reason","_liveStreamSuffix","MqttClient","onReceive","publish","_topicFor"],"mappings":"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","file":"protocols/mqttStreamClient.js","sourcesContent":["/**\n * A module that exports an MqttStreamClient client\n * which inherits from the Mqtt base client\n * @module MqttStreamClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\n\n// Import MqttClient main module from which MqttStreamClient inherits\nimport MqttClient from './mqttClient';\n\nclass MqttStreamClient extends MqttClient {\n\n /**\n * Subscribe to multiple stream hooks\n *\n * @param {Array} streamHooks - Array of objects. Each objects containing\n * { deviceId: {string}, channel: {string}, callback: {func} }\n * @param {Object} options - subscription options\n * @return promise containing the result of multiple subscriptions\n */\n streamFrom(streamHooks = [], opts) {\n return new Promise((resolve, reject) => {\n this.connect().then((mqttClient) => {\n const emptyFunction = () => { return undefined; };\n streamHooks.forEach((streamHook) => {\n const stream = streamHook.stream;\n const deviceId = streamHook.deviceId;\n const channel = streamHook.channel;\n const qos = streamHook.qos;\n const cache = (typeof(streamHook.cache) !== 'boolean') ? true : streamHook.cache;\n if (stream === undefined && (channel === undefined || deviceId === undefined)) {\n reject('Missing Stream or Device ID and Channel');\n }\n if (stream) {\n if (!this.liveStreamExists(stream)) {\n console.error(`Stream ${stream} does not exist`); // eslint-disable-line no-console\n resolve(false);\n }\n // Cached streams generate qos1 connections with persistent queues\n // Uncached streams generate qos0 connections with auto delete queues\n this._topics[this._streamTopicFor(stream)] = (cache) ? 1 : 0;\n } else {\n // streams connected directly to a specific channel generate qos0 connections with auto delete queues\n this._topics[this._streamChannelTopicFor(deviceId, channel)] = qos || this._connectionOpts.qos;\n }\n });\n mqttClient.subscribe(this._topics, merge(this._connectionOpts, opts), (err) => {\n if (err) {\n reject(false);\n } else {\n mqttClient.on('message', (topic, message) => {\n const splitted = topic.split('/');\n const streams = streamHooks.filter((streamHook) => {\n return this.liveStreamByName(streamHook.stream) === splitted[0] ||\n (streamHook.deviceId === splitted[0] && streamHook.channel === splitted[1]);\n });\n let callback = emptyFunction;\n if (streams.length > 0) {\n callback = streams[0].callback || emptyFunction;\n }\n callback(topic, this._parseContent(message));\n });\n resolve(true);\n }\n });\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Generate the topic for a specific channel\n *\n * @private\n * @param {String} deviceId - deviceId from which you want to stream\n * @param {String} channel - channel name from which you want to stream\n * @return a string that represents the topic name for that channel\n */\n _streamChannelTopicFor(deviceId, channel) {\n return `${deviceId}/${channel}`;\n }\n\n /**\n * Generate the topic for a specific stream\n *\n * @private\n * @param {String} streamName - stream name from which you want to stream\n * @return a string that represents the topic name for that stream\n */\n _streamTopicFor(stream) {\n return `${this.liveStreamByName(stream)}/${this._liveStreamSuffix}`;\n }\n}\n\n// Remove unwnated methods inherited from MqttClient\ndelete MqttStreamClient.onReceive;\ndelete MqttStreamClient.publish;\ndelete MqttStreamClient._topicFor;\n\nexport default MqttStreamClient;\n"],"sourceRoot":"./src"} \ No newline at end of file +{"version":3,"sources":["protocols/mqttStreamClient.js"],"names":["MqttStreamClient","streamHooks","opts","Promise","resolve","reject","connect","then","mqttClient","emptyFunction","undefined","forEach","streamHook","stream","deviceId","channel","qos","cache","liveStreamExists","console","error","_topics","_streamTopicFor","_streamChannelTopicFor","_connectionOpts","subscribe","err","on","topic","message","splitted","split","streams","filter","liveStreamByName","callback","length","_parseContent","catch","reason","_liveStreamSuffix","MqttClient","onReceive","publish","_topicFor"],"mappings":"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","file":"mqttStreamClient.js","sourcesContent":["/**\n * A module that exports an MqttStreamClient client\n * which inherits from the Mqtt base client\n * @module MqttStreamClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\n\n// Import MqttClient main module from which MqttStreamClient inherits\nimport MqttClient from './mqttClient';\n\nclass MqttStreamClient extends MqttClient {\n\n /**\n * Subscribe to multiple stream hooks\n *\n * @param {Array} streamHooks - Array of objects. Each objects containing\n * { deviceId: {string}, channel: {string}, callback: {func} }\n * @param {Object} options - subscription options\n * @return promise containing the result of multiple subscriptions\n */\n streamFrom(streamHooks = [], opts) {\n return new Promise((resolve, reject) => {\n this.connect().then((mqttClient) => {\n const emptyFunction = () => { return undefined; };\n streamHooks.forEach((streamHook) => {\n const stream = streamHook.stream;\n const deviceId = streamHook.deviceId;\n const channel = streamHook.channel;\n const qos = streamHook.qos;\n const cache = (typeof(streamHook.cache) !== 'boolean') ? true : streamHook.cache;\n if (stream === undefined && (channel === undefined || deviceId === undefined)) {\n reject('Missing Stream or Device ID and Channel');\n }\n if (stream) {\n if (!this.liveStreamExists(stream)) {\n console.error(`Stream ${stream} does not exist`); // eslint-disable-line no-console\n resolve(false);\n }\n // Cached streams generate qos1 connections with persistent queues\n // Uncached streams generate qos0 connections with auto delete queues\n this._topics[this._streamTopicFor(stream)] = (cache) ? 1 : 0;\n } else {\n // streams connected directly to a specific channel generate qos0 connections with auto delete queues\n this._topics[this._streamChannelTopicFor(deviceId, channel)] = qos || this._connectionOpts.qos;\n }\n });\n mqttClient.subscribe(this._topics, merge(this._connectionOpts, opts), (err) => {\n if (err) {\n reject(false);\n } else {\n mqttClient.on('message', (topic, message) => {\n const splitted = topic.split('/');\n const streams = streamHooks.filter((streamHook) => {\n return this.liveStreamByName(streamHook.stream) === splitted[0] ||\n (streamHook.deviceId === splitted[0] && streamHook.channel === splitted[1]);\n });\n let callback = emptyFunction;\n if (streams.length > 0) {\n callback = streams[0].callback || emptyFunction;\n }\n callback(topic, this._parseContent(message));\n });\n resolve(true);\n }\n });\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Generate the topic for a specific channel\n *\n * @private\n * @param {String} deviceId - deviceId from which you want to stream\n * @param {String} channel - channel name from which you want to stream\n * @return a string that represents the topic name for that channel\n */\n _streamChannelTopicFor(deviceId, channel) {\n return `${deviceId}/${channel}`;\n }\n\n /**\n * Generate the topic for a specific stream\n *\n * @private\n * @param {String} streamName - stream name from which you want to stream\n * @return a string that represents the topic name for that stream\n */\n _streamTopicFor(stream) {\n return `${this.liveStreamByName(stream)}/${this._liveStreamSuffix}`;\n }\n}\n\n// Remove unwnated methods inherited from MqttClient\ndelete MqttStreamClient.onReceive;\ndelete MqttStreamClient.publish;\ndelete MqttStreamClient._topicFor;\n\nexport default MqttStreamClient;\n"],"sourceRoot":"../src"} \ No newline at end of file diff --git a/lib/protocols/stompClient.js.map b/lib/protocols/stompClient.js.map index 290e6e9..e4f3c9e 100644 --- a/lib/protocols/stompClient.js.map +++ b/lib/protocols/stompClient.js.map @@ -1 +1 @@ -{"version":3,"sources":["protocols/stompClient.js"],"names":["CONFIG","require","StompClient","opts","_stompConnection","undefined","_subscription","process","_protocol","stompOpts","stomp","webStompOpts","webStomp","_webSocketOpts","webSocket","_connectionHeaders","connection","headers","_connectionOpts","_existingQueuePrefix","existingQueuePrefix","callback","Promise","resolve","reject","connect","then","client","topic","_subcriptionFor","_inboxTopic","subscriptionCallback","message","stompMessage","StompMessage","_deviceId","ackNeeded","_autoAck","ack","blackListed","nack","_parseContent","body","subscribe","catch","reason","channel","destination","_destinationFor","send","_encapsulateContent","unsubscribe","disconnect","emit","getEndpointConfigs","endpointConfigs","connectionParams","_tls","Stomp","overTCP","host","protocols","tlsPort","_tlsOpts","port","protocol","tls","connectionString","endpoint","ws","WebSocket","over","heartbeat","outgoing","incoming","debug","login","deviceId","passcode","secret","vhost","err","type","ackTypes","console","error","SpaceBunny"],"mappings":"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","file":"protocols/stompClient.js","sourcesContent":["/**\n * A module that exports an StompClient client\n * which inherits from the SpaceBunny base client\n * @module StompClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\nimport _ from 'lodash';\n\n// Import stomp library\nimport Stomp from 'stompjs';\n\n// Import SpaceBunny main module from which StompClient inherits\nimport SpaceBunny from '../spacebunny';\nimport StompMessage from '../messages/stompMessage';\nconst CONFIG = require('../../config/constants').CONFIG;\n\nclass StompClient extends SpaceBunny {\n\n /**\n * @constructor\n * @param {Object} opts - options must contain Device-Key or connection options\n * (deviceId and secret) for devices.\n */\n constructor(opts) {\n super(opts);\n this._stompConnection = undefined;\n this._subscription = undefined;\n if (typeof process === 'object' && `${process}` === '[object process]') {\n this._protocol = 'stomp';\n } else {\n this._protocol = 'webStomp';\n }\n const stompOpts = CONFIG.stomp;\n const webStompOpts = CONFIG.webStomp;\n this._webSocketOpts = webStompOpts.webSocket;\n this._connectionHeaders = stompOpts.connection.headers;\n this._connectionOpts = stompOpts.connection.opts;\n this._existingQueuePrefix = stompOpts.existingQueuePrefix;\n }\n\n /**\n * Subscribe to input channel\n *\n * @param {function} callback - function called every time a message is received\n * passing the current message as argument\n * @param {Object} options - subscription options\n * @return promise containing the result of the subscription\n */\n onReceive(callback, opts) {\n opts = merge({}, opts);\n // subscribe for input messages\n return new Promise((resolve, reject) => {\n this.connect().then((client) => {\n const topic = this._subcriptionFor(this._existingQueuePrefix, this._inboxTopic);\n const subscriptionCallback = (message) => {\n // Create message object\n const stompMessage = new StompMessage(message, this._deviceId, opts);\n const ackNeeded = this._autoAck(opts.ack);\n // Check if should be accepted or not\n if (stompMessage.blackListed()) {\n if (ackNeeded) { message.nack(); }\n return;\n }\n // Call message callback\n callback(this._parseContent(stompMessage.body), stompMessage.headers);\n // Check if ACK is needed\n if (ackNeeded) { message.ack(); }\n };\n this._subscription = client.subscribe(topic, subscriptionCallback);\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Publish a message on a specific channel\n *\n * @param {String} channel - channel name on which you want to publish a message\n * @param {Object} message - the message payload\n * @param {Object} opts - publication options\n * @return a promise containing the result of the operation\n */\n publish(channel, message, opts) {\n opts = merge({}, opts);\n // Publish message\n return new Promise((resolve, reject) => {\n this.connect().then((client) => {\n const destination = this._destinationFor('exchange', channel);\n client.send(destination, this._connectionHeaders, this._encapsulateContent(message));\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Destroy the connection between the stomp client and broker\n *\n * @return a promise containing the result of the operation\n */\n disconnect() {\n return new Promise((resolve, reject) => {\n if (this._stompConnection === undefined) {\n reject('Invalid connection');\n } else {\n if (this._subscription !== undefined) {\n this._subscription.unsubscribe();\n }\n this._stompConnection.disconnect(() => {\n this.emit('disconnect');\n this._stompConnection = undefined;\n resolve(true);\n }).catch((reason) => {\n this._stompConnection = undefined;\n reject(reason);\n });\n }\n });\n }\n\n /**\n * Establish an stomp connection with the broker.\n * If a connection already exists, returns the current connection\n *\n * @param {Object} opts - connection options\n * @return a promise containing current connection\n */\n connect(opts = {}) {\n opts = merge(this._connectionOpts, opts);\n return new Promise((resolve, reject) => {\n this.getEndpointConfigs().then((endpointConfigs) => {\n const connectionParams = endpointConfigs.connection;\n if (this._stompConnection !== undefined) {\n resolve(this._stompConnection);\n } else {\n try {\n let client = undefined;\n if (typeof process === 'object' && `${process}` === '[object process]') {\n // code is runnning in nodejs: STOMP uses TCP sockets\n if (this._tls) {\n client = Stomp.overTCP(connectionParams.host, connectionParams.protocols.stomp.tlsPort, this._tlsOpts);\n } else {\n client = Stomp.overTCP(connectionParams.host, connectionParams.protocols.stomp.port);\n }\n } else {\n // code is runnning in a browser: web STOMP uses Web sockets\n const protocol = (this._tls) ? this._webSocketOpts.tls.protocol : this._webSocketOpts.protocol;\n const port = (this._tls) ? connectionParams.protocols.webStomp.tlsPort :\n connectionParams.protocols.webStomp.port;\n const connectionString = `${protocol}://${connectionParams.host}:${port}/${this._webSocketOpts.endpoint}`;\n const ws = new WebSocket(connectionString);\n client = Stomp.over(ws);\n client.heartbeat.outgoing = 10000;\n client.heartbeat.incoming = 10000;\n client.debug = null;\n }\n const headers = merge(this._connectionHeaders, {\n login: connectionParams.deviceId || connectionParams.client,\n passcode: connectionParams.secret,\n host: connectionParams.vhost\n });\n client.connect(headers, () => {\n this._stompConnection = client;\n this.emit('connect');\n resolve(this._stompConnection);\n }, (err) => {\n this.emit('error', err);\n this._stompConnection = undefined;\n reject(err);\n });\n } catch (reason) {\n reject(reason);\n }\n }\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n isConnected() {\n return (this._stompConnection !== undefined);\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Generate the subscription string for a specific channel\n *\n * @private\n * @param {String} type - resource type on which subscribe or publish [exchange/queue]\n * @param {String} channel - channel name on which you want to publish a message\n * @return a string that represents the topic name for that channel\n */\n _subcriptionFor(type, channel) {\n return `/${type}/${this.deviceId()}.${channel}`;\n }\n\n /**\n * Generate the destination string for a specific channel\n *\n * @private\n * @param {String} type - resource type on which subscribe or publish [exchange/queue]\n * @param {String} channel - channel name on which you want to publish a message\n * @return a string that represents the topic name for that channel\n */\n _destinationFor(type, channel) {\n return `/${type}/${this.deviceId()}/${this.deviceId()}.${channel}`;\n }\n\n /**\n * Check if the SDK have to automatically ack messages\n * By default STOMP messages are acked by the server\n * they need to be acked if client subscribes with { ack: 'client' } option\n *\n * @private\n * @param {String} ack - the ack type, it should be 'client' or null\n * @return boolean - true if messages have to be autoacked, false otherwise\n */\n _autoAck(ack) {\n if (ack) {\n if (!_.includes(CONFIG[this._protocol].ackTypes, ack)) {\n console.error('Wrong acknowledge type'); // eslint-disable-line no-console\n }\n switch (ack) {\n case 'client':\n return false;\n default:\n return true;\n }\n }\n return false;\n }\n\n}\n\nexport default StompClient;\n"],"sourceRoot":"./src"} \ No newline at end of file +{"version":3,"sources":["protocols/stompClient.js"],"names":["CONFIG","require","StompClient","opts","_stompConnection","undefined","_subscription","process","_protocol","stompOpts","stomp","webStompOpts","webStomp","_webSocketOpts","webSocket","_connectionHeaders","connection","headers","_connectionOpts","_existingQueuePrefix","existingQueuePrefix","callback","Promise","resolve","reject","connect","then","client","topic","_subcriptionFor","_inboxTopic","subscriptionCallback","message","stompMessage","StompMessage","_deviceId","ackNeeded","_autoAck","ack","blackListed","nack","_parseContent","body","subscribe","catch","reason","channel","destination","_destinationFor","send","_encapsulateContent","unsubscribe","disconnect","emit","getEndpointConfigs","endpointConfigs","connectionParams","_tls","Stomp","overTCP","host","protocols","tlsPort","_tlsOpts","port","protocol","tls","connectionString","endpoint","ws","WebSocket","over","heartbeat","outgoing","incoming","debug","login","deviceId","passcode","secret","vhost","err","type","ackTypes","console","error","SpaceBunny"],"mappings":";;;;;;;;;;;;;;AAOA;;;;AACA;;;;AAIA;;;;AAGA;;;;AACA;;;;;;;;;;+eAhBA;;;;;;AAMA;;;AAKA;;;AAGA;;;AAGA,IAAMA,SAASC,QAAQ,wBAAR,EAAkCD,MAAjD;;IAEME,W;;;AAEJ;;;;;AAKA,uBAAYC,IAAZ,EAAkB;AAAA;;AAAA,0HACVA,IADU;;AAEhB,UAAKC,gBAAL,GAAwBC,SAAxB;AACA,UAAKC,aAAL,GAAqBD,SAArB;AACA,QAAI,QAAOE,OAAP,yCAAOA,OAAP,OAAmB,QAAnB,IAA+B,KAAGA,OAAH,KAAiB,kBAApD,EAAwE;AACtE,YAAKC,SAAL,GAAiB,OAAjB;AACD,KAFD,MAEO;AACL,YAAKA,SAAL,GAAiB,UAAjB;AACD;AACD,QAAMC,YAAYT,OAAOU,KAAzB;AACA,QAAMC,eAAeX,OAAOY,QAA5B;AACA,UAAKC,cAAL,GAAsBF,aAAaG,SAAnC;AACA,UAAKC,kBAAL,GAA0BN,UAAUO,UAAV,CAAqBC,OAA/C;AACA,UAAKC,eAAL,GAAuBT,UAAUO,UAAV,CAAqBb,IAA5C;AACA,UAAKgB,oBAAL,GAA4BV,UAAUW,mBAAtC;AAdgB;AAejB;;AAED;;;;;;;;;;;;8BAQUC,Q,EAAUlB,I,EAAM;AAAA;;AACxBA,aAAO,qBAAM,EAAN,EAAUA,IAAV,CAAP;AACA;AACA,aAAO,IAAImB,kBAAJ,CAAY,UAACC,OAAD,EAAUC,MAAV,EAAqB;AACtC,eAAKC,OAAL,GAAeC,IAAf,CAAoB,UAACC,MAAD,EAAY;AAC9B,cAAMC,QAAQ,OAAKC,eAAL,CAAqB,OAAKV,oBAA1B,EAAgD,OAAKW,WAArD,CAAd;AACA,cAAMC,uBAAuB,SAAvBA,oBAAuB,CAACC,OAAD,EAAa;AACxC;AACA,gBAAMC,eAAe,IAAIC,sBAAJ,CAAiBF,OAAjB,EAA0B,OAAKG,SAA/B,EAA0ChC,IAA1C,CAArB;AACA,gBAAMiC,YAAY,OAAKC,QAAL,CAAclC,KAAKmC,GAAnB,CAAlB;AACA;AACA,gBAAIL,aAAaM,WAAb,EAAJ,EAAgC;AAC9B,kBAAIH,SAAJ,EAAe;AAAEJ,wBAAQQ,IAAR;AAAiB;AAClC;AACD;AACD;AACAnB,qBAAS,OAAKoB,aAAL,CAAmBR,aAAaS,IAAhC,CAAT,EAAgDT,aAAahB,OAA7D;AACA;AACA,gBAAImB,SAAJ,EAAe;AAAEJ,sBAAQM,GAAR;AAAgB;AAClC,WAbD;AAcA,iBAAKhC,aAAL,GAAqBqB,OAAOgB,SAAP,CAAiBf,KAAjB,EAAwBG,oBAAxB,CAArB;AACAR,kBAAQ,IAAR;AACD,SAlBD,EAkBGqB,KAlBH,CAkBS,UAACC,MAAD,EAAY;AACnBrB,iBAAOqB,MAAP;AACD,SApBD;AAqBD,OAtBM,CAAP;AAuBD;;AAED;;;;;;;;;;;4BAQQC,O,EAASd,O,EAAS7B,I,EAAM;AAAA;;AAC9BA,aAAO,qBAAM,EAAN,EAAUA,IAAV,CAAP;AACA;AACA,aAAO,IAAImB,kBAAJ,CAAY,UAACC,OAAD,EAAUC,MAAV,EAAqB;AACtC,eAAKC,OAAL,GAAeC,IAAf,CAAoB,UAACC,MAAD,EAAY;AAC9B,cAAMoB,cAAc,OAAKC,eAAL,CAAqB,UAArB,EAAiCF,OAAjC,CAApB;AACAnB,iBAAOsB,IAAP,CAAYF,WAAZ,EAAyB,OAAKhC,kBAA9B,EAAkD,OAAKmC,mBAAL,CAAyBlB,OAAzB,CAAlD;AACAT,kBAAQ,IAAR;AACD,SAJD,EAIGqB,KAJH,CAIS,UAACC,MAAD,EAAY;AACnBrB,iBAAOqB,MAAP;AACD,SAND;AAOD,OARM,CAAP;AASD;;AAED;;;;;;;;iCAKa;AAAA;;AACX,aAAO,IAAIvB,kBAAJ,CAAY,UAACC,OAAD,EAAUC,MAAV,EAAqB;AACtC,YAAI,OAAKpB,gBAAL,KAA0BC,SAA9B,EAAyC;AACvCmB,iBAAO,oBAAP;AACD,SAFD,MAEO;AACL,cAAI,OAAKlB,aAAL,KAAuBD,SAA3B,EAAsC;AACpC,mBAAKC,aAAL,CAAmB6C,WAAnB;AACD;AACD,iBAAK/C,gBAAL,CAAsBgD,UAAtB,CAAiC,YAAM;AACrC,mBAAKC,IAAL,CAAU,YAAV;AACA,mBAAKjD,gBAAL,GAAwBC,SAAxB;AACAkB,oBAAQ,IAAR;AACD,WAJD,EAIGqB,KAJH,CAIS,UAACC,MAAD,EAAY;AACnB,mBAAKzC,gBAAL,GAAwBC,SAAxB;AACAmB,mBAAOqB,MAAP;AACD,WAPD;AAQD;AACF,OAhBM,CAAP;AAiBD;;AAED;;;;;;;;;;8BAOmB;AAAA;;AAAA,UAAX1C,IAAW,uEAAJ,EAAI;;AACjBA,aAAO,qBAAM,KAAKe,eAAX,EAA4Bf,IAA5B,CAAP;AACA,aAAO,IAAImB,kBAAJ,CAAY,UAACC,OAAD,EAAUC,MAAV,EAAqB;AACtC,eAAK8B,kBAAL,GAA0B5B,IAA1B,CAA+B,UAAC6B,eAAD,EAAqB;AAClD,cAAMC,mBAAmBD,gBAAgBvC,UAAzC;AACA,cAAI,OAAKZ,gBAAL,KAA0BC,SAA9B,EAAyC;AACvCkB,oBAAQ,OAAKnB,gBAAb;AACD,WAFD,MAEO;AACL,gBAAI;AACF,kBAAIuB,SAAStB,SAAb;AACA,kBAAI,QAAOE,OAAP,yCAAOA,OAAP,OAAmB,QAAnB,IAA+B,KAAGA,OAAH,KAAiB,kBAApD,EAAwE;AACtE;AACA,oBAAI,OAAKkD,IAAT,EAAe;AACb9B,2BAAS+B,kBAAMC,OAAN,CAAcH,iBAAiBI,IAA/B,EAAqCJ,iBAAiBK,SAAjB,CAA2BnD,KAA3B,CAAiCoD,OAAtE,EAA+E,OAAKC,QAApF,CAAT;AACD,iBAFD,MAEO;AACLpC,2BAAS+B,kBAAMC,OAAN,CAAcH,iBAAiBI,IAA/B,EAAqCJ,iBAAiBK,SAAjB,CAA2BnD,KAA3B,CAAiCsD,IAAtE,CAAT;AACD;AACF,eAPD,MAOO;AACL;AACA,oBAAMC,WAAY,OAAKR,IAAN,GAAc,OAAK5C,cAAL,CAAoBqD,GAApB,CAAwBD,QAAtC,GAAiD,OAAKpD,cAAL,CAAoBoD,QAAtF;AACA,oBAAMD,OAAQ,OAAKP,IAAN,GAAcD,iBAAiBK,SAAjB,CAA2BjD,QAA3B,CAAoCkD,OAAlD,GACXN,iBAAiBK,SAAjB,CAA2BjD,QAA3B,CAAoCoD,IADtC;AAEA,oBAAMG,mBAAsBF,QAAtB,WAAoCT,iBAAiBI,IAArD,SAA6DI,IAA7D,SAAqE,OAAKnD,cAAL,CAAoBuD,QAA/F;AACA,oBAAMC,KAAK,IAAIC,SAAJ,CAAcH,gBAAd,CAAX;AACAxC,yBAAS+B,kBAAMa,IAAN,CAAWF,EAAX,CAAT;AACA1C,uBAAO6C,SAAP,CAAiBC,QAAjB,GAA4B,KAA5B;AACA9C,uBAAO6C,SAAP,CAAiBE,QAAjB,GAA4B,KAA5B;AACA/C,uBAAOgD,KAAP,GAAe,IAAf;AACD;AACD,kBAAM1D,UAAU,qBAAM,OAAKF,kBAAX,EAA+B;AAC7C6D,uBAAOpB,iBAAiBqB,QAAjB,IAA6BrB,iBAAiB7B,MADR;AAE7CmD,0BAAUtB,iBAAiBuB,MAFkB;AAG7CnB,sBAAMJ,iBAAiBwB;AAHsB,eAA/B,CAAhB;AAKArD,qBAAOF,OAAP,CAAeR,OAAf,EAAwB,YAAM;AAC5B,uBAAKb,gBAAL,GAAwBuB,MAAxB;AACA,uBAAK0B,IAAL,CAAU,SAAV;AACA9B,wBAAQ,OAAKnB,gBAAb;AACD,eAJD,EAIG,UAAC6E,GAAD,EAAS;AACV,uBAAK5B,IAAL,CAAU,OAAV,EAAmB4B,GAAnB;AACA,uBAAK7E,gBAAL,GAAwBC,SAAxB;AACAmB,uBAAOyD,GAAP;AACD,eARD;AASD,aAnCD,CAmCE,OAAOpC,MAAP,EAAe;AACfrB,qBAAOqB,MAAP;AACD;AACF;AACF,SA5CD,EA4CGD,KA5CH,CA4CS,UAACC,MAAD,EAAY;AACnBrB,iBAAOqB,MAAP;AACD,SA9CD;AA+CD,OAhDM,CAAP;AAiDD;;;kCAEa;AACZ,aAAQ,KAAKzC,gBAAL,KAA0BC,SAAlC;AACD;;AAED;;AAEA;;;;;;;;;;;oCAQgB6E,I,EAAMpC,O,EAAS;AAC7B,mBAAWoC,IAAX,SAAmB,KAAKL,QAAL,EAAnB,SAAsC/B,OAAtC;AACD;;AAED;;;;;;;;;;;oCAQgBoC,I,EAAMpC,O,EAAS;AAC7B,mBAAWoC,IAAX,SAAmB,KAAKL,QAAL,EAAnB,SAAsC,KAAKA,QAAL,EAAtC,SAAyD/B,OAAzD;AACD;;AAED;;;;;;;;;;;;6BASSR,G,EAAK;AACZ,UAAIA,GAAJ,EAAS;AACP,YAAI,CAAC,wBAAWtC,OAAO,KAAKQ,SAAZ,EAAuB2E,QAAlC,EAA4C7C,GAA5C,CAAL,EAAuD;AACrD8C,kBAAQC,KAAR,CAAc,wBAAd,EADqD,CACZ;AAC1C;AACD,gBAAQ/C,GAAR;AACE,eAAK,QAAL;AACE,mBAAO,KAAP;AACF;AACE,mBAAO,IAAP;AAJJ;AAMD;AACD,aAAO,KAAP;AACD;;;;EA3NuBgD,oB;;kBA+NXpF,W","file":"stompClient.js","sourcesContent":["/**\n * A module that exports an StompClient client\n * which inherits from the SpaceBunny base client\n * @module StompClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\nimport _ from 'lodash';\n\n// Import stomp library\nimport Stomp from 'stompjs';\n\n// Import SpaceBunny main module from which StompClient inherits\nimport SpaceBunny from '../spacebunny';\nimport StompMessage from '../messages/stompMessage';\nconst CONFIG = require('../../config/constants').CONFIG;\n\nclass StompClient extends SpaceBunny {\n\n /**\n * @constructor\n * @param {Object} opts - options must contain Device-Key or connection options\n * (deviceId and secret) for devices.\n */\n constructor(opts) {\n super(opts);\n this._stompConnection = undefined;\n this._subscription = undefined;\n if (typeof process === 'object' && `${process}` === '[object process]') {\n this._protocol = 'stomp';\n } else {\n this._protocol = 'webStomp';\n }\n const stompOpts = CONFIG.stomp;\n const webStompOpts = CONFIG.webStomp;\n this._webSocketOpts = webStompOpts.webSocket;\n this._connectionHeaders = stompOpts.connection.headers;\n this._connectionOpts = stompOpts.connection.opts;\n this._existingQueuePrefix = stompOpts.existingQueuePrefix;\n }\n\n /**\n * Subscribe to input channel\n *\n * @param {function} callback - function called every time a message is received\n * passing the current message as argument\n * @param {Object} options - subscription options\n * @return promise containing the result of the subscription\n */\n onReceive(callback, opts) {\n opts = merge({}, opts);\n // subscribe for input messages\n return new Promise((resolve, reject) => {\n this.connect().then((client) => {\n const topic = this._subcriptionFor(this._existingQueuePrefix, this._inboxTopic);\n const subscriptionCallback = (message) => {\n // Create message object\n const stompMessage = new StompMessage(message, this._deviceId, opts);\n const ackNeeded = this._autoAck(opts.ack);\n // Check if should be accepted or not\n if (stompMessage.blackListed()) {\n if (ackNeeded) { message.nack(); }\n return;\n }\n // Call message callback\n callback(this._parseContent(stompMessage.body), stompMessage.headers);\n // Check if ACK is needed\n if (ackNeeded) { message.ack(); }\n };\n this._subscription = client.subscribe(topic, subscriptionCallback);\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Publish a message on a specific channel\n *\n * @param {String} channel - channel name on which you want to publish a message\n * @param {Object} message - the message payload\n * @param {Object} opts - publication options\n * @return a promise containing the result of the operation\n */\n publish(channel, message, opts) {\n opts = merge({}, opts);\n // Publish message\n return new Promise((resolve, reject) => {\n this.connect().then((client) => {\n const destination = this._destinationFor('exchange', channel);\n client.send(destination, this._connectionHeaders, this._encapsulateContent(message));\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Destroy the connection between the stomp client and broker\n *\n * @return a promise containing the result of the operation\n */\n disconnect() {\n return new Promise((resolve, reject) => {\n if (this._stompConnection === undefined) {\n reject('Invalid connection');\n } else {\n if (this._subscription !== undefined) {\n this._subscription.unsubscribe();\n }\n this._stompConnection.disconnect(() => {\n this.emit('disconnect');\n this._stompConnection = undefined;\n resolve(true);\n }).catch((reason) => {\n this._stompConnection = undefined;\n reject(reason);\n });\n }\n });\n }\n\n /**\n * Establish an stomp connection with the broker.\n * If a connection already exists, returns the current connection\n *\n * @param {Object} opts - connection options\n * @return a promise containing current connection\n */\n connect(opts = {}) {\n opts = merge(this._connectionOpts, opts);\n return new Promise((resolve, reject) => {\n this.getEndpointConfigs().then((endpointConfigs) => {\n const connectionParams = endpointConfigs.connection;\n if (this._stompConnection !== undefined) {\n resolve(this._stompConnection);\n } else {\n try {\n let client = undefined;\n if (typeof process === 'object' && `${process}` === '[object process]') {\n // code is runnning in nodejs: STOMP uses TCP sockets\n if (this._tls) {\n client = Stomp.overTCP(connectionParams.host, connectionParams.protocols.stomp.tlsPort, this._tlsOpts);\n } else {\n client = Stomp.overTCP(connectionParams.host, connectionParams.protocols.stomp.port);\n }\n } else {\n // code is runnning in a browser: web STOMP uses Web sockets\n const protocol = (this._tls) ? this._webSocketOpts.tls.protocol : this._webSocketOpts.protocol;\n const port = (this._tls) ? connectionParams.protocols.webStomp.tlsPort :\n connectionParams.protocols.webStomp.port;\n const connectionString = `${protocol}://${connectionParams.host}:${port}/${this._webSocketOpts.endpoint}`;\n const ws = new WebSocket(connectionString);\n client = Stomp.over(ws);\n client.heartbeat.outgoing = 10000;\n client.heartbeat.incoming = 10000;\n client.debug = null;\n }\n const headers = merge(this._connectionHeaders, {\n login: connectionParams.deviceId || connectionParams.client,\n passcode: connectionParams.secret,\n host: connectionParams.vhost\n });\n client.connect(headers, () => {\n this._stompConnection = client;\n this.emit('connect');\n resolve(this._stompConnection);\n }, (err) => {\n this.emit('error', err);\n this._stompConnection = undefined;\n reject(err);\n });\n } catch (reason) {\n reject(reason);\n }\n }\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n isConnected() {\n return (this._stompConnection !== undefined);\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Generate the subscription string for a specific channel\n *\n * @private\n * @param {String} type - resource type on which subscribe or publish [exchange/queue]\n * @param {String} channel - channel name on which you want to publish a message\n * @return a string that represents the topic name for that channel\n */\n _subcriptionFor(type, channel) {\n return `/${type}/${this.deviceId()}.${channel}`;\n }\n\n /**\n * Generate the destination string for a specific channel\n *\n * @private\n * @param {String} type - resource type on which subscribe or publish [exchange/queue]\n * @param {String} channel - channel name on which you want to publish a message\n * @return a string that represents the topic name for that channel\n */\n _destinationFor(type, channel) {\n return `/${type}/${this.deviceId()}/${this.deviceId()}.${channel}`;\n }\n\n /**\n * Check if the SDK have to automatically ack messages\n * By default STOMP messages are acked by the server\n * they need to be acked if client subscribes with { ack: 'client' } option\n *\n * @private\n * @param {String} ack - the ack type, it should be 'client' or null\n * @return boolean - true if messages have to be autoacked, false otherwise\n */\n _autoAck(ack) {\n if (ack) {\n if (!_.includes(CONFIG[this._protocol].ackTypes, ack)) {\n console.error('Wrong acknowledge type'); // eslint-disable-line no-console\n }\n switch (ack) {\n case 'client':\n return false;\n default:\n return true;\n }\n }\n return false;\n }\n\n}\n\nexport default StompClient;\n"],"sourceRoot":"../src"} \ No newline at end of file diff --git a/lib/protocols/stompStreamClient.js.map b/lib/protocols/stompStreamClient.js.map index e6e4153..e9a3907 100644 --- a/lib/protocols/stompStreamClient.js.map +++ b/lib/protocols/stompStreamClient.js.map @@ -1 +1 @@ -{"version":3,"sources":["protocols/stompStreamClient.js"],"names":["CONFIG","require","StompStreamClient","opts","_subscriptions","stompStreamOpts","stomp","stream","_exchangePrefix","exchangePrefix","_defaultPattern","defaultPattern","streamHooks","promises","map","streamHook","_attachStreamHook","length","Promise","any","reject","deviceId","channel","resolve","_stompConnection","undefined","topic","_topicFor","subscription","unsubscribe","disconnect","catch","reason","cache","emptyFunction","callback","connect","then","client","tempQueue","liveStreamExists","console","error","_cachedStreamTopicFor","_streamTopicFor","_liveStreamSuffix","_streamChannelTopicFor","subscriptionHeaders","messageCallback","message","_parseContent","body","headers","subscribe","type","pattern","streamName","_existingQueuePrefix","liveStreamByName","StompClient","onReceive","publish","_subcriptionFor","_destinationFor"],"mappings":"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","file":"protocols/stompStreamClient.js","sourcesContent":["/**\n * A module that exports an StompStreamClient client\n * which inherits from the Stomp base client\n * @module StompStreamClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\n\n// Import StompClient main module from which StompStreamClient inherits\nimport StompClient from './stompClient';\n\nconst CONFIG = require('../../config/constants').CONFIG;\n\nclass StompStreamClient extends StompClient {\n\n /**\n * @constructor\n * @param {Object} opts - options must contain client and secret for access keys\n */\n constructor(opts) {\n super(opts);\n this._subscriptions = {};\n const stompStreamOpts = CONFIG.stomp.stream;\n this._exchangePrefix = stompStreamOpts.exchangePrefix;\n this._defaultPattern = stompStreamOpts.defaultPattern;\n }\n\n /**\n * Subscribe to multiple stream hooks\n *\n * @param {Array} streamHooks - Array of objects. Each objects containing\n * { deviceId: {string}, channel: {string}, callback: {func} }\n * @param {Object} options - subscription options\n * @return promise containing the result of multiple subscriptions\n */\n streamFrom(streamHooks = [], opts) {\n const promises = streamHooks.map((streamHook) => {\n return this._attachStreamHook(streamHook, opts);\n }) || [];\n if (promises.length > 0) {\n return Promise.any(promises);\n } else {\n return Promise.reject('Missing stream hooks');\n }\n }\n\n /**\n * Unsubscribe client from a topic\n *\n * @param {String} deviceId - Device uuid\n * @param {String} channel - channel name\n * @return a promise containing the result of the operation\n */\n unsubscribe(deviceId, channel) {\n return new Promise((resolve, reject) => {\n if (this._stompConnection === undefined) {\n reject('Invalid connection');\n } else {\n const topic = this._topicFor(deviceId, channel);\n const subscription = this._subscriptions[topic];\n subscription.unsubscribe(topic);\n delete this._subscriptions[topic];\n resolve(true);\n }\n });\n }\n\n /**\n * Destroy the connection between the stomp client and broker\n *\n * @return a promise containing the result of the operation\n */\n disconnect() {\n return new Promise((resolve, reject) => {\n if (this._stompConnection === undefined) {\n reject('Invalid connection');\n } else {\n for (const subscription in this._subscriptions) {\n if (subscription) {\n this._subscriptions[subscription].unsubscribe();\n }\n }\n this._subscriptions = {};\n this._stompConnection.disconnect(() => {\n this._stompConnection = undefined;\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n }\n });\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Start consuming messages from a device's channel\n * It generates an auto delete queue from which consume\n * and binds it to the channel exchange\n *\n * @private\n * @param {Object} streamHook - Object containit hook info\n * { deviceId: {String}, channel: {String}, callback: {func}}\n * @param {Object} opts - connection options\n * @return a promise containing current connection\n */\n _attachStreamHook(streamHook, opts) {\n opts = merge({}, opts);\n return new Promise((resolve, reject) => {\n // Receive messages from imput queue\n const stream = streamHook.stream;\n const deviceId = streamHook.deviceId;\n const channel = streamHook.channel;\n const cache = (typeof(streamHook.cache) !== 'boolean') ? true : streamHook.cache;\n const emptyFunction = () => { return undefined; };\n const callback = streamHook.callback || emptyFunction;\n if (stream === undefined && (channel === undefined || deviceId === undefined)) {\n reject('Missing Stream or Device ID and Channel');\n }\n this.connect().then((client) => {\n let topic = undefined;\n let tempQueue = undefined;\n if (stream) {\n if (!this.liveStreamExists(stream)) {\n console.error(`Stream ${stream} does not exist`); // eslint-disable-line no-console\n resolve(false);\n }\n if (cache) {\n // Cached streams are connected to the existing live stream queue\n topic = this._cachedStreamTopicFor(stream);\n } else {\n // Uncached streams are connected to the stream exchange and create a temp queue\n topic = this._streamTopicFor(stream);\n tempQueue = this.tempQueue(stream, this._liveStreamSuffix);\n }\n } else {\n // else if current hook is channel (or a couple deviceId, channel)\n // creates a temp queue, binds to channel exchange and starts consuming\n topic = this._streamChannelTopicFor(deviceId, channel);\n tempQueue = this.tempQueue(deviceId, channel);\n }\n const subscriptionHeaders = {};\n if (tempQueue) { subscriptionHeaders['x-queue-name'] = tempQueue; }\n const messageCallback = (message) => {\n callback(this._parseContent(message.body), message.headers);\n };\n const subscription = client.subscribe(topic, messageCallback, subscriptionHeaders);\n this._subscriptions[topic] = subscription;\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Generate the subscription string for a specific channel\n *\n * @private\n * @param {String} deviceId - deviceId from which you want to stream from\n * @param {String} channel - channel name from which you want to stream from\n * @param {String} type - resource type on which subscribe or publish [exchange/queue]\n * @param {String} pattern - binding pattern\n * @return a string that represents the topic name for that channel\n */\n _streamChannelTopicFor(deviceId, channel, type, pattern) {\n return `/${type || this._exchangePrefix}/${deviceId}.${channel}/${pattern || this._defaultPattern}`;\n }\n\n /**\n * Generate the subscription string for cached live streams\n *\n * @private\n * @param {String} streamName - stream name from which you want to stream\n * @param {String} type - resource type on which subscribe or publish [exchange/queue]\n * @return a string that represents the topic name for that channel\n */\n _cachedStreamTopicFor(streamName, type) {\n return `/${type || this._existingQueuePrefix}/${this.liveStreamByName(streamName)}.` +\n `${this._liveStreamSuffix}`;\n }\n\n /**\n * Generate the subscription for live streams without caching\n *\n * @private\n * @param {String} streamName - stream name from which you want to stream\n * @param {String} type - resource type on which subscribe or publish [exchange/queue]\n * @param {String} pattern - binding pattern\n * @return a string that represents the topic name for that channel\n */\n _streamTopicFor(streamName, type, pattern) {\n return `/${type || this._exchangePrefix}/${this.liveStreamByName(streamName)}.` +\n `${this._liveStreamSuffix}/${pattern || this._defaultPattern}`;\n }\n\n}\n\n// Remove unwnated methods inherited from StompClient\ndelete StompStreamClient.onReceive;\ndelete StompStreamClient.publish;\ndelete StompStreamClient._subcriptionFor;\ndelete StompStreamClient._destinationFor;\n\nexport default StompStreamClient;\n"],"sourceRoot":"./src"} \ No newline at end of file +{"version":3,"sources":["protocols/stompStreamClient.js"],"names":["CONFIG","require","StompStreamClient","opts","_subscriptions","stompStreamOpts","stomp","stream","_exchangePrefix","exchangePrefix","_defaultPattern","defaultPattern","streamHooks","promises","map","streamHook","_attachStreamHook","length","Promise","any","reject","deviceId","channel","resolve","_stompConnection","undefined","topic","_topicFor","subscription","unsubscribe","disconnect","catch","reason","cache","emptyFunction","callback","connect","then","client","tempQueue","liveStreamExists","console","error","_cachedStreamTopicFor","_streamTopicFor","_liveStreamSuffix","_streamChannelTopicFor","subscriptionHeaders","messageCallback","message","_parseContent","body","headers","subscribe","type","pattern","streamName","_existingQueuePrefix","liveStreamByName","StompClient","onReceive","publish","_subcriptionFor","_destinationFor"],"mappings":"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","file":"stompStreamClient.js","sourcesContent":["/**\n * A module that exports an StompStreamClient client\n * which inherits from the Stomp base client\n * @module StompStreamClient\n */\n\n// Import some helpers modules\nimport merge from 'merge';\nimport Promise from 'bluebird';\n\n// Import StompClient main module from which StompStreamClient inherits\nimport StompClient from './stompClient';\n\nconst CONFIG = require('../../config/constants').CONFIG;\n\nclass StompStreamClient extends StompClient {\n\n /**\n * @constructor\n * @param {Object} opts - options must contain client and secret for access keys\n */\n constructor(opts) {\n super(opts);\n this._subscriptions = {};\n const stompStreamOpts = CONFIG.stomp.stream;\n this._exchangePrefix = stompStreamOpts.exchangePrefix;\n this._defaultPattern = stompStreamOpts.defaultPattern;\n }\n\n /**\n * Subscribe to multiple stream hooks\n *\n * @param {Array} streamHooks - Array of objects. Each objects containing\n * { deviceId: {string}, channel: {string}, callback: {func} }\n * @param {Object} options - subscription options\n * @return promise containing the result of multiple subscriptions\n */\n streamFrom(streamHooks = [], opts) {\n const promises = streamHooks.map((streamHook) => {\n return this._attachStreamHook(streamHook, opts);\n }) || [];\n if (promises.length > 0) {\n return Promise.any(promises);\n } else {\n return Promise.reject('Missing stream hooks');\n }\n }\n\n /**\n * Unsubscribe client from a topic\n *\n * @param {String} deviceId - Device uuid\n * @param {String} channel - channel name\n * @return a promise containing the result of the operation\n */\n unsubscribe(deviceId, channel) {\n return new Promise((resolve, reject) => {\n if (this._stompConnection === undefined) {\n reject('Invalid connection');\n } else {\n const topic = this._topicFor(deviceId, channel);\n const subscription = this._subscriptions[topic];\n subscription.unsubscribe(topic);\n delete this._subscriptions[topic];\n resolve(true);\n }\n });\n }\n\n /**\n * Destroy the connection between the stomp client and broker\n *\n * @return a promise containing the result of the operation\n */\n disconnect() {\n return new Promise((resolve, reject) => {\n if (this._stompConnection === undefined) {\n reject('Invalid connection');\n } else {\n for (const subscription in this._subscriptions) {\n if (subscription) {\n this._subscriptions[subscription].unsubscribe();\n }\n }\n this._subscriptions = {};\n this._stompConnection.disconnect(() => {\n this._stompConnection = undefined;\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n }\n });\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Start consuming messages from a device's channel\n * It generates an auto delete queue from which consume\n * and binds it to the channel exchange\n *\n * @private\n * @param {Object} streamHook - Object containit hook info\n * { deviceId: {String}, channel: {String}, callback: {func}}\n * @param {Object} opts - connection options\n * @return a promise containing current connection\n */\n _attachStreamHook(streamHook, opts) {\n opts = merge({}, opts);\n return new Promise((resolve, reject) => {\n // Receive messages from imput queue\n const stream = streamHook.stream;\n const deviceId = streamHook.deviceId;\n const channel = streamHook.channel;\n const cache = (typeof(streamHook.cache) !== 'boolean') ? true : streamHook.cache;\n const emptyFunction = () => { return undefined; };\n const callback = streamHook.callback || emptyFunction;\n if (stream === undefined && (channel === undefined || deviceId === undefined)) {\n reject('Missing Stream or Device ID and Channel');\n }\n this.connect().then((client) => {\n let topic = undefined;\n let tempQueue = undefined;\n if (stream) {\n if (!this.liveStreamExists(stream)) {\n console.error(`Stream ${stream} does not exist`); // eslint-disable-line no-console\n resolve(false);\n }\n if (cache) {\n // Cached streams are connected to the existing live stream queue\n topic = this._cachedStreamTopicFor(stream);\n } else {\n // Uncached streams are connected to the stream exchange and create a temp queue\n topic = this._streamTopicFor(stream);\n tempQueue = this.tempQueue(stream, this._liveStreamSuffix);\n }\n } else {\n // else if current hook is channel (or a couple deviceId, channel)\n // creates a temp queue, binds to channel exchange and starts consuming\n topic = this._streamChannelTopicFor(deviceId, channel);\n tempQueue = this.tempQueue(deviceId, channel);\n }\n const subscriptionHeaders = {};\n if (tempQueue) { subscriptionHeaders['x-queue-name'] = tempQueue; }\n const messageCallback = (message) => {\n callback(this._parseContent(message.body), message.headers);\n };\n const subscription = client.subscribe(topic, messageCallback, subscriptionHeaders);\n this._subscriptions[topic] = subscription;\n resolve(true);\n }).catch((reason) => {\n reject(reason);\n });\n });\n }\n\n /**\n * Generate the subscription string for a specific channel\n *\n * @private\n * @param {String} deviceId - deviceId from which you want to stream from\n * @param {String} channel - channel name from which you want to stream from\n * @param {String} type - resource type on which subscribe or publish [exchange/queue]\n * @param {String} pattern - binding pattern\n * @return a string that represents the topic name for that channel\n */\n _streamChannelTopicFor(deviceId, channel, type, pattern) {\n return `/${type || this._exchangePrefix}/${deviceId}.${channel}/${pattern || this._defaultPattern}`;\n }\n\n /**\n * Generate the subscription string for cached live streams\n *\n * @private\n * @param {String} streamName - stream name from which you want to stream\n * @param {String} type - resource type on which subscribe or publish [exchange/queue]\n * @return a string that represents the topic name for that channel\n */\n _cachedStreamTopicFor(streamName, type) {\n return `/${type || this._existingQueuePrefix}/${this.liveStreamByName(streamName)}.` +\n `${this._liveStreamSuffix}`;\n }\n\n /**\n * Generate the subscription for live streams without caching\n *\n * @private\n * @param {String} streamName - stream name from which you want to stream\n * @param {String} type - resource type on which subscribe or publish [exchange/queue]\n * @param {String} pattern - binding pattern\n * @return a string that represents the topic name for that channel\n */\n _streamTopicFor(streamName, type, pattern) {\n return `/${type || this._exchangePrefix}/${this.liveStreamByName(streamName)}.` +\n `${this._liveStreamSuffix}/${pattern || this._defaultPattern}`;\n }\n\n}\n\n// Remove unwnated methods inherited from StompClient\ndelete StompStreamClient.onReceive;\ndelete StompStreamClient.publish;\ndelete StompStreamClient._subcriptionFor;\ndelete StompStreamClient._destinationFor;\n\nexport default StompStreamClient;\n"],"sourceRoot":"../src"} \ No newline at end of file diff --git a/lib/spacebunny.js b/lib/spacebunny.js index f086b73..fe43dc7 100644 --- a/lib/spacebunny.js +++ b/lib/spacebunny.js @@ -306,7 +306,8 @@ var SpaceBunny = function (_EventEmitter) { key: 'tempQueue', value: function tempQueue(prefix, suffix, currentTime) { var timestamp = currentTime || new Date().getTime(); - return timestamp + '-' + this._connectionParams.client + '-' + (this.exchangeName(prefix, suffix) + '.') + ('' + this._tempQueueSuffix); + var deviceId = this._connectionParams.client || this._connectionParams.deviceId; + return timestamp + '-' + deviceId + '-' + (this.exchangeName(prefix, suffix) + '.') + ('' + this._tempQueueSuffix); } /** diff --git a/lib/spacebunny.js.map b/lib/spacebunny.js.map index 362a2d7..589de0e 100644 --- a/lib/spacebunny.js.map +++ b/lib/spacebunny.js.map @@ -1 +1 @@ -{"version":3,"sources":["spacebunny.js"],"names":["CONFIG","require","SpaceBunny","opts","_connectionParams","humps","camelizeKeys","_endpointConfigs","undefined","_endpoint","endpoint","_deviceKey","deviceKey","_channels","channels","_deviceId","deviceId","_client","client","_secret","secret","_host","host","_port","port","_vhost","vhost","_protocol","protocol","_inboxTopic","inputTopic","inboxTopic","_liveStreamSuffix","liveStreamSuffix","_tempQueueSuffix","tempQueueSuffix","_liveStreams","_tls","tls","_tlsOpts","cert","fs","readFileSync","key","passphrase","ca","Array","isArray","map","element","pfx","disableCertCheck","rejectUnauthorized","secureProtocol","Promise","resolve","reject","hostname","_generateHostname","uri","url","deviceConfigurationsPath","options","method","responseType","headers","then","response","data","connection","catch","err","protocols","tlsPort","liveStreams","liveStreamKeyConfigurationsPath","obj","name","streamName","stream","length","id","prefix","suffix","currentTime","timestamp","Date","getTime","exchangeName","liveStreamByName","content","encapsulatedContent","JSON","stringify","ex","message","parsedMessage","Buffer","isBuffer","toString","res","parse","EventEmitter"],"mappings":"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","file":"spacebunny.js","sourcesContent":["/**\n * A module that exports the base SpaceBunny client\n * @module SpaceBunny\n */\n\n// Import some helpers modules\nimport fs from 'fs';\nimport merge from 'merge';\nimport axios from 'axios';\nimport humps from 'humps';\nimport Promise from 'bluebird';\nimport { startsWith, filter } from 'lodash';\nimport url from 'url';\nimport EventEmitter from 'events';\n\n// TODO validate enpointConfig object format with Joi\n// import Joi from 'joi';\n\nconst CONFIG = require('../config/constants').CONFIG;\n\n/**\n * @constructor\n * @param {Object} opts - constructor options may contain Device-Key or connection options\n */\nclass SpaceBunny extends EventEmitter {\n constructor(opts = {}) {\n super();\n this._connectionParams = merge({}, humps.camelizeKeys(opts));\n this._endpointConfigs = undefined;\n this._endpoint = merge(CONFIG.endpoint, this._connectionParams.endpoint);\n this._deviceKey = this._connectionParams.deviceKey;\n this._channels = this._connectionParams.channels;\n this._deviceId = this._connectionParams.deviceId;\n this._client = this._connectionParams.client;\n this._secret = this._connectionParams.secret;\n this._host = this._connectionParams.host;\n this._port = this._connectionParams.port;\n this._vhost = this._connectionParams.vhost;\n this._protocol = CONFIG.protocol;\n this._inboxTopic = this._connectionParams.inputTopic || CONFIG.inboxTopic;\n this._liveStreamSuffix = CONFIG.liveStreamSuffix;\n this._tempQueueSuffix = CONFIG.tempQueueSuffix;\n this._liveStreams = [];\n this._tls = this._connectionParams.tls || false;\n this._tlsOpts = {};\n if (this._connectionParams.cert) { this._tlsOpts.cert = fs.readFileSync(this._connectionParams.cert); }\n if (this._connectionParams.key) { this._tlsOpts.key = fs.readFileSync(this._connectionParams.key); }\n if (this._connectionParams.passphrase) { this._tlsOpts.passphrase = this._connectionParams.passphrase; }\n if (this._connectionParams.ca) {\n if (Array.isArray(this._connectionParams.ca)) {\n this._tlsOpts.ca = this._connectionParams.ca.map((element) => {\n return fs.readFileSync(element);\n });\n } else {\n this._tlsOpts.ca = [fs.readFileSync(this._connectionParams.ca)];\n }\n }\n if (this._connectionParams.pfx) { this._tlsOpts.pfx = fs.readFileSync(this._connectionParams.pfx); }\n if (this._connectionParams.disableCertCheck) {\n this._tlsOpts.rejectUnauthorized = false;\n } else {\n this._tlsOpts.rejectUnauthorized = true;\n }\n this._tlsOpts.secureProtocol = this._connectionParams.secureProtocol || CONFIG.tls.secureProtocol;\n }\n\n /**\n * Check if Device-Key or connection parameters have already been passed\n * If at least Device-Key is passed ask the endpoint for the configurations\n * else if also connection parameters are not passed raise an exception\n *\n * @return an Object containing the connection parameters\n */\n getEndpointConfigs() {\n return new Promise((resolve, reject) => {\n // Resolve with configs if already retrieved\n if (this._endpointConfigs !== undefined) {\n resolve(this._endpointConfigs);\n }\n // Contact endpoint to retrieve configs\n // Switch endpoint if you are using sdk as device or as access key stream\n if ((this._deviceId && this._secret) || this._deviceKey) { // Device credentials\n // uses endpoint passed from user, default endpoint otherwise\n const hostname = this._generateHostname();\n const uri = url.resolve(hostname, this._endpoint.deviceConfigurationsPath);\n if (this._deviceKey) { // Get configs from endpoint\n const options = {\n url: uri,\n method: 'get',\n responseType: 'json',\n headers: {\n 'Device-Key': this._deviceKey,\n 'Content-Type': 'application/json'\n }\n };\n axios(options).then((response) => {\n this._endpointConfigs = humps.camelizeKeys(response.data);\n this._connectionParams = this._endpointConfigs.connection;\n resolve(this._endpointConfigs);\n }).catch((err) => {\n reject(err);\n });\n } else if (this._deviceId && this._secret && this._host && this._port && this._vhost) {\n // Manually provided configs\n this._connectionParams.protocols = {};\n if (this._tls) {\n this._connectionParams.protocols[this._protocol] = { tlsPort: this._port };\n } else {\n this._connectionParams.protocols[this._protocol] = { port: this._port };\n }\n this._endpointConfigs = {\n connection: this._connectionParams,\n channels: []\n };\n resolve(this._endpointConfigs);\n }\n } else if (this._client && this._secret) { // Access key credentials\n if (this._host && this._port && this._vhost) {\n // Manually provided configs\n this._connectionParams.protocols = {};\n if (this._tls) {\n this._connectionParams.protocols[this._protocol] = { tlsPort: this._port };\n } else {\n this._connectionParams.protocols[this._protocol] = { port: this._port };\n }\n this._endpointConfigs = {\n connection: this._connectionParams,\n liveStreams: []\n };\n resolve(this._endpointConfigs);\n } else {\n // Get configs from endpoint\n // uses endpoint passed from user, default endpoint otherwise\n const hostname = this._generateHostname();\n const uri = url.resolve(hostname, this._endpoint.liveStreamKeyConfigurationsPath);\n const options = {\n url: uri,\n method: 'get',\n responseType: 'json',\n headers: {\n 'Live-Stream-Key-Client': this._client,\n 'Live-Stream-Key-Secret': this._secret,\n 'Content-Type': 'application/json'\n }\n };\n axios(options).then((response) => {\n this._endpointConfigs = humps.camelizeKeys(response.data);\n this._connectionParams = this._endpointConfigs.connection;\n this._liveStreams = this._endpointConfigs.liveStreams || [];\n resolve(this._endpointConfigs);\n }).catch((err) => {\n reject(err);\n });\n }\n } else { // No configs or missing some info\n reject('Missing Device Key or wrong connection parameters');\n }\n });\n }\n\n /**\n * @return all channels configured for the current device\n */\n channels() {\n if (this._endpointConfigs.channels) {\n this._channels = this._endpointConfigs.channels.map((obj) => {\n return obj.name;\n });\n return this._channels || [];\n } else {\n return [];\n }\n }\n\n /**\n * @return the device ID for the current device\n */\n deviceId() {\n this._deviceId = this._deviceId || this._connectionParams.deviceId;\n return this._deviceId;\n }\n\n /**\n * Return a Stream ID from a stream name given in input\n *\n * @param {String} streamName - stream name\n * @return the stream ID which corresponds to the input stream name\n */\n liveStreamByName(streamName) {\n const liveStreams = filter(this._liveStreams, (stream) => { return stream.name === streamName; });\n if (liveStreams.length > 0) {\n return liveStreams[0].id || streamName;\n } else {\n return streamName;\n }\n }\n\n /**\n * Check if a stream exists\n *\n * @param {String} streamName - stream name\n * @return true if stream exists, false otherwise\n */\n liveStreamExists(streamName) {\n const liveStreams = filter(this._liveStreams, (stream) => { return stream.name === streamName; });\n return (liveStreams.length > 0);\n }\n\n /**\n * Generate a temporary queue name\n *\n * @private\n * @param {String} prefix - client id or stream name\n * @param {String} suffix - channel name or defaul live stream suffix\n * @param {Numeric} currentTime - current timestamp\n * @return a string that represents the topic name for that channel\n */\n tempQueue(prefix, suffix, currentTime) {\n const timestamp = currentTime || new Date().getTime();\n return `${timestamp}-${this._connectionParams.client}-` +\n `${this.exchangeName(prefix, suffix)}.` +\n `${this._tempQueueSuffix}`;\n }\n\n /**\n * Generate the exchange name for a device's channel\n *\n * @private\n * @param {String} prefix - It could be a device id or a stream name\n * @param {String} suffix - It could be a channel name or a the default stream suffix (live_stream)\n * @return a string that represents the complete exchange name\n */\n exchangeName(prefix, suffix) {\n return (prefix && suffix) ? `${this.liveStreamByName(prefix)}.${suffix}` : `${suffix}`;\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Encapsulates contens for publishing messages.\n * If the content is a valid JSON the function stringifies the content\n *\n * @private\n * @param {Object} content - content to publish, could be a string or a JSON object\n * @return the content encapsulated in the proper way\n */\n _encapsulateContent(content) {\n let encapsulatedContent = content;\n try {\n encapsulatedContent = JSON.stringify(content);\n } catch (ex) {\n encapsulatedContent = content;\n }\n return encapsulatedContent;\n }\n\n /**\n * Generate the complete hostname string for an endpoint\n *\n * @private\n * @return the string representing the endpoint url\n */\n _generateHostname() {\n if (this._endpoint.url) {\n return this._endpoint.url;\n }\n let hostname = `${this._endpoint.host}:${this._endpoint.port}`;\n const protocol = (this._tls) ? this._endpoint.secureProtocol : this._endpoint.protocol;\n if (!startsWith(hostname, protocol)) {\n hostname = `${protocol}://${hostname}`;\n }\n return hostname;\n }\n\n /**\n * Automatically parse message content\n *\n * @private\n * @param {Object/String} message - the received message\n * @return an object containing the input message with parsed content\n */\n _parseContent(message) {\n let parsedMessage = message;\n if (Buffer.isBuffer(parsedMessage)) {\n parsedMessage = parsedMessage.toString('utf-8');\n }\n let res = undefined;\n try {\n res = JSON.parse(parsedMessage);\n } catch (ex) {\n res = parsedMessage;\n }\n return res;\n }\n\n}\n\nexport default SpaceBunny;\n"],"sourceRoot":"./src"} \ No newline at end of file +{"version":3,"sources":["spacebunny.js"],"names":["CONFIG","require","SpaceBunny","opts","_connectionParams","humps","camelizeKeys","_endpointConfigs","undefined","_endpoint","endpoint","_deviceKey","deviceKey","_channels","channels","_deviceId","deviceId","_client","client","_secret","secret","_host","host","_port","port","_vhost","vhost","_protocol","protocol","_inboxTopic","inputTopic","inboxTopic","_liveStreamSuffix","liveStreamSuffix","_tempQueueSuffix","tempQueueSuffix","_liveStreams","_tls","tls","_tlsOpts","cert","fs","readFileSync","key","passphrase","ca","Array","isArray","map","element","pfx","disableCertCheck","rejectUnauthorized","secureProtocol","Promise","resolve","reject","hostname","_generateHostname","uri","url","deviceConfigurationsPath","options","method","responseType","headers","then","response","data","connection","catch","err","protocols","tlsPort","liveStreams","liveStreamKeyConfigurationsPath","obj","name","streamName","stream","length","id","prefix","suffix","currentTime","timestamp","Date","getTime","exchangeName","liveStreamByName","content","encapsulatedContent","JSON","stringify","ex","message","parsedMessage","Buffer","isBuffer","toString","res","parse","EventEmitter"],"mappings":"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","file":"spacebunny.js","sourcesContent":["/**\n * A module that exports the base SpaceBunny client\n * @module SpaceBunny\n */\n\n// Import some helpers modules\nimport fs from 'fs';\nimport merge from 'merge';\nimport axios from 'axios';\nimport humps from 'humps';\nimport Promise from 'bluebird';\nimport { startsWith, filter } from 'lodash';\nimport url from 'url';\nimport EventEmitter from 'events';\n\n// TODO validate enpointConfig object format with Joi\n// import Joi from 'joi';\n\nconst CONFIG = require('../config/constants').CONFIG;\n\n/**\n * @constructor\n * @param {Object} opts - constructor options may contain Device-Key or connection options\n */\nclass SpaceBunny extends EventEmitter {\n constructor(opts = {}) {\n super();\n this._connectionParams = merge({}, humps.camelizeKeys(opts));\n this._endpointConfigs = undefined;\n this._endpoint = merge(CONFIG.endpoint, this._connectionParams.endpoint);\n this._deviceKey = this._connectionParams.deviceKey;\n this._channels = this._connectionParams.channels;\n this._deviceId = this._connectionParams.deviceId;\n this._client = this._connectionParams.client;\n this._secret = this._connectionParams.secret;\n this._host = this._connectionParams.host;\n this._port = this._connectionParams.port;\n this._vhost = this._connectionParams.vhost;\n this._protocol = CONFIG.protocol;\n this._inboxTopic = this._connectionParams.inputTopic || CONFIG.inboxTopic;\n this._liveStreamSuffix = CONFIG.liveStreamSuffix;\n this._tempQueueSuffix = CONFIG.tempQueueSuffix;\n this._liveStreams = [];\n this._tls = this._connectionParams.tls || false;\n this._tlsOpts = {};\n if (this._connectionParams.cert) { this._tlsOpts.cert = fs.readFileSync(this._connectionParams.cert); }\n if (this._connectionParams.key) { this._tlsOpts.key = fs.readFileSync(this._connectionParams.key); }\n if (this._connectionParams.passphrase) { this._tlsOpts.passphrase = this._connectionParams.passphrase; }\n if (this._connectionParams.ca) {\n if (Array.isArray(this._connectionParams.ca)) {\n this._tlsOpts.ca = this._connectionParams.ca.map((element) => {\n return fs.readFileSync(element);\n });\n } else {\n this._tlsOpts.ca = [fs.readFileSync(this._connectionParams.ca)];\n }\n }\n if (this._connectionParams.pfx) { this._tlsOpts.pfx = fs.readFileSync(this._connectionParams.pfx); }\n if (this._connectionParams.disableCertCheck) {\n this._tlsOpts.rejectUnauthorized = false;\n } else {\n this._tlsOpts.rejectUnauthorized = true;\n }\n this._tlsOpts.secureProtocol = this._connectionParams.secureProtocol || CONFIG.tls.secureProtocol;\n }\n\n /**\n * Check if Device-Key or connection parameters have already been passed\n * If at least Device-Key is passed ask the endpoint for the configurations\n * else if also connection parameters are not passed raise an exception\n *\n * @return an Object containing the connection parameters\n */\n getEndpointConfigs() {\n return new Promise((resolve, reject) => {\n // Resolve with configs if already retrieved\n if (this._endpointConfigs !== undefined) {\n resolve(this._endpointConfigs);\n }\n // Contact endpoint to retrieve configs\n // Switch endpoint if you are using sdk as device or as access key stream\n if ((this._deviceId && this._secret) || this._deviceKey) { // Device credentials\n // uses endpoint passed from user, default endpoint otherwise\n const hostname = this._generateHostname();\n const uri = url.resolve(hostname, this._endpoint.deviceConfigurationsPath);\n if (this._deviceKey) { // Get configs from endpoint\n const options = {\n url: uri,\n method: 'get',\n responseType: 'json',\n headers: {\n 'Device-Key': this._deviceKey,\n 'Content-Type': 'application/json'\n }\n };\n axios(options).then((response) => {\n this._endpointConfigs = humps.camelizeKeys(response.data);\n this._connectionParams = this._endpointConfigs.connection;\n resolve(this._endpointConfigs);\n }).catch((err) => {\n reject(err);\n });\n } else if (this._deviceId && this._secret && this._host && this._port && this._vhost) {\n // Manually provided configs\n this._connectionParams.protocols = {};\n if (this._tls) {\n this._connectionParams.protocols[this._protocol] = { tlsPort: this._port };\n } else {\n this._connectionParams.protocols[this._protocol] = { port: this._port };\n }\n this._endpointConfigs = {\n connection: this._connectionParams,\n channels: []\n };\n resolve(this._endpointConfigs);\n }\n } else if (this._client && this._secret) { // Access key credentials\n if (this._host && this._port && this._vhost) {\n // Manually provided configs\n this._connectionParams.protocols = {};\n if (this._tls) {\n this._connectionParams.protocols[this._protocol] = { tlsPort: this._port };\n } else {\n this._connectionParams.protocols[this._protocol] = { port: this._port };\n }\n this._endpointConfigs = {\n connection: this._connectionParams,\n liveStreams: []\n };\n resolve(this._endpointConfigs);\n } else {\n // Get configs from endpoint\n // uses endpoint passed from user, default endpoint otherwise\n const hostname = this._generateHostname();\n const uri = url.resolve(hostname, this._endpoint.liveStreamKeyConfigurationsPath);\n const options = {\n url: uri,\n method: 'get',\n responseType: 'json',\n headers: {\n 'Live-Stream-Key-Client': this._client,\n 'Live-Stream-Key-Secret': this._secret,\n 'Content-Type': 'application/json'\n }\n };\n axios(options).then((response) => {\n this._endpointConfigs = humps.camelizeKeys(response.data);\n this._connectionParams = this._endpointConfigs.connection;\n this._liveStreams = this._endpointConfigs.liveStreams || [];\n resolve(this._endpointConfigs);\n }).catch((err) => {\n reject(err);\n });\n }\n } else { // No configs or missing some info\n reject('Missing Device Key or wrong connection parameters');\n }\n });\n }\n\n /**\n * @return all channels configured for the current device\n */\n channels() {\n if (this._endpointConfigs.channels) {\n this._channels = this._endpointConfigs.channels.map((obj) => {\n return obj.name;\n });\n return this._channels || [];\n } else {\n return [];\n }\n }\n\n /**\n * @return the device ID for the current device\n */\n deviceId() {\n this._deviceId = this._deviceId || this._connectionParams.deviceId;\n return this._deviceId;\n }\n\n /**\n * Return a Stream ID from a stream name given in input\n *\n * @param {String} streamName - stream name\n * @return the stream ID which corresponds to the input stream name\n */\n liveStreamByName(streamName) {\n const liveStreams = filter(this._liveStreams, (stream) => { return stream.name === streamName; });\n if (liveStreams.length > 0) {\n return liveStreams[0].id || streamName;\n } else {\n return streamName;\n }\n }\n\n /**\n * Check if a stream exists\n *\n * @param {String} streamName - stream name\n * @return true if stream exists, false otherwise\n */\n liveStreamExists(streamName) {\n const liveStreams = filter(this._liveStreams, (stream) => { return stream.name === streamName; });\n return (liveStreams.length > 0);\n }\n\n /**\n * Generate a temporary queue name\n *\n * @private\n * @param {String} prefix - client id or stream name\n * @param {String} suffix - channel name or defaul live stream suffix\n * @param {Numeric} currentTime - current timestamp\n * @return a string that represents the topic name for that channel\n */\n tempQueue(prefix, suffix, currentTime) {\n const timestamp = currentTime || new Date().getTime();\n const deviceId = this._connectionParams.client || this._connectionParams.deviceId;\n return `${timestamp}-${deviceId}-` +\n `${this.exchangeName(prefix, suffix)}.` +\n `${this._tempQueueSuffix}`;\n }\n\n /**\n * Generate the exchange name for a device's channel\n *\n * @private\n * @param {String} prefix - It could be a device id or a stream name\n * @param {String} suffix - It could be a channel name or a the default stream suffix (live_stream)\n * @return a string that represents the complete exchange name\n */\n exchangeName(prefix, suffix) {\n return (prefix && suffix) ? `${this.liveStreamByName(prefix)}.${suffix}` : `${suffix}`;\n }\n\n // ------------ PRIVATE METHODS -------------------\n\n /**\n * Encapsulates contens for publishing messages.\n * If the content is a valid JSON the function stringifies the content\n *\n * @private\n * @param {Object} content - content to publish, could be a string or a JSON object\n * @return the content encapsulated in the proper way\n */\n _encapsulateContent(content) {\n let encapsulatedContent = content;\n try {\n encapsulatedContent = JSON.stringify(content);\n } catch (ex) {\n encapsulatedContent = content;\n }\n return encapsulatedContent;\n }\n\n /**\n * Generate the complete hostname string for an endpoint\n *\n * @private\n * @return the string representing the endpoint url\n */\n _generateHostname() {\n if (this._endpoint.url) {\n return this._endpoint.url;\n }\n let hostname = `${this._endpoint.host}:${this._endpoint.port}`;\n const protocol = (this._tls) ? this._endpoint.secureProtocol : this._endpoint.protocol;\n if (!startsWith(hostname, protocol)) {\n hostname = `${protocol}://${hostname}`;\n }\n return hostname;\n }\n\n /**\n * Automatically parse message content\n *\n * @private\n * @param {Object/String} message - the received message\n * @return an object containing the input message with parsed content\n */\n _parseContent(message) {\n let parsedMessage = message;\n if (Buffer.isBuffer(parsedMessage)) {\n parsedMessage = parsedMessage.toString('utf-8');\n }\n let res = undefined;\n try {\n res = JSON.parse(parsedMessage);\n } catch (ex) {\n res = parsedMessage;\n }\n return res;\n }\n\n}\n\nexport default SpaceBunny;\n"],"sourceRoot":"src"} \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index 52c5ed4..04427a1 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4,6 +4,238 @@ "lockfileVersion": 1, "requires": true, "dependencies": { + "@babel/code-frame": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.0.0-beta.44.tgz", + "integrity": "sha512-cuAuTTIQ9RqcFRJ/Y8PvTh+paepNcaGxwQwjIDRWPXmzzyAeCO4KqS9ikMvq0MCbRk6GlYKwfzStrcP3/jSL8g==", + "dev": true, + "requires": { + "@babel/highlight": "7.0.0-beta.44" + } + }, + "@babel/generator": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.0.0-beta.44.tgz", + "integrity": "sha512-5xVb7hlhjGcdkKpMXgicAVgx8syK5VJz193k0i/0sLP6DzE6lRrU1K3B/rFefgdo9LPGMAOOOAWW4jycj07ShQ==", + "dev": true, + "requires": { + "@babel/types": "7.0.0-beta.44", + "jsesc": "2.5.1", + "lodash": "4.17.10", + "source-map": "0.5.7", + "trim-right": "1.0.1" + }, + "dependencies": { + "jsesc": { + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.1.tgz", + "integrity": "sha1-5CGiqOINawgZ3yiQj3glJrlt0f4=", + "dev": true + } + } + }, + "@babel/helper-function-name": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.0.0-beta.44.tgz", + "integrity": "sha512-MHRG2qZMKMFaBavX0LWpfZ2e+hLloT++N7rfM3DYOMUOGCD8cVjqZpwiL8a0bOX3IYcQev1ruciT0gdFFRTxzg==", + "dev": true, + "requires": { + "@babel/helper-get-function-arity": "7.0.0-beta.44", + "@babel/template": "7.0.0-beta.44", + "@babel/types": "7.0.0-beta.44" + } + }, + "@babel/helper-get-function-arity": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0-beta.44.tgz", + "integrity": "sha512-w0YjWVwrM2HwP6/H3sEgrSQdkCaxppqFeJtAnB23pRiJB5E/O9Yp7JAAeWBl+gGEgmBFinnTyOv2RN7rcSmMiw==", + "dev": true, + "requires": { + "@babel/types": "7.0.0-beta.44" + } + }, + "@babel/helper-module-imports": { + "version": "7.0.0-beta.51", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.0.0-beta.51.tgz", + "integrity": "sha1-zgBCgEX7t9XrwOp7+DV4nxU2arI=", + "dev": true, + "requires": { + "@babel/types": "7.0.0-beta.51", + "lodash": "4.17.10" + }, + "dependencies": { + "@babel/types": { + "version": "7.0.0-beta.51", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.0.0-beta.51.tgz", + "integrity": "sha1-2AK3tUO1g2x3iqaReXq/APPZfqk=", + "dev": true, + "requires": { + "esutils": "2.0.2", + "lodash": "4.17.10", + "to-fast-properties": "2.0.0" + } + }, + "to-fast-properties": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", + "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", + "dev": true + } + } + }, + "@babel/helper-split-export-declaration": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.0.0-beta.44.tgz", + "integrity": "sha512-aQ7QowtkgKKzPGf0j6u77kBMdUFVBKNHw2p/3HX/POt5/oz8ec5cs0GwlgM8Hz7ui5EwJnzyfRmkNF1Nx1N7aA==", + "dev": true, + "requires": { + "@babel/types": "7.0.0-beta.44" + } + }, + "@babel/highlight": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.0.0-beta.44.tgz", + "integrity": "sha512-Il19yJvy7vMFm8AVAh6OZzaFoAd0hbkeMZiX3P5HGD+z7dyI7RzndHB0dg6Urh/VAFfHtpOIzDUSxmY6coyZWQ==", + "dev": true, + "requires": { + "chalk": "2.4.1", + "esutils": "2.0.2", + "js-tokens": "3.0.2" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } + } + }, + "@babel/template": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.0.0-beta.44.tgz", + "integrity": "sha512-w750Sloq0UNifLx1rUqwfbnC6uSUk0mfwwgGRfdLiaUzfAOiH0tHJE6ILQIUi3KYkjiCDTskoIsnfqZvWLBDng==", + "dev": true, + "requires": { + "@babel/code-frame": "7.0.0-beta.44", + "@babel/types": "7.0.0-beta.44", + "babylon": "7.0.0-beta.44", + "lodash": "4.17.10" + }, + "dependencies": { + "babylon": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/babylon/-/babylon-7.0.0-beta.44.tgz", + "integrity": "sha512-5Hlm13BJVAioCHpImtFqNOF2H3ieTOHd0fmFGMxOJ9jgeFqeAwsv3u5P5cR7CSeFrkgHsT19DgFJkHV0/Mcd8g==", + "dev": true + } + } + }, + "@babel/traverse": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.0.0-beta.44.tgz", + "integrity": "sha512-UHuDz8ukQkJCDASKHf+oDt3FVUzFd+QYfuBIsiNu/4+/ix6pP/C+uQZJ6K1oEfbCMv/IKWbgDEh7fcsnIE5AtA==", + "dev": true, + "requires": { + "@babel/code-frame": "7.0.0-beta.44", + "@babel/generator": "7.0.0-beta.44", + "@babel/helper-function-name": "7.0.0-beta.44", + "@babel/helper-split-export-declaration": "7.0.0-beta.44", + "@babel/types": "7.0.0-beta.44", + "babylon": "7.0.0-beta.44", + "debug": "3.1.0", + "globals": "11.7.0", + "invariant": "2.2.4", + "lodash": "4.17.10" + }, + "dependencies": { + "babylon": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/babylon/-/babylon-7.0.0-beta.44.tgz", + "integrity": "sha512-5Hlm13BJVAioCHpImtFqNOF2H3ieTOHd0fmFGMxOJ9jgeFqeAwsv3u5P5cR7CSeFrkgHsT19DgFJkHV0/Mcd8g==", + "dev": true + }, + "globals": { + "version": "11.7.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-11.7.0.tgz", + "integrity": "sha512-K8BNSPySfeShBQXsahYB/AbbWruVOTyVpgoIDnl8odPpeSfP2J5QO2oLFFdl2j7GfDCtZj2bMKar2T49itTPCg==", + "dev": true + } + } + }, + "@babel/types": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.0.0-beta.44.tgz", + "integrity": "sha512-5eTV4WRmqbaFM3v9gHAIljEQJU4Ssc6fxL61JN+Oe2ga/BwyjzjamwkCVVAQjHGuAX8i0BWo42dshL8eO5KfLQ==", + "dev": true, + "requires": { + "esutils": "2.0.2", + "lodash": "4.17.10", + "to-fast-properties": "2.0.0" + }, + "dependencies": { + "to-fast-properties": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", + "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", + "dev": true + } + } + }, + "@gulp-sourcemaps/identity-map": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@gulp-sourcemaps/identity-map/-/identity-map-1.0.2.tgz", + "integrity": "sha512-ciiioYMLdo16ShmfHBXJBOFm3xPC4AuwO4xeRpFeHz7WK9PYsWCmigagG2XyzZpubK4a3qNKoUBDhbzHfa50LQ==", + "dev": true, + "requires": { + "acorn": "5.7.1", + "css": "2.2.3", + "normalize-path": "2.1.1", + "source-map": "0.6.1", + "through2": "2.0.3" + }, + "dependencies": { + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true + } + } + }, + "@gulp-sourcemaps/map-sources": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@gulp-sourcemaps/map-sources/-/map-sources-1.0.0.tgz", + "integrity": "sha1-iQrnxdjId/bThIYCFazp1+yUW9o=", + "dev": true, + "requires": { + "normalize-path": "2.1.1", + "through2": "2.0.3" + } + }, "Base64": { "version": "0.2.1", "resolved": "https://registry.npmjs.org/Base64/-/Base64-0.2.1.tgz", @@ -16,12 +248,6 @@ "integrity": "sha1-X6rZwsB/YN12dw9xzwJbYqY8/U4=", "dev": true }, - "abbrev": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.9.tgz", - "integrity": "sha1-kbR5JYinc4wl813W9jdSovh3YTU=", - "dev": true - }, "accepts": { "version": "1.3.5", "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.5.tgz", @@ -33,53 +259,45 @@ } }, "acorn": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-3.3.0.tgz", - "integrity": "sha1-ReN/s56No/JbruP/U2niu18iAXo=", + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-5.7.1.tgz", + "integrity": "sha512-d+nbxBUGKg7Arpsvbnlq61mc12ek3EY8EQldM3GPAhWJ1UVxC6TDGbIvUMNU6obBX3i1+ptCIzV4vq0gFPEGVQ==", "dev": true }, "acorn-globals": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/acorn-globals/-/acorn-globals-3.1.0.tgz", - "integrity": "sha1-/YJw9x+7SZawBPqIDuXUZXOnMb8=", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/acorn-globals/-/acorn-globals-4.1.0.tgz", + "integrity": "sha512-KjZwU26uG3u6eZcfGbTULzFcsoz6pegNKtHPksZPOUsiKo5bUmiBPa38FuHZ/Eun+XYh/JCCkS9AS3Lu4McQOQ==", "dev": true, "requires": { - "acorn": "4.0.13" - }, - "dependencies": { - "acorn": { - "version": "4.0.13", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-4.0.13.tgz", - "integrity": "sha1-EFSVrlNh1pe9GVyCUZLhrX8lN4c=", - "dev": true - } + "acorn": "5.7.1" } }, "acorn-jsx": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-3.0.1.tgz", - "integrity": "sha1-r9+UiPsezvyDSPb7IvRk4ypYs2s=", + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-4.1.1.tgz", + "integrity": "sha512-JY+iV6r+cO21KtntVvFkD+iqjtdpRUpGqKWgfkCdZq1R+kbreEl8EcdcJR4SmiIgsIQT33s6QzheQ9a275Q8xw==", "dev": true, "requires": { - "acorn": "3.3.0" + "acorn": "5.7.1" } }, "ajv": { - "version": "5.5.2", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-5.5.2.tgz", - "integrity": "sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU=", + "version": "6.5.2", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.5.2.tgz", + "integrity": "sha512-hOs7GfvI6tUI1LfZddH82ky6mOMyTuY0mk7kE2pWpmhhUSkumzaTO5vbVwij39MdwPQWCV4Zv57Eo06NtL/GVA==", "dev": true, "requires": { - "co": "4.6.0", - "fast-deep-equal": "1.1.0", + "fast-deep-equal": "2.0.1", "fast-json-stable-stringify": "2.0.0", - "json-schema-traverse": "0.3.1" + "json-schema-traverse": "0.4.1", + "uri-js": "4.2.2" } }, "ajv-keywords": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-1.5.1.tgz", - "integrity": "sha1-MU3QpLM2j609/NxU7eYXG4htrzw=", + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.2.0.tgz", + "integrity": "sha1-6GuBnGAs+IIa1jdBNpjx3sAhhHo=", "dev": true }, "align-text": { @@ -100,21 +318,24 @@ "dev": true }, "amqplib": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/amqplib/-/amqplib-0.4.0.tgz", - "integrity": "sha1-nv52Vt2oWnNZ9mSicm6OhSKeEkw=", + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/amqplib/-/amqplib-0.5.2.tgz", + "integrity": "sha512-l9mCs6LbydtHqRniRwYkKdqxVa6XMz3Vw1fh+2gJaaVgTM6Jk3o8RccAKWKtlhT1US5sWrFh+KKxsVUALURSIA==", "requires": { "bitsyntax": "0.0.4", + "bluebird": "3.5.1", "buffer-more-ints": "0.0.2", "readable-stream": "1.1.14", - "when": "3.6.4" - }, - "dependencies": { - "when": { - "version": "3.6.4", - "resolved": "https://registry.npmjs.org/when/-/when-3.6.4.tgz", - "integrity": "sha1-RztRfsFZ4rhQBUl6E5g/CVQS404=" - } + "safe-buffer": "5.1.2" + } + }, + "ansi-colors": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-1.1.0.tgz", + "integrity": "sha512-SFKX67auSNoVR38N3L+nvsPjOE0bybKTYbkf5tRvushrAPQ9V75huw0ZxBkKVeRU9kqH3d6HA4xTckbwZ4ixmA==", + "dev": true, + "requires": { + "ansi-wrap": "0.1.0" } }, "ansi-escape-sequences": { @@ -127,9 +348,9 @@ } }, "ansi-escapes": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-1.4.0.tgz", - "integrity": "sha1-06ioOzGapneTZisT52HHkRQiMG4=", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.1.0.tgz", + "integrity": "sha512-UgAb8H9D41AQnu/PbWlCofQVcnV4Gs2bBJi9eZPxfU/hgglFh3SMDMENRIqdr7H6XFnXdoknctFByVsCOotTVw==", "dev": true }, "ansi-gray": { @@ -183,6 +404,15 @@ "usage-stats": "0.8.6" } }, + "append-transform": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/append-transform/-/append-transform-1.0.0.tgz", + "integrity": "sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw==", + "dev": true, + "requires": { + "default-require-extensions": "2.0.0" + } + }, "archy": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz", @@ -198,6 +428,16 @@ "sprintf-js": "1.0.3" } }, + "aria-query": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/aria-query/-/aria-query-3.0.0.tgz", + "integrity": "sha1-ZbP8wcoRVajJrmTW7uKX8V1RM8w=", + "dev": true, + "requires": { + "ast-types-flow": "0.0.7", + "commander": "2.16.0" + } + }, "arr-diff": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-2.0.0.tgz", @@ -246,18 +486,22 @@ "integrity": "sha1-jCpe8kcv2ep0KwTHenUJO6J1fJM=", "dev": true }, - "array-find-index": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/array-find-index/-/array-find-index-1.0.2.tgz", - "integrity": "sha1-3wEKoSh+Fku9pvlyOwqWoexBh6E=", - "dev": true - }, "array-flatten": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", "integrity": "sha1-ml9pkFGx5wczKPKgCJaLZOopVdI=", "dev": true }, + "array-includes": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/array-includes/-/array-includes-3.0.3.tgz", + "integrity": "sha1-GEtI9i2S10UrsxsyMWXH+L0CJm0=", + "dev": true, + "requires": { + "define-properties": "1.1.2", + "es-abstract": "1.12.0" + } + }, "array-slice": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/array-slice/-/array-slice-1.1.0.tgz", @@ -374,6 +618,18 @@ "integrity": "sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c=", "dev": true }, + "ast-types-flow": { + "version": "0.0.7", + "resolved": "https://registry.npmjs.org/ast-types-flow/-/ast-types-flow-0.0.7.tgz", + "integrity": "sha1-9wtzXGvKGlycItmCw+Oef+ujva0=", + "dev": true + }, + "astral-regex": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz", + "integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==", + "dev": true + }, "async": { "version": "0.2.10", "resolved": "https://registry.npmjs.org/async/-/async-0.2.10.tgz", @@ -387,6 +643,11 @@ "integrity": "sha1-GdOGodntxufByF04iu28xW0zYC0=", "dev": true }, + "async-limiter": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.0.tgz", + "integrity": "sha512-jp/uFnooOiO+L211eZOoSyzpOITMXx1rBITauYykG3BRYPu8h0UcxsPNB04RR5vo4Tyz3+ay17tR6JVf9qzYWg==" + }, "asynckit": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", @@ -412,53 +673,50 @@ "dev": true }, "axios": { - "version": "0.11.0", - "resolved": "https://registry.npmjs.org/axios/-/axios-0.11.0.tgz", - "integrity": "sha1-UK3Fm9DxG+6Jo4OySy1Adkjm1ug=", + "version": "0.18.0", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.18.0.tgz", + "integrity": "sha1-MtU+SFHv3AoRmTts0AB4nXDAUQI=", + "requires": { + "follow-redirects": "1.5.0", + "is-buffer": "1.1.6" + } + }, + "axobject-query": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/axobject-query/-/axobject-query-2.0.1.tgz", + "integrity": "sha1-Bd+nBa2orZ25k/polvItOVsLCgc=", + "dev": true, "requires": { - "follow-redirects": "0.0.7" + "ast-types-flow": "0.0.7" } }, "babel": { - "version": "6.5.1", - "resolved": "http://registry.npmjs.org/babel/-/babel-6.5.1.tgz", - "integrity": "sha1-FzadfW8mgtXet0HWW/1fdGvhI6s=", + "version": "6.23.0", + "resolved": "https://registry.npmjs.org/babel/-/babel-6.23.0.tgz", + "integrity": "sha1-0NHn2APpdHZb7qMjLU4VPA77kPQ=", "dev": true }, "babel-cli": { - "version": "6.8.0", - "resolved": "https://registry.npmjs.org/babel-cli/-/babel-cli-6.8.0.tgz", - "integrity": "sha1-EPDxJgok7ZRwWAsIblhfO2V8B+E=", + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-cli/-/babel-cli-6.26.0.tgz", + "integrity": "sha1-UCq1SHTX24itALiHoGODzgPQAvE=", "dev": true, "requires": { - "babel-core": "6.8.0", + "babel-core": "6.26.3", "babel-polyfill": "6.26.0", "babel-register": "6.26.0", "babel-runtime": "6.26.0", - "bin-version-check": "2.1.0", - "chalk": "1.1.1", "chokidar": "1.7.0", "commander": "2.16.0", "convert-source-map": "1.5.1", - "fs-readdir-recursive": "0.1.2", - "glob": "5.0.15", - "lodash": "3.10.1", - "log-symbols": "1.0.2", + "fs-readdir-recursive": "1.1.0", + "glob": "7.1.2", + "lodash": "4.17.10", "output-file-sync": "1.1.2", - "path-exists": "1.0.0", "path-is-absolute": "1.0.1", - "request": "2.87.0", "slash": "1.0.0", "source-map": "0.5.7", "v8flags": "2.1.1" - }, - "dependencies": { - "lodash": { - "version": "3.10.1", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-3.10.1.tgz", - "integrity": "sha1-W/Rejkm6QYnhfUgnid/RW9FAt7Y=", - "dev": true - } } }, "babel-code-frame": { @@ -470,27 +728,12 @@ "chalk": "1.1.3", "esutils": "2.0.2", "js-tokens": "3.0.2" - }, - "dependencies": { - "chalk": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", - "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", - "dev": true, - "requires": { - "ansi-styles": "2.2.1", - "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" - } - } } }, "babel-core": { - "version": "6.8.0", - "resolved": "https://registry.npmjs.org/babel-core/-/babel-core-6.8.0.tgz", - "integrity": "sha1-Uv3gtMBdnrf2Cto8dWZiOPFNFCA=", + "version": "6.26.3", + "resolved": "https://registry.npmjs.org/babel-core/-/babel-core-6.26.3.tgz", + "integrity": "sha512-6jyFLuDmeidKmUEb3NM+/yawG0M2bDZ9Z1qbZP59cyHLz8kYGKYwpJP0UwUKKUiTRNvxfLesJnTedqczP7cTDA==", "dev": true, "requires": { "babel-code-frame": "6.26.0", @@ -505,36 +748,46 @@ "babylon": "6.18.0", "convert-source-map": "1.5.1", "debug": "2.6.9", - "json5": "0.4.0", - "lodash": "3.10.1", - "minimatch": "2.0.10", - "path-exists": "1.0.0", + "json5": "0.5.1", + "lodash": "4.17.10", + "minimatch": "3.0.4", "path-is-absolute": "1.0.1", "private": "0.1.8", - "shebang-regex": "1.0.0", "slash": "1.0.0", "source-map": "0.5.7" }, "dependencies": { - "lodash": { - "version": "3.10.1", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-3.10.1.tgz", - "integrity": "sha1-W/Rejkm6QYnhfUgnid/RW9FAt7Y=", - "dev": true + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } } } }, "babel-eslint": { - "version": "6.0.4", - "resolved": "https://registry.npmjs.org/babel-eslint/-/babel-eslint-6.0.4.tgz", - "integrity": "sha1-z4fc1RYkGy4B2F6A4I6EmiMr3vc=", + "version": "8.2.5", + "resolved": "https://registry.npmjs.org/babel-eslint/-/babel-eslint-8.2.5.tgz", + "integrity": "sha512-TcdEGCHHquOPQOlH6Fe6MLwPWWWJLdeKhcGoLfOTShETpoH8XYWhjWJw38KCKaTca7c/EdxLolnbakixKxnXDg==", "dev": true, "requires": { - "babel-traverse": "6.26.0", - "babel-types": "6.26.0", - "babylon": "6.18.0", - "lodash.assign": "4.2.0", - "lodash.pickby": "4.6.0" + "@babel/code-frame": "7.0.0-beta.44", + "@babel/traverse": "7.0.0-beta.44", + "@babel/types": "7.0.0-beta.44", + "babylon": "7.0.0-beta.44", + "eslint-scope": "3.7.1", + "eslint-visitor-keys": "1.0.0" + }, + "dependencies": { + "babylon": { + "version": "7.0.0-beta.44", + "resolved": "https://registry.npmjs.org/babylon/-/babylon-7.0.0-beta.44.tgz", + "integrity": "sha512-5Hlm13BJVAioCHpImtFqNOF2H3ieTOHd0fmFGMxOJ9jgeFqeAwsv3u5P5cR7CSeFrkgHsT19DgFJkHV0/Mcd8g==", + "dev": true + } } }, "babel-generator": { @@ -551,14 +804,6 @@ "lodash": "4.17.10", "source-map": "0.5.7", "trim-right": "1.0.1" - }, - "dependencies": { - "lodash": { - "version": "4.17.10", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", - "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==", - "dev": true - } } }, "babel-helper-bindify-decorators": { @@ -605,14 +850,6 @@ "babel-runtime": "6.26.0", "babel-types": "6.26.0", "lodash": "4.17.10" - }, - "dependencies": { - "lodash": { - "version": "4.17.10", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", - "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==", - "dev": true - } } }, "babel-helper-explode-assignable-expression": { @@ -690,14 +927,6 @@ "babel-runtime": "6.26.0", "babel-types": "6.26.0", "lodash": "4.17.10" - }, - "dependencies": { - "lodash": { - "version": "4.17.10", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", - "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==", - "dev": true - } } }, "babel-helper-remap-async-to-generator": { @@ -738,24 +967,24 @@ } }, "babel-jest": { - "version": "12.0.2", - "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-12.0.2.tgz", - "integrity": "sha1-jsor9SpoZac4T1szQ8Gb/5hph60=", + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-23.2.0.tgz", + "integrity": "sha1-FKnWo/QSLf6mBp03CFrfJqU6Tbo=", "dev": true, "requires": { - "babel-core": "6.8.0", - "babel-preset-jest": "12.1.0" + "babel-plugin-istanbul": "4.1.6", + "babel-preset-jest": "23.2.0" } }, "babel-loader": { - "version": "6.2.4", - "resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-6.2.4.tgz", - "integrity": "sha1-qnCv+N3CI6WVLoOaQ6bDpMi/oek=", + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-7.1.4.tgz", + "integrity": "sha512-/hbyEvPzBJuGpk9o80R0ZyTej6heEOr59GoEUtn8qFKbnx4cJm9FWES6J/iv644sYgrtVw9JJQkjaLW/bqb5gw==", "dev": true, "requires": { - "loader-utils": "0.2.17", - "mkdirp": "0.5.1", - "object-assign": "4.1.1" + "find-cache-dir": "1.0.0", + "loader-utils": "1.1.0", + "mkdirp": "0.5.1" } }, "babel-messages": { @@ -776,44 +1005,53 @@ "babel-runtime": "6.26.0" } }, + "babel-plugin-istanbul": { + "version": "4.1.6", + "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-4.1.6.tgz", + "integrity": "sha512-PWP9FQ1AhZhS01T/4qLSKoHGY/xvkZdVBGlKM/HuxxS3+sC66HhTNR7+MpbO/so/cz/wY94MeSWJuP1hXIPfwQ==", + "dev": true, + "requires": { + "babel-plugin-syntax-object-rest-spread": "6.13.0", + "find-up": "2.1.0", + "istanbul-lib-instrument": "1.10.1", + "test-exclude": "4.2.1" + } + }, "babel-plugin-jest-hoist": { - "version": "12.1.0", - "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-12.1.0.tgz", - "integrity": "sha1-Tg0KL9cjxPmrAaFgbaoVvza9cIM=", + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-23.2.0.tgz", + "integrity": "sha1-5h+uBaHKiAGq3uV6bWa4zvr0QWc=", "dev": true }, "babel-plugin-lodash": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/babel-plugin-lodash/-/babel-plugin-lodash-3.0.0.tgz", - "integrity": "sha1-n3oZcR8sQHcAOiRjQaq5phOy8nM=", + "version": "3.3.4", + "resolved": "https://registry.npmjs.org/babel-plugin-lodash/-/babel-plugin-lodash-3.3.4.tgz", + "integrity": "sha512-yDZLjK7TCkWl1gpBeBGmuaDIFhZKmkoL+Cu2MUUjv5VxUZx/z7tBGBCBcQs5RI1Bkz5LLmNdjx7paOyQtMovyg==", "dev": true, "requires": { + "@babel/helper-module-imports": "7.0.0-beta.51", + "@babel/types": "7.0.0-beta.51", "glob": "7.1.2", - "lodash": "4.11.2" + "lodash": "4.17.10", + "require-package-name": "2.0.1" }, "dependencies": { - "glob": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", - "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", + "@babel/types": { + "version": "7.0.0-beta.51", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.0.0-beta.51.tgz", + "integrity": "sha1-2AK3tUO1g2x3iqaReXq/APPZfqk=", "dev": true, "requires": { - "fs.realpath": "1.0.0", - "inflight": "1.0.6", - "inherits": "2.0.3", - "minimatch": "3.0.4", - "once": "1.4.0", - "path-is-absolute": "1.0.1" - } - }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "dev": true, - "requires": { - "brace-expansion": "1.1.11" + "esutils": "2.0.2", + "lodash": "4.17.10", + "to-fast-properties": "2.0.0" } + }, + "to-fast-properties": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", + "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", + "dev": true } } }, @@ -986,14 +1224,6 @@ "babel-traverse": "6.26.0", "babel-types": "6.26.0", "lodash": "4.17.10" - }, - "dependencies": { - "lodash": { - "version": "4.17.10", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", - "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==", - "dev": true - } } }, "babel-plugin-transform-es2015-classes": { @@ -1071,6 +1301,17 @@ "babel-runtime": "6.26.0" } }, + "babel-plugin-transform-es2015-modules-amd": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-es2015-modules-amd/-/babel-plugin-transform-es2015-modules-amd-6.24.1.tgz", + "integrity": "sha1-Oz5UAXI5hC1tGcMBHEvS8AoA0VQ=", + "dev": true, + "requires": { + "babel-plugin-transform-es2015-modules-commonjs": "6.26.2", + "babel-runtime": "6.26.0", + "babel-template": "6.26.0" + } + }, "babel-plugin-transform-es2015-modules-commonjs": { "version": "6.26.2", "resolved": "https://registry.npmjs.org/babel-plugin-transform-es2015-modules-commonjs/-/babel-plugin-transform-es2015-modules-commonjs-6.26.2.tgz", @@ -1083,6 +1324,28 @@ "babel-types": "6.26.0" } }, + "babel-plugin-transform-es2015-modules-systemjs": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-es2015-modules-systemjs/-/babel-plugin-transform-es2015-modules-systemjs-6.24.1.tgz", + "integrity": "sha1-/4mhQrkRmpBhlfXxBuzzBdlAfSM=", + "dev": true, + "requires": { + "babel-helper-hoist-variables": "6.24.1", + "babel-runtime": "6.26.0", + "babel-template": "6.26.0" + } + }, + "babel-plugin-transform-es2015-modules-umd": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-es2015-modules-umd/-/babel-plugin-transform-es2015-modules-umd-6.24.1.tgz", + "integrity": "sha1-rJl+YoXNGO1hdq22B9YCNErThGg=", + "dev": true, + "requires": { + "babel-plugin-transform-es2015-modules-amd": "6.24.1", + "babel-runtime": "6.26.0", + "babel-template": "6.26.0" + } + }, "babel-plugin-transform-es2015-object-super": { "version": "6.24.1", "resolved": "https://registry.npmjs.org/babel-plugin-transform-es2015-object-super/-/babel-plugin-transform-es2015-object-super-6.24.1.tgz", @@ -1246,9 +1509,9 @@ } }, "babel-preset-es2015": { - "version": "6.6.0", - "resolved": "https://registry.npmjs.org/babel-preset-es2015/-/babel-preset-es2015-6.6.0.tgz", - "integrity": "sha1-iLM+WP7JTG695Y3GXs5dFODsJWg=", + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-preset-es2015/-/babel-preset-es2015-6.24.1.tgz", + "integrity": "sha1-1EBQ1rwsn+6nAqrzjXJ6AhBTiTk=", "dev": true, "requires": { "babel-plugin-check-es2015-constants": "6.22.0", @@ -1262,7 +1525,10 @@ "babel-plugin-transform-es2015-for-of": "6.23.0", "babel-plugin-transform-es2015-function-name": "6.24.1", "babel-plugin-transform-es2015-literals": "6.22.0", + "babel-plugin-transform-es2015-modules-amd": "6.24.1", "babel-plugin-transform-es2015-modules-commonjs": "6.26.2", + "babel-plugin-transform-es2015-modules-systemjs": "6.24.1", + "babel-plugin-transform-es2015-modules-umd": "6.24.1", "babel-plugin-transform-es2015-object-super": "6.24.1", "babel-plugin-transform-es2015-parameters": "6.24.1", "babel-plugin-transform-es2015-shorthand-properties": "6.24.1", @@ -1275,18 +1541,19 @@ } }, "babel-preset-jest": { - "version": "12.1.0", - "resolved": "https://registry.npmjs.org/babel-preset-jest/-/babel-preset-jest-12.1.0.tgz", - "integrity": "sha1-C0AeboocTqvFXby1m8RjEusba/Y=", + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/babel-preset-jest/-/babel-preset-jest-23.2.0.tgz", + "integrity": "sha1-jsegOhOPABoaj7HoETZSvxpV2kY=", "dev": true, "requires": { - "babel-plugin-jest-hoist": "12.1.0" + "babel-plugin-jest-hoist": "23.2.0", + "babel-plugin-syntax-object-rest-spread": "6.13.0" } }, "babel-preset-stage-0": { - "version": "6.5.0", - "resolved": "https://registry.npmjs.org/babel-preset-stage-0/-/babel-preset-stage-0-6.5.0.tgz", - "integrity": "sha1-i4R5sgd0grjz3I+PXwyceXiM3iI=", + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-preset-stage-0/-/babel-preset-stage-0-6.24.1.tgz", + "integrity": "sha1-VkLRUEL5E4TX5a+LyIsduVsDnmo=", "dev": true, "requires": { "babel-plugin-transform-do-expressions": "6.22.0", @@ -1343,56 +1610,6 @@ "lodash": "4.17.10", "mkdirp": "0.5.1", "source-map-support": "0.4.18" - }, - "dependencies": { - "babel-core": { - "version": "6.26.3", - "resolved": "https://registry.npmjs.org/babel-core/-/babel-core-6.26.3.tgz", - "integrity": "sha512-6jyFLuDmeidKmUEb3NM+/yawG0M2bDZ9Z1qbZP59cyHLz8kYGKYwpJP0UwUKKUiTRNvxfLesJnTedqczP7cTDA==", - "dev": true, - "requires": { - "babel-code-frame": "6.26.0", - "babel-generator": "6.26.1", - "babel-helpers": "6.24.1", - "babel-messages": "6.23.0", - "babel-register": "6.26.0", - "babel-runtime": "6.26.0", - "babel-template": "6.26.0", - "babel-traverse": "6.26.0", - "babel-types": "6.26.0", - "babylon": "6.18.0", - "convert-source-map": "1.5.1", - "debug": "2.6.9", - "json5": "0.5.1", - "lodash": "4.17.10", - "minimatch": "3.0.4", - "path-is-absolute": "1.0.1", - "private": "0.1.8", - "slash": "1.0.0", - "source-map": "0.5.7" - } - }, - "json5": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/json5/-/json5-0.5.1.tgz", - "integrity": "sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE=", - "dev": true - }, - "lodash": { - "version": "4.17.10", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", - "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==", - "dev": true - }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "dev": true, - "requires": { - "brace-expansion": "1.1.11" - } - } } }, "babel-runtime": { @@ -1416,14 +1633,6 @@ "babel-types": "6.26.0", "babylon": "6.18.0", "lodash": "4.17.10" - }, - "dependencies": { - "lodash": { - "version": "4.17.10", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", - "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==", - "dev": true - } } }, "babel-traverse": { @@ -1443,11 +1652,14 @@ "lodash": "4.17.10" }, "dependencies": { - "lodash": { - "version": "4.17.10", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", - "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==", - "dev": true + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } } } }, @@ -1461,14 +1673,6 @@ "esutils": "2.0.2", "lodash": "4.17.10", "to-fast-properties": "1.0.3" - }, - "dependencies": { - "lodash": { - "version": "4.17.10", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", - "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==", - "dev": true - } } }, "babylon": { @@ -1480,8 +1684,7 @@ "balanced-match": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", - "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", - "dev": true + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" }, "base": { "version": "0.11.2", @@ -1584,27 +1787,6 @@ "integrity": "sha512-+hN/Zh2D08Mx65pZ/4g5bsmNiZUuChDiQfTUQ7qJr4/kuopCr88xZsAXv6mBoZEsUI4OuGHlX59qE94K2mMW8Q==", "dev": true }, - "bin-version": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/bin-version/-/bin-version-1.0.4.tgz", - "integrity": "sha1-nrSY7m/Xb3q5p8FgQ2+JV5Q1144=", - "dev": true, - "requires": { - "find-versions": "1.2.1" - } - }, - "bin-version-check": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/bin-version-check/-/bin-version-check-2.1.0.tgz", - "integrity": "sha1-5OXfKQuQaffRETJAMe/BP90RpbA=", - "dev": true, - "requires": { - "bin-version": "1.0.4", - "minimist": "1.2.0", - "semver": "4.3.6", - "semver-truncate": "1.1.2" - } - }, "binary-extensions": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.11.0.tgz", @@ -1658,9 +1840,9 @@ } }, "bluebird": { - "version": "3.3.5", - "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.3.5.tgz", - "integrity": "sha1-XudH8ce9lnZYtoOTZDCu51OVWjQ=" + "version": "3.5.1", + "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.1.tgz", + "integrity": "sha512-MKiLiV+I1AA596t9w1sQJ8jkiSr5+ZKi0WKrYGUn6d1Fx+Ij4tIj+m2WMQSGczs5jZVxV339chE8iwk6F64wjA==" }, "bn.js": { "version": "4.11.8", @@ -1686,6 +1868,21 @@ "type-is": "1.6.16" }, "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, + "iconv-lite": { + "version": "0.4.19", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.19.tgz", + "integrity": "sha512-oTZqweIP51xaGPI4uPa56/Pri/480R+mo7SeU+YETByQNhDG55ycFyNLIgta9vXhILrxXDmF7ZGhqZIcuN0gJQ==", + "dev": true + }, "qs": { "version": "6.5.1", "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.1.tgz", @@ -1698,7 +1895,6 @@ "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, "requires": { "balanced-match": "1.0.0", "concat-map": "0.0.1" @@ -1721,6 +1917,29 @@ "integrity": "sha1-EsJe/kCkXjwyPrhnWgoM5XsiNx8=", "dev": true }, + "browser-process-hrtime": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/browser-process-hrtime/-/browser-process-hrtime-0.1.2.tgz", + "integrity": "sha1-Ql1opY00R/AqBKqJQYf86K+Le44=", + "dev": true + }, + "browser-resolve": { + "version": "1.11.3", + "resolved": "https://registry.npmjs.org/browser-resolve/-/browser-resolve-1.11.3.tgz", + "integrity": "sha512-exDi1BYWB/6raKHmDTCicQfTkqwN5fioMFV4j8BsfMU4R2DK/QfZfK7kOVkmWCNANf0snkBzqGqAJBao9gZMdQ==", + "dev": true, + "requires": { + "resolve": "1.1.7" + }, + "dependencies": { + "resolve": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.1.7.tgz", + "integrity": "sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs=", + "dev": true + } + } + }, "browserify-aes": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/browserify-aes/-/browserify-aes-1.2.0.tgz", @@ -1783,18 +2002,18 @@ } }, "browserify-zlib": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/browserify-zlib/-/browserify-zlib-0.1.4.tgz", - "integrity": "sha1-uzX4pRn2AOD6a4SFJByXnQFB+y0=", + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/browserify-zlib/-/browserify-zlib-0.2.0.tgz", + "integrity": "sha512-Z942RysHXmJrhqk88FmKBVq/v5tqmSkDz7p54G/MGyjMnCFFnC79XWNbg+Vta8W6Wb2qtSZTSxIGkJrRpCFEiA==", "dev": true, "requires": { - "pako": "0.2.9" + "pako": "1.0.6" } }, "bser": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/bser/-/bser-1.0.2.tgz", - "integrity": "sha1-OBEWlwsqbe6lZG3RXdcnhES1YWk=", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/bser/-/bser-2.0.0.tgz", + "integrity": "sha1-mseNPtXZFYBP2HrLFYvHlxR6Fxk=", "dev": true, "requires": { "node-int64": "0.4.0" @@ -1841,6 +2060,12 @@ "integrity": "sha1-Jw8HbFpywC9bZaR9+Uxf46J4iS8=", "dev": true }, + "builtin-status-codes": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/builtin-status-codes/-/builtin-status-codes-3.0.0.tgz", + "integrity": "sha1-hZgoeOIbmOHGZCXgPQF0eI9Wnug=", + "dev": true + }, "bytes": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.0.0.tgz", @@ -1885,6 +2110,15 @@ "mkdirp": "0.5.1" } }, + "callback-stream": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/callback-stream/-/callback-stream-1.1.0.tgz", + "integrity": "sha1-RwGlEmbwbgbqpx/BcjOCLYdfSQg=", + "requires": { + "inherits": "2.0.3", + "readable-stream": "1.1.14" + } + }, "caller-path": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/caller-path/-/caller-path-0.1.0.tgz", @@ -1901,19 +2135,18 @@ "dev": true }, "camelcase": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-2.1.1.tgz", - "integrity": "sha1-fB0W1nmhu+WcoCys7PsBHiAfWh8=", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-1.2.1.tgz", + "integrity": "sha1-m7UwTS4LVmmLLHWLCKPqqdqlijk=", "dev": true }, - "camelcase-keys": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-2.1.0.tgz", - "integrity": "sha1-MIvur/3ygRkFHvodkyITyRuPkuc=", + "capture-exit": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/capture-exit/-/capture-exit-1.2.0.tgz", + "integrity": "sha1-HF/MSJ/QqwDU8ax64QcuMXP7q28=", "dev": true, "requires": { - "camelcase": "2.1.1", - "map-obj": "1.0.1" + "rsvp": "3.6.2" } }, "caseless": { @@ -1942,9 +2175,9 @@ } }, "chalk": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.1.tgz", - "integrity": "sha1-UJr7ZwZudJn36zU1x3RFdyri0Bk=", + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { "ansi-styles": "2.2.1", @@ -1954,6 +2187,12 @@ "supports-color": "2.0.0" } }, + "chardet": { + "version": "0.4.2", + "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.4.2.tgz", + "integrity": "sha1-tUc7M9yXxCTl2Y3IfVXU2KKci/I=", + "dev": true + }, "chokidar": { "version": "1.7.0", "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-1.7.0.tgz", @@ -1969,8 +2208,40 @@ "is-glob": "2.0.1", "path-is-absolute": "1.0.1", "readdirp": "2.1.0" + }, + "dependencies": { + "glob-parent": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-2.0.0.tgz", + "integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=", + "dev": true, + "requires": { + "is-glob": "2.0.1" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", + "dev": true + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "dev": true, + "requires": { + "is-extglob": "1.0.0" + } + } } }, + "ci-info": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-1.1.3.tgz", + "integrity": "sha512-SK/846h/Rcy8q9Z9CAwGBLfCJ6EkjJWdpelWDufQpqVDYq2Wnnv8zlSO6AMQap02jvhVruKKpEtQOufo3pFhLg==", + "dev": true + }, "cipher-base": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/cipher-base/-/cipher-base-1.0.4.tgz", @@ -2029,21 +2300,12 @@ } }, "cli-cursor": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-1.0.2.tgz", - "integrity": "sha1-ZNo/fValRBLll5S9Ytw1KV6PKYc=", - "dev": true, - "requires": { - "restore-cursor": "1.0.1" - } - }, - "cli-table": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/cli-table/-/cli-table-0.0.2.tgz", - "integrity": "sha1-mChn4WQ1Mlxmwgih5xuVM26jCTs=", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-2.1.0.tgz", + "integrity": "sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU=", "dev": true, "requires": { - "colors": "0.3.0" + "restore-cursor": "2.0.0" } }, "cli-width": { @@ -2072,9 +2334,9 @@ } }, "clone": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/clone/-/clone-0.2.0.tgz", - "integrity": "sha1-xhJqkK1Pctv1rNskPMN3JP6T/B8=", + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", + "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=", "dev": true }, "clone-stats": { @@ -2083,6 +2345,12 @@ "integrity": "sha1-uI+UqCzzi4eR1YBG6kAprYjKmdE=", "dev": true }, + "clorox": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/clorox/-/clorox-1.0.3.tgz", + "integrity": "sha512-w3gKAUKMJYmmaJyc+p+iDrDtLvsFasrx/y6/zWo2U1TZfsz3y4Vl4T9PHCZrOwk1eMTOSRI6xHdpDR4PhTdy8Q==", + "dev": true + }, "co": { "version": "4.6.0", "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", @@ -2145,18 +2413,27 @@ "object-visit": "1.0.1" } }, + "color-convert": { + "version": "1.9.2", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.2.tgz", + "integrity": "sha512-3NUJZdhMhcdPn8vJ9v2UQJoH0qqoGUkYTgFEPZaPjEtwmmKUfNV46zZmgB2M5M4DCEQHMaCfWHCxiBflLm04Tg==", + "dev": true, + "requires": { + "color-name": "1.1.1" + } + }, + "color-name": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.1.tgz", + "integrity": "sha1-SxQVMEz1ACjqgWQ2Q72C6gWANok=", + "dev": true + }, "color-support": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz", "integrity": "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==", "dev": true }, - "colors": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/colors/-/colors-0.3.0.tgz", - "integrity": "sha1-wkfWTTTbDKTcjkPz7NbamNCvlOc=", - "dev": true - }, "column-layout": { "version": "2.1.4", "resolved": "https://registry.npmjs.org/column-layout/-/column-layout-2.1.4.tgz", @@ -2316,6 +2593,18 @@ "integrity": "sha1-MOB/P49vf5s97oVPILLTnu4Ibeg=", "dev": true }, + "commondir": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", + "integrity": "sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs=", + "dev": true + }, + "compare-versions": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/compare-versions/-/compare-versions-3.3.0.tgz", + "integrity": "sha512-MAAAIOdi2s4Gl6rZ76PNcUa9IOYB+5ICdT41o5uMRf09aEu/F9RK+qhe8RjXNPwcTjGV7KU7h2P/fljThFVqyQ==", + "dev": true + }, "component-emitter": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz", @@ -2354,6 +2643,15 @@ "vary": "1.1.2" }, "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, "safe-buffer": { "version": "5.1.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.1.tgz", @@ -2365,8 +2663,7 @@ "concat-map": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "dev": true + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" }, "concat-stream": { "version": "1.6.2", @@ -2440,6 +2737,12 @@ "integrity": "sha1-wguW2MYXdIqvHBYCF2DNJ/y4y3U=", "dev": true }, + "contains-path": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/contains-path/-/contains-path-0.1.0.tgz", + "integrity": "sha1-/ozxhP9mcLa67wGp1IYaXL7EEgo=", + "dev": true + }, "content-disposition": { "version": "0.5.2", "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.2.tgz", @@ -2452,12 +2755,6 @@ "integrity": "sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA==", "dev": true }, - "content-type-parser": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/content-type-parser/-/content-type-parser-1.0.2.tgz", - "integrity": "sha512-lM4l4CnMEwOLHAHr/P6MEZwZFPJFtAAKgL6pogbXmVZggIqXhdB6RbBtPOTsw2FcXwYhehRGERJmRrjOiIB8pQ==", - "dev": true - }, "convert-source-map": { "version": "1.5.1", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.5.1.tgz", @@ -2493,32 +2790,6 @@ "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" }, - "cover": { - "version": "0.2.9", - "resolved": "https://registry.npmjs.org/cover/-/cover-0.2.9.tgz", - "integrity": "sha1-JiAp37MXFNSAQ/7ZHt5lhZOVXdQ=", - "dev": true, - "requires": { - "cli-table": "0.0.2", - "underscore": "1.2.4", - "underscore.string": "2.0.0", - "which": "1.0.9" - }, - "dependencies": { - "underscore": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.2.4.tgz", - "integrity": "sha1-6NpiQaoG9k3yRzuyWQuMF8hMPH4=", - "dev": true - }, - "which": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/which/-/which-1.0.9.tgz", - "integrity": "sha1-RgwdoPgQED0DIam2M6+eV15kSG8=", - "dev": true - } - } - }, "create-ecdh": { "version": "4.0.3", "resolved": "https://registry.npmjs.org/create-ecdh/-/create-ecdh-4.0.3.tgz", @@ -2556,6 +2827,19 @@ "sha.js": "2.4.11" } }, + "cross-spawn": { + "version": "6.0.5", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", + "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", + "dev": true, + "requires": { + "nice-try": "1.0.4", + "path-key": "2.0.1", + "semver": "5.5.0", + "shebang-command": "1.2.0", + "which": "1.3.1" + } + }, "crypto-browserify": { "version": "3.12.0", "resolved": "https://registry.npmjs.org/crypto-browserify/-/crypto-browserify-3.12.0.tgz", @@ -2575,6 +2859,29 @@ "randomfill": "1.0.4" } }, + "css": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/css/-/css-2.2.3.tgz", + "integrity": "sha512-0W171WccAjQGGTKLhw4m2nnl0zPHUlTO/I8td4XzJgIB8Hg3ZZx71qT4G4eX8OVsSiaAKiUMy73E3nsbPlg2DQ==", + "dev": true, + "requires": { + "inherits": "2.0.3", + "source-map": "0.1.43", + "source-map-resolve": "0.5.2", + "urix": "0.1.0" + }, + "dependencies": { + "source-map": { + "version": "0.1.43", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.1.43.tgz", + "integrity": "sha1-wkvBRspRfBRx9drL4lcbK3+eM0Y=", + "dev": true, + "requires": { + "amdefine": "1.0.1" + } + } + } + }, "cssom": { "version": "0.3.4", "resolved": "https://registry.npmjs.org/cssom/-/cssom-0.3.4.tgz", @@ -2582,23 +2889,14 @@ "dev": true }, "cssstyle": { - "version": "0.2.37", - "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-0.2.37.tgz", - "integrity": "sha1-VBCXI0yyUTyDzu06zdwn/yeYfVQ=", + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-0.3.1.tgz", + "integrity": "sha512-tNvaxM5blOnxanyxI6panOsnfiyLRj3HV4qjqqS45WPNS1usdYWRUQjqTEEELK73lpeP/1KoIGYUwrBn/VcECA==", "dev": true, "requires": { "cssom": "0.3.4" } }, - "currently-unhandled": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/currently-unhandled/-/currently-unhandled-0.4.1.tgz", - "integrity": "sha1-mI3zP+qxke95mmE2nddsF635V+o=", - "dev": true, - "requires": { - "array-find-index": "1.0.2" - } - }, "d": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/d/-/d-1.0.0.tgz", @@ -2608,6 +2906,12 @@ "es5-ext": "0.10.45" } }, + "damerau-levenshtein": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/damerau-levenshtein/-/damerau-levenshtein-1.0.4.tgz", + "integrity": "sha1-AxkcQyy27qFou3fzpV/9zLiXhRQ=", + "dev": true + }, "dashdash": { "version": "1.14.1", "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", @@ -2617,21 +2921,28 @@ "assert-plus": "1.0.0" } }, - "date-now": { - "version": "0.1.4", + "data-urls": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-1.0.0.tgz", + "integrity": "sha512-ai40PPQR0Fn1lD2PPie79CibnlMN2AYiDhwFX/rZHVsxbs5kNJSjegqXIprhouGXlRdEnfybva7kqRGnB6mypA==", + "dev": true, + "requires": { + "abab": "1.0.4", + "whatwg-mimetype": "2.1.0", + "whatwg-url": "6.5.0" + } + }, + "date-now": { + "version": "0.1.4", "resolved": "https://registry.npmjs.org/date-now/-/date-now-0.1.4.tgz", "integrity": "sha1-6vQ5/U1ISK105cx9vvIAZyueNFs=", "dev": true }, "dateformat": { - "version": "1.0.12", - "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-1.0.12.tgz", - "integrity": "sha1-nxJLZ1lMk3/3BpMuSmQsyo27/uk=", - "dev": true, - "requires": { - "get-stdin": "4.0.1", - "meow": "3.7.0" - } + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-2.2.0.tgz", + "integrity": "sha1-QGXiATz5+5Ft39gu+1Bq1MZ2kGI=", + "dev": true }, "ddata": { "version": "0.1.28", @@ -2650,13 +2961,24 @@ } }, "debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz", + "integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==", "requires": { "ms": "2.0.0" } }, + "debug-fabulous": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/debug-fabulous/-/debug-fabulous-1.1.0.tgz", + "integrity": "sha512-GZqvGIgKNlUnHUPQhepnUZFIMoi3dgZKQBzKDeL2g7oJF9SNAji/AAu36dusFUas0O+pae74lNeoIPHqXWDkLg==", + "dev": true, + "requires": { + "debug": "3.1.0", + "memoizee": "0.4.12", + "object-assign": "4.1.1" + } + }, "decamelize": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", @@ -2681,6 +3003,23 @@ "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=", "dev": true }, + "default-require-extensions": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-2.0.0.tgz", + "integrity": "sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc=", + "dev": true, + "requires": { + "strip-bom": "3.0.0" + }, + "dependencies": { + "strip-bom": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", + "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=", + "dev": true + } + } + }, "defaults": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/defaults/-/defaults-1.0.3.tgz", @@ -2688,14 +3027,6 @@ "dev": true, "requires": { "clone": "1.0.4" - }, - "dependencies": { - "clone": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=", - "dev": true - } } }, "defer-promise": { @@ -2704,6 +3035,16 @@ "integrity": "sha1-HKb/7dvO8XFd16riXHYW+a4iky8=", "dev": true }, + "define-properties": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.2.tgz", + "integrity": "sha1-g6c/L+pWmJj7c3GTyPhzyvbUXJQ=", + "dev": true, + "requires": { + "foreach": "2.0.5", + "object-keys": "1.0.12" + } + }, "define-property": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/define-property/-/define-property-2.0.2.tgz", @@ -2758,34 +3099,24 @@ } }, "del": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/del/-/del-2.0.2.tgz", - "integrity": "sha1-bNxo2wAoK5LY6CoO2f/x0zMZNCQ=", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/del/-/del-3.0.0.tgz", + "integrity": "sha1-U+z2mf/LyzljdpGrE7rxYIGXZuU=", "dev": true, "requires": { - "globby": "3.0.1", + "globby": "6.1.0", "is-path-cwd": "1.0.0", "is-path-in-cwd": "1.0.1", - "object-assign": "4.1.1", - "pify": "2.3.0", - "pinkie-promise": "1.0.0", + "p-map": "1.2.0", + "pify": "3.0.0", "rimraf": "2.6.2" }, "dependencies": { - "pinkie": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/pinkie/-/pinkie-1.0.0.tgz", - "integrity": "sha1-Wkfyi6EBXQIBvae/DzWOR77Ix+Q=", + "pify": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", + "integrity": "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=", "dev": true - }, - "pinkie-promise": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/pinkie-promise/-/pinkie-promise-1.0.0.tgz", - "integrity": "sha1-0dpn9UglY7t89X8oauKCLs+/NnA=", - "dev": true, - "requires": { - "pinkie": "1.0.0" - } } } }, @@ -2838,10 +3169,16 @@ "repeating": "2.0.1" } }, + "detect-newline": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/detect-newline/-/detect-newline-2.1.0.tgz", + "integrity": "sha1-9B8cEL5LAOh7XxPaaAdZ8sW/0+I=", + "dev": true + }, "diff": { - "version": "2.2.3", - "resolved": "https://registry.npmjs.org/diff/-/diff-2.2.3.tgz", - "integrity": "sha1-YOr9DSjukG5Oj/ClLBIpUhAzv5k=", + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/diff/-/diff-3.5.0.tgz", + "integrity": "sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA==", "dev": true }, "diffie-hellman": { @@ -2880,21 +3217,12 @@ } }, "doctrine": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-1.5.0.tgz", - "integrity": "sha1-N53Ocw9hZvds76TmcHoVmwLFpvo=", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", + "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", "dev": true, "requires": { - "esutils": "2.0.2", - "isarray": "1.0.0" - }, - "dependencies": { - "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", - "dev": true - } + "esutils": "2.0.2" } }, "domain-browser": { @@ -2903,6 +3231,15 @@ "integrity": "sha512-jnjyiM6eRyZl2H+W8Q/zLMA481hzi0eszAaBUzIVnmYVDBbnLxVNnfu1HgEBvCbL+71FrxMl3E6lpKH7Ge3OXA==", "dev": true }, + "domexception": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/domexception/-/domexception-1.0.1.tgz", + "integrity": "sha512-raigMkn7CJNNo6Ihro1fzG7wr3fHuYVytzquZKX5n0yizGsTcYgzdIUwj1X9pK0VvjeihV+XiclP+DjwbsSKug==", + "dev": true, + "requires": { + "webidl-conversions": "4.0.2" + } + }, "duplexer2": { "version": "0.0.2", "resolved": "https://registry.npmjs.org/duplexer2/-/duplexer2-0.0.2.tgz", @@ -2983,6 +3320,12 @@ "minimalistic-crypto-utils": "1.0.1" } }, + "emoji-regex": { + "version": "6.5.1", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-6.5.1.tgz", + "integrity": "sha512-PAHp6TxrCy7MGMFidro8uikr+zlJJKJ/Q6mm2ExZ7HwkyR9lSVFfE3kt36qcwa24BQL7y0G9axycGjK1A/0uNQ==", + "dev": true + }, "emojis-list": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/emojis-list/-/emojis-list-2.1.0.tgz", @@ -3040,6 +3383,30 @@ "is-arrayish": "0.2.1" } }, + "es-abstract": { + "version": "1.12.0", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.12.0.tgz", + "integrity": "sha512-C8Fx/0jFmV5IPoMOFPA9P9G5NtqW+4cOPit3MIuvR2t7Ag2K15EJTpxnHAYTzL+aYQJIESYeXZmDBfOBE1HcpA==", + "dev": true, + "requires": { + "es-to-primitive": "1.1.1", + "function-bind": "1.1.1", + "has": "1.0.3", + "is-callable": "1.1.4", + "is-regex": "1.0.4" + } + }, + "es-to-primitive": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.1.1.tgz", + "integrity": "sha1-RTVSSKiJeQNLZ5Lhm7gfK3l13Q0=", + "dev": true, + "requires": { + "is-callable": "1.1.4", + "is-date-object": "1.0.1", + "is-symbol": "1.0.1" + } + }, "es5-ext": { "version": "0.10.45", "resolved": "https://registry.npmjs.org/es5-ext/-/es5-ext-0.10.45.tgz", @@ -3062,33 +3429,6 @@ "es6-symbol": "3.1.1" } }, - "es6-map": { - "version": "0.1.5", - "resolved": "https://registry.npmjs.org/es6-map/-/es6-map-0.1.5.tgz", - "integrity": "sha1-kTbgUD3MBqMBaQ8LsU/042TpSfA=", - "dev": true, - "requires": { - "d": "1.0.0", - "es5-ext": "0.10.45", - "es6-iterator": "2.0.3", - "es6-set": "0.1.5", - "es6-symbol": "3.1.1", - "event-emitter": "0.3.5" - } - }, - "es6-set": { - "version": "0.1.5", - "resolved": "https://registry.npmjs.org/es6-set/-/es6-set-0.1.5.tgz", - "integrity": "sha1-0rPsXU2ADO2BjbU40ol02wpzzLE=", - "dev": true, - "requires": { - "d": "1.0.0", - "es5-ext": "0.10.45", - "es6-iterator": "2.0.3", - "es6-symbol": "3.1.1", - "event-emitter": "0.3.5" - } - }, "es6-symbol": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/es6-symbol/-/es6-symbol-3.1.1.tgz", @@ -3124,200 +3464,277 @@ "dev": true }, "escodegen": { - "version": "1.8.1", - "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.8.1.tgz", - "integrity": "sha1-WltTr0aTEQvrsIZ6o0MN07cKEBg=", + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.10.0.tgz", + "integrity": "sha512-fjUOf8johsv23WuIKdNQU4P9t9jhQ4Qzx6pC2uW890OloK3Zs1ZAoCNpg/2larNF501jLl3UNy0kIRcF6VI22g==", "dev": true, "requires": { - "esprima": "2.7.3", - "estraverse": "1.9.3", + "esprima": "3.1.3", + "estraverse": "4.2.0", "esutils": "2.0.2", "optionator": "0.8.2", - "source-map": "0.2.0" + "source-map": "0.6.1" }, "dependencies": { "esprima": { - "version": "2.7.3", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-2.7.3.tgz", - "integrity": "sha1-luO3DVd59q1JzQMmc9HDEnZ7pYE=", - "dev": true - }, - "estraverse": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-1.9.3.tgz", - "integrity": "sha1-r2fy3JIlgkFZUJJgkaQAXSnJu0Q=", + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-3.1.3.tgz", + "integrity": "sha1-/cpRzuYTOJXjyI1TXOSdv/YqRjM=", "dev": true }, "source-map": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.2.0.tgz", - "integrity": "sha1-2rc/vPwrqBm03gO9b26qSBZLP50=", + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true, - "optional": true, - "requires": { - "amdefine": "1.0.1" - } + "optional": true } } }, - "escope": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/escope/-/escope-3.6.0.tgz", - "integrity": "sha1-4Bl16BJ4GhY6ba392AOY3GTIicM=", - "dev": true, - "requires": { - "es6-map": "0.1.5", - "es6-weak-map": "2.0.2", - "esrecurse": "4.2.1", - "estraverse": "4.2.0" - } - }, "eslint": { - "version": "2.9.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-2.9.0.tgz", - "integrity": "sha1-Wz/bdJe7BC4nR+PR/pX0BNyjmmA=", + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-5.0.1.tgz", + "integrity": "sha512-D5nG2rErquLUstgUaxJlWB5+gu+U/3VDY0fk/Iuq8y9CUFy/7Y6oF4N2cR1tV8knzQvciIbfqfohd359xTLIKQ==", "dev": true, "requires": { - "chalk": "1.1.3", - "concat-stream": "1.6.2", - "debug": "2.6.9", - "doctrine": "1.5.0", - "es6-map": "0.1.5", - "escope": "3.6.0", - "espree": "3.1.4", - "estraverse": "4.2.0", + "ajv": "6.5.2", + "babel-code-frame": "6.26.0", + "chalk": "2.4.1", + "cross-spawn": "6.0.5", + "debug": "3.1.0", + "doctrine": "2.1.0", + "eslint-scope": "4.0.0", + "eslint-visitor-keys": "1.0.0", + "espree": "4.0.0", + "esquery": "1.0.1", "esutils": "2.0.2", - "file-entry-cache": "1.3.1", + "file-entry-cache": "2.0.0", + "functional-red-black-tree": "1.0.1", "glob": "7.1.2", - "globals": "9.18.0", + "globals": "11.7.0", "ignore": "3.3.10", "imurmurhash": "0.1.4", - "inquirer": "0.12.0", - "is-my-json-valid": "2.17.2", + "inquirer": "5.2.0", "is-resolvable": "1.1.0", "js-yaml": "3.12.0", - "json-stable-stringify": "1.0.1", - "lodash": "4.11.2", + "json-stable-stringify-without-jsonify": "1.0.1", + "levn": "0.3.0", + "lodash": "4.17.10", + "minimatch": "3.0.4", "mkdirp": "0.5.1", + "natural-compare": "1.4.0", "optionator": "0.8.2", - "path-is-absolute": "1.0.1", "path-is-inside": "1.0.2", - "pluralize": "1.2.1", - "progress": "1.1.8", + "pluralize": "7.0.0", + "progress": "2.0.0", + "regexpp": "1.1.0", "require-uncached": "1.0.3", - "shelljs": "0.6.1", - "strip-json-comments": "1.0.4", - "table": "3.8.3", - "text-table": "0.2.0", - "user-home": "2.0.0" + "semver": "5.5.0", + "string.prototype.matchall": "2.0.0", + "strip-ansi": "4.0.0", + "strip-json-comments": "2.0.1", + "table": "4.0.3", + "text-table": "0.2.0" }, "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, "chalk": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", - "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", "dev": true, "requires": { - "ansi-styles": "2.2.1", + "ansi-styles": "3.2.1", "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" + "supports-color": "5.4.0" } }, - "glob": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", - "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", + "eslint-scope": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-4.0.0.tgz", + "integrity": "sha512-1G6UTDi7Jc1ELFwnR58HV4fK9OQK4S6N985f166xqXxpjU6plxFISJa2Ba9KCQuFa8RCnj/lSFJbHo7UFDBnUA==", "dev": true, "requires": { - "fs.realpath": "1.0.0", - "inflight": "1.0.6", - "inherits": "2.0.3", - "minimatch": "3.0.4", - "once": "1.4.0", - "path-is-absolute": "1.0.1" + "esrecurse": "4.2.1", + "estraverse": "4.2.0" } }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "globals": { + "version": "11.7.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-11.7.0.tgz", + "integrity": "sha512-K8BNSPySfeShBQXsahYB/AbbWruVOTyVpgoIDnl8odPpeSfP2J5QO2oLFFdl2j7GfDCtZj2bMKar2T49itTPCg==", + "dev": true + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", "dev": true, "requires": { - "brace-expansion": "1.1.11" + "ansi-regex": "3.0.0" } }, - "user-home": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/user-home/-/user-home-2.0.0.tgz", - "integrity": "sha1-nHC/2Babwdy/SGBODwS4tJzenp8=", + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", "dev": true, "requires": { - "os-homedir": "1.0.2" + "has-flag": "3.0.0" } } } }, "eslint-config-airbnb": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/eslint-config-airbnb/-/eslint-config-airbnb-8.0.0.tgz", - "integrity": "sha1-LlOYJiYuY2dSWWDVoNU9MrJjr5A=", + "version": "17.0.0", + "resolved": "https://registry.npmjs.org/eslint-config-airbnb/-/eslint-config-airbnb-17.0.0.tgz", + "integrity": "sha512-FLaAYKpu9gLw/ca0qXQRT150Nbfvwc8eaCITaJCU25H9x+5CHsBPW1pFB6EF3r3T2PZTnXrHKisLh+GT43ZY5Q==", "dev": true, "requires": { - "eslint-config-airbnb-base": "1.0.4" + "eslint-config-airbnb-base": "13.0.0", + "object.assign": "4.1.0", + "object.entries": "1.0.4" } }, "eslint-config-airbnb-base": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/eslint-config-airbnb-base/-/eslint-config-airbnb-base-1.0.4.tgz", - "integrity": "sha1-vFQgiQvGRCzxUnfJpKKB/BMX+KY=", - "dev": true + "version": "13.0.0", + "resolved": "https://registry.npmjs.org/eslint-config-airbnb-base/-/eslint-config-airbnb-base-13.0.0.tgz", + "integrity": "sha512-hUFXRlE6AY84z0qYh4wKdtSF4EqDnyT8sxrvTpcXCV4ENSLF8li5yNA1yDM26iinH8Ierbpc4lv8Rp62uX6VSQ==", + "dev": true, + "requires": { + "eslint-restricted-globals": "0.1.1", + "object.assign": "4.1.0", + "object.entries": "1.0.4" + } }, "eslint-import-resolver-node": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.2.3.tgz", - "integrity": "sha1-Wt2BBujJKNssuiMrzZ76hG49oWw=", + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.2.tgz", + "integrity": "sha512-sfmTqJfPSizWu4aymbPr4Iidp5yKm8yDkHp+Ir3YiTHiiDfxh69mOUsmiqW6RZ9zRXFaF64GtYmN7e+8GHBv6Q==", "dev": true, "requires": { "debug": "2.6.9", - "object-assign": "4.1.1", "resolve": "1.8.1" + }, + "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + } } }, "eslint-loader": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/eslint-loader/-/eslint-loader-1.2.1.tgz", - "integrity": "sha1-Z7FmNJdYXqJnj83VFxZT73sRDSA=", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/eslint-loader/-/eslint-loader-2.0.0.tgz", + "integrity": "sha512-VxxGDI4bXzLk0+/jMt/0EkGMRKS9ox6Czx+yapMb9WJmcS/ZHhlhqcVUNgUjFBNp02j/2pZLdGOrG7EXyjoz/g==", "dev": true, "requires": { - "loader-utils": "0.2.17", - "object-assign": "4.1.1" + "loader-fs-cache": "1.0.1", + "loader-utils": "1.1.0", + "object-assign": "4.1.1", + "object-hash": "1.3.0", + "rimraf": "2.6.2" + } + }, + "eslint-module-utils": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.2.0.tgz", + "integrity": "sha1-snA2LNiLGkitMIl2zn+lTphBF0Y=", + "dev": true, + "requires": { + "debug": "2.6.9", + "pkg-dir": "1.0.0" + }, + "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, + "find-up": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz", + "integrity": "sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8=", + "dev": true, + "requires": { + "path-exists": "2.1.0", + "pinkie-promise": "2.0.1" + } + }, + "path-exists": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz", + "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=", + "dev": true, + "requires": { + "pinkie-promise": "2.0.1" + } + }, + "pkg-dir": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-1.0.0.tgz", + "integrity": "sha1-ektQio1bstYp1EcFb/TpyTFM89Q=", + "dev": true, + "requires": { + "find-up": "1.1.2" + } + } } }, "eslint-plugin-import": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-1.6.1.tgz", - "integrity": "sha1-hWzXjQKilP9+Re1vTMkXrjc28ps=", + "version": "2.13.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.13.0.tgz", + "integrity": "sha512-t6hGKQDMIt9N8R7vLepsYXgDfeuhp6ZJSgtrLEDxonpSubyxUZHjhm6LsAaZX8q6GYVxkbT3kTsV9G5mBCFR6A==", "dev": true, "requires": { - "builtin-modules": "1.1.1", - "doctrine": "1.2.3", - "es6-map": "0.1.5", - "es6-set": "0.1.5", - "es6-symbol": "3.1.1", - "eslint-import-resolver-node": "0.2.3", - "lodash.cond": "4.5.2", - "lodash.endswith": "4.2.1", - "lodash.find": "4.6.0", - "object-assign": "4.1.1", - "pkg-up": "1.0.0" + "contains-path": "0.1.0", + "debug": "2.6.9", + "doctrine": "1.5.0", + "eslint-import-resolver-node": "0.3.2", + "eslint-module-utils": "2.2.0", + "has": "1.0.3", + "lodash": "4.17.10", + "minimatch": "3.0.4", + "read-pkg-up": "2.0.0", + "resolve": "1.8.1" }, "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, "doctrine": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-1.2.3.tgz", - "integrity": "sha1-auxrvWLPid1JjK5wwO2fSdqHOmo=", + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-1.5.0.tgz", + "integrity": "sha1-N53Ocw9hZvds76TmcHoVmwLFpvo=", "dev": true, "requires": { "esutils": "2.0.2", @@ -3329,32 +3746,115 @@ "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", "dev": true - } - } - }, - "eslint-plugin-jsx-a11y": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-1.0.4.tgz", - "integrity": "sha1-Mnmf1ZCI5DQMPMlU3oYBMqjQTTw=", - "dev": true, - "requires": { - "object-assign": "4.1.1" - } + }, + "load-json-file": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-2.0.0.tgz", + "integrity": "sha1-eUfkIUmvgNaWy/eXvKq8/h/inKg=", + "dev": true, + "requires": { + "graceful-fs": "4.1.11", + "parse-json": "2.2.0", + "pify": "2.3.0", + "strip-bom": "3.0.0" + } + }, + "path-type": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/path-type/-/path-type-2.0.0.tgz", + "integrity": "sha1-8BLMuEFbcJb8LaoQVMPXI4lZTHM=", + "dev": true, + "requires": { + "pify": "2.3.0" + } + }, + "read-pkg": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-2.0.0.tgz", + "integrity": "sha1-jvHAYjxqbbDcZxPEv6xGMysjaPg=", + "dev": true, + "requires": { + "load-json-file": "2.0.0", + "normalize-package-data": "2.4.0", + "path-type": "2.0.0" + } + }, + "read-pkg-up": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-2.0.0.tgz", + "integrity": "sha1-a3KoBImE4MQeeVEP1en6mbO1Sb4=", + "dev": true, + "requires": { + "find-up": "2.1.0", + "read-pkg": "2.0.0" + } + }, + "strip-bom": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", + "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=", + "dev": true + } + } + }, + "eslint-plugin-jsx-a11y": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.1.0.tgz", + "integrity": "sha512-hnhf28u7Z9zlh7Y56tETrwnPeBvXgcqlP7ntHvZsWQs/n/p/vPnfNMNFWTqJAFcbd8PrDEifX1NRGHsjnUmqMw==", + "dev": true, + "requires": { + "aria-query": "3.0.0", + "array-includes": "3.0.3", + "ast-types-flow": "0.0.7", + "axobject-query": "2.0.1", + "damerau-levenshtein": "1.0.4", + "emoji-regex": "6.5.1", + "has": "1.0.3", + "jsx-ast-utils": "2.0.1" + } }, "eslint-plugin-react": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-5.0.1.tgz", - "integrity": "sha1-WljFIoy6dCAuRaik1jUf+7Dqdbk=", + "version": "7.10.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.10.0.tgz", + "integrity": "sha512-18rzWn4AtbSUxFKKM7aCVcj5LXOhOKdwBino3KKWy4psxfPW0YtIbE8WNRDUdyHFL50BeLb6qFd4vpvNYyp7hw==", + "dev": true, + "requires": { + "doctrine": "2.1.0", + "has": "1.0.3", + "jsx-ast-utils": "2.0.1", + "prop-types": "15.6.2" + } + }, + "eslint-restricted-globals": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/eslint-restricted-globals/-/eslint-restricted-globals-0.1.1.tgz", + "integrity": "sha1-NfDVy8ZMLj7WLpO0saevBbp+1Nc=", + "dev": true + }, + "eslint-scope": { + "version": "3.7.1", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-3.7.1.tgz", + "integrity": "sha1-PWPD7f2gLgbgGkUq2IyqzHzctug=", + "dev": true, + "requires": { + "esrecurse": "4.2.1", + "estraverse": "4.2.0" + } + }, + "eslint-visitor-keys": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz", + "integrity": "sha512-qzm/XxIbxm/FHyH341ZrbnMUpe+5Bocte9xkmFMzPMjRaZMcXww+MpBptFvtU+79L362nqiLhekCxCxDPaUMBQ==", "dev": true }, "espree": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/espree/-/espree-3.1.4.tgz", - "integrity": "sha1-BybXrIOvl6fISY2ps2OjYJ0qaKE=", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/espree/-/espree-4.0.0.tgz", + "integrity": "sha512-kapdTCt1bjmspxStVKX6huolXVV5ZfyZguY1lcfhVVZstce3bqxH9mcLzNn3/mlgW6wQ732+0fuG9v7h0ZQoKg==", "dev": true, "requires": { - "acorn": "3.3.0", - "acorn-jsx": "3.0.1" + "acorn": "5.7.1", + "acorn-jsx": "4.1.1" } }, "esprima": { @@ -3363,6 +3863,15 @@ "integrity": "sha512-oftTcaMu/EGrEIu904mWteKIv8vMuOgGYo7EhVJJN00R/EED9DCua/xxHRdYnKtcECzVg7xOWhflvJMnqcFZjw==", "dev": true }, + "esquery": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.0.1.tgz", + "integrity": "sha512-SmiyZ5zIWH9VM+SRUReLS5Q8a7GxtRdxEBVZpm98rJM7Sb+A9DVCndXfkeFUd3byderg+EbDkfnevfCwynWaNA==", + "dev": true, + "requires": { + "estraverse": "4.2.0" + } + }, "esrecurse": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.2.1.tgz", @@ -3440,10 +3949,48 @@ "merge": "1.2.0" } }, - "exit-hook": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/exit-hook/-/exit-hook-1.1.1.tgz", - "integrity": "sha1-8FyiM7SMBdVP/wd2XfhQfpXAL/g=", + "execa": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/execa/-/execa-0.7.0.tgz", + "integrity": "sha1-lEvs00zEHuMqY6n68nrVpl/Fl3c=", + "dev": true, + "requires": { + "cross-spawn": "5.1.0", + "get-stream": "3.0.0", + "is-stream": "1.1.0", + "npm-run-path": "2.0.2", + "p-finally": "1.0.0", + "signal-exit": "3.0.2", + "strip-eof": "1.0.0" + }, + "dependencies": { + "cross-spawn": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-5.1.0.tgz", + "integrity": "sha1-6L0O/uWPz/b4+UUQoKVUu/ojVEk=", + "dev": true, + "requires": { + "lru-cache": "4.1.3", + "shebang-command": "1.2.0", + "which": "1.3.1" + } + }, + "lru-cache": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.3.tgz", + "integrity": "sha512-fFEhvcgzuIoJVUF8fYr5KR0YqxD238zgObTps31YdADwPPAp82a4M8TrckkWyx7ekNlf9aBcVn81cFwwXngrJA==", + "dev": true, + "requires": { + "pseudomap": "1.0.2", + "yallist": "2.1.2" + } + } + } + }, + "exit": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/exit/-/exit-0.1.2.tgz", + "integrity": "sha1-BjJjj42HfMghB9MKD/8aF8uhzQw=", "dev": true }, "expand-brackets": { @@ -3473,6 +4020,31 @@ "homedir-polyfill": "1.0.1" } }, + "expect": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/expect/-/expect-23.3.0.tgz", + "integrity": "sha1-7LBRrcvcQKxNtXbBYGfxL9sTzGE=", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "jest-diff": "23.2.0", + "jest-get-type": "22.4.3", + "jest-matcher-utils": "23.2.0", + "jest-message-util": "23.3.0", + "jest-regex-util": "23.3.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + } + } + }, "express": { "version": "4.16.3", "resolved": "https://registry.npmjs.org/express/-/express-4.16.3.tgz", @@ -3511,6 +4083,15 @@ "vary": "1.1.2" }, "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, "qs": { "version": "6.5.1", "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.1.tgz", @@ -3528,8 +4109,7 @@ "extend": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.1.tgz", - "integrity": "sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ=", - "dev": true + "integrity": "sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ=" }, "extend-shallow": { "version": "3.0.2", @@ -3552,6 +4132,17 @@ } } }, + "external-editor": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-2.2.0.tgz", + "integrity": "sha512-bSn6gvGxKt+b7+6TKEv1ZycHleA7aHhRHyAqJyp5pbUFuYYNIzpZnQDk7AsYckyWdEnTeAnay0aCy2aV6iTk9A==", + "dev": true, + "requires": { + "chardet": "0.4.2", + "iconv-lite": "0.4.23", + "tmp": "0.0.33" + } + }, "extglob": { "version": "0.3.2", "resolved": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz", @@ -3559,6 +4150,14 @@ "dev": true, "requires": { "is-extglob": "1.0.0" + }, + "dependencies": { + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", + "dev": true + } } }, "extsprintf": { @@ -3579,9 +4178,9 @@ } }, "fast-deep-equal": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-1.1.0.tgz", - "integrity": "sha1-wFNHeBfIa1HaqFPIHgWbcz0CNhQ=", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz", + "integrity": "sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk=", "dev": true }, "fast-json-stable-stringify": { @@ -3606,12 +4205,12 @@ } }, "fb-watchman": { - "version": "1.9.2", - "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-1.9.2.tgz", - "integrity": "sha1-okz0eCf4LTj7Waaa1wt247auc4M=", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.0.tgz", + "integrity": "sha1-VOmr99+i8mzZsWNsWIwa/AXeXVg=", "dev": true, "requires": { - "bser": "1.0.2" + "bser": "2.0.0" } }, "feature-detect-es6": { @@ -3624,19 +4223,18 @@ } }, "figures": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz", - "integrity": "sha1-y+Hjr/zxzUS4DK3+0o3Hk6lwHS4=", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-2.0.0.tgz", + "integrity": "sha1-OrGi0qYsi/tDGgyUy3l6L84nyWI=", "dev": true, "requires": { - "escape-string-regexp": "1.0.5", - "object-assign": "4.1.1" + "escape-string-regexp": "1.0.5" } }, "file-entry-cache": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-1.3.1.tgz", - "integrity": "sha1-RMYepgeuS+nBQC9B9EJwy/4zT/g=", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-2.0.0.tgz", + "integrity": "sha1-w5KZDD5oR4PYOLjISkXYoEhFg2E=", "dev": true, "requires": { "flat-cache": "1.3.0", @@ -3651,31 +4249,6 @@ "requires": { "array-back": "1.0.4", "glob": "7.1.2" - }, - "dependencies": { - "glob": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", - "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", - "dev": true, - "requires": { - "fs.realpath": "1.0.0", - "inflight": "1.0.6", - "inherits": "2.0.3", - "minimatch": "3.0.4", - "once": "1.4.0", - "path-is-absolute": "1.0.1" - } - }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "dev": true, - "requires": { - "brace-expansion": "1.1.11" - } - } } }, "filename-regex": { @@ -3684,6 +4257,16 @@ "integrity": "sha1-wcS5vuPglyXdsQa3XB4wH+LxiyY=", "dev": true }, + "fileset": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/fileset/-/fileset-2.0.3.tgz", + "integrity": "sha1-jnVIqW08wjJ+5eZ0FocjozO7oqA=", + "dev": true, + "requires": { + "glob": "7.1.2", + "minimatch": "3.0.4" + } + }, "fill-range": { "version": "2.2.4", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-2.2.4.tgz", @@ -3731,6 +4314,28 @@ "parseurl": "1.3.2", "statuses": "1.4.0", "unpipe": "1.0.0" + }, + "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + } + } + }, + "find-cache-dir": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-1.0.0.tgz", + "integrity": "sha1-kojj6ePMN0hxfTnq3hfPcfww7m8=", + "dev": true, + "requires": { + "commondir": "1.0.1", + "make-dir": "1.3.0", + "pkg-dir": "2.0.0" } }, "find-index": { @@ -3750,36 +4355,12 @@ } }, "find-up": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz", - "integrity": "sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8=", - "dev": true, - "requires": { - "path-exists": "2.1.0", - "pinkie-promise": "2.0.1" - }, - "dependencies": { - "path-exists": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz", - "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=", - "dev": true, - "requires": { - "pinkie-promise": "2.0.1" - } - } - } - }, - "find-versions": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/find-versions/-/find-versions-1.2.1.tgz", - "integrity": "sha1-y96fEuOFdaCvG+G5osXV/Y8Ya2I=", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz", + "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=", "dev": true, "requires": { - "array-uniq": "1.0.3", - "get-stdin": "4.0.1", - "meow": "3.7.0", - "semver-regex": "1.0.0" + "locate-path": "2.0.0" } }, "findup-sync": { @@ -3835,6 +4416,15 @@ } } }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, "expand-brackets": { "version": "2.1.4", "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", @@ -4015,21 +4605,6 @@ "kind-of": "6.0.2" } }, - "is-extglob": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", - "dev": true - }, - "is-glob": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-3.1.0.tgz", - "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=", - "dev": true, - "requires": { - "is-extglob": "2.1.1" - } - }, "is-number": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", @@ -4117,18 +4692,48 @@ "dev": true, "requires": { "circular-json": "0.3.3", - "del": "2.0.2", + "del": "2.2.2", "graceful-fs": "4.1.11", "write": "0.2.1" + }, + "dependencies": { + "del": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/del/-/del-2.2.2.tgz", + "integrity": "sha1-wSyYHQZ4RshLyvhiz/kw2Qf/0ag=", + "dev": true, + "requires": { + "globby": "5.0.0", + "is-path-cwd": "1.0.0", + "is-path-in-cwd": "1.0.1", + "object-assign": "4.1.1", + "pify": "2.3.0", + "pinkie-promise": "2.0.1", + "rimraf": "2.6.2" + } + }, + "globby": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/globby/-/globby-5.0.0.tgz", + "integrity": "sha1-69hGZ8oNuzMLmbz8aOrCvFQ3Dg0=", + "dev": true, + "requires": { + "array-union": "1.0.2", + "arrify": "1.0.1", + "glob": "7.1.2", + "object-assign": "4.1.1", + "pify": "2.3.0", + "pinkie-promise": "2.0.1" + } + } } }, "follow-redirects": { - "version": "0.0.7", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-0.0.7.tgz", - "integrity": "sha1-NLkLqyqRGqNHVx2pDyK9NuzYqRk=", + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.5.0.tgz", + "integrity": "sha512-fdrt472/9qQ6Kgjvb935ig6vJCuofpBUD14f9Vb+SLlm7xIe4Qva5gey8EKtv8lp7ahE1wilg3xL1znpVGtZIA==", "requires": { - "debug": "2.6.9", - "stream-consume": "0.1.1" + "debug": "3.1.0" } }, "for-in": { @@ -4146,6 +4751,12 @@ "for-in": "1.0.2" } }, + "foreach": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/foreach/-/foreach-2.0.5.tgz", + "integrity": "sha1-C+4AUBiusmDQo6865ljdATbsG5k=", + "dev": true + }, "forever-agent": { "version": "0.6.1", "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", @@ -4185,9 +4796,9 @@ "dev": true }, "fs-readdir-recursive": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/fs-readdir-recursive/-/fs-readdir-recursive-0.1.2.tgz", - "integrity": "sha1-MVtPuMHKW4xH3v7zGdBz2tNWgFk=", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/fs-readdir-recursive/-/fs-readdir-recursive-1.1.0.tgz", + "integrity": "sha512-GNanXlVr2pf02+sPN40XN8HG+ePaNcvM0q5mZBd668Obwb0yD5GiUbZOFgwn8kGMY6I3mdyDJzieUy3PTYyTRA==", "dev": true }, "fs-then-native": { @@ -4202,8 +4813,7 @@ "fs.realpath": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", - "dev": true + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" }, "fsevents": { "version": "1.2.4", @@ -4734,6 +5344,18 @@ } } }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", + "dev": true + }, + "functional-red-black-tree": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz", + "integrity": "sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc=", + "dev": true + }, "gaze": { "version": "0.5.2", "resolved": "https://registry.npmjs.org/gaze/-/gaze-0.5.2.tgz", @@ -4743,25 +5365,16 @@ "globule": "0.1.0" } }, - "generate-function": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/generate-function/-/generate-function-2.0.0.tgz", - "integrity": "sha1-aFj+fAlpt9TpCTM3ZHrHn2DfvnQ=", + "get-caller-file": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-1.0.2.tgz", + "integrity": "sha1-9wLmMSfn4jHBYKgMFVSstw1QR+U=", "dev": true }, - "generate-object-property": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/generate-object-property/-/generate-object-property-1.2.0.tgz", - "integrity": "sha1-nA4cQDCM6AT0eDYYuTf6iPmdUNA=", - "dev": true, - "requires": { - "is-property": "1.0.2" - } - }, - "get-stdin": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-4.0.1.tgz", - "integrity": "sha1-uWjGsKBDhDJJAui/Gl3zJXmkUP4=", + "get-stream": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz", + "integrity": "sha1-jpQ9E1jcN1VQVOy+LtsFqhdO3hQ=", "dev": true }, "get-value": { @@ -4780,14 +5393,14 @@ } }, "glob": { - "version": "5.0.15", - "resolved": "https://registry.npmjs.org/glob/-/glob-5.0.15.tgz", - "integrity": "sha1-G8k2ueAvSmA/zCIuz3Yz0wuLk7E=", - "dev": true, + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", + "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", "requires": { + "fs.realpath": "1.0.0", "inflight": "1.0.6", "inherits": "2.0.3", - "minimatch": "2.0.10", + "minimatch": "3.0.4", "once": "1.4.0", "path-is-absolute": "1.0.1" } @@ -4800,41 +5413,85 @@ "requires": { "glob-parent": "2.0.0", "is-glob": "2.0.1" + }, + "dependencies": { + "glob-parent": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-2.0.0.tgz", + "integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=", + "dev": true, + "requires": { + "is-glob": "2.0.1" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", + "dev": true + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "dev": true, + "requires": { + "is-extglob": "1.0.0" + } + } } }, "glob-parent": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-2.0.0.tgz", - "integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=", - "dev": true, + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-3.1.0.tgz", + "integrity": "sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4=", "requires": { - "is-glob": "2.0.1" + "is-glob": "3.1.0", + "path-dirname": "1.0.2" } }, "glob-stream": { - "version": "3.1.18", - "resolved": "https://registry.npmjs.org/glob-stream/-/glob-stream-3.1.18.tgz", - "integrity": "sha1-kXCl8St5Awb9/lmPMT+PeVT9FDs=", - "dev": true, + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/glob-stream/-/glob-stream-6.1.0.tgz", + "integrity": "sha1-cEXJlBOz65SIjYOrRtC0BMx73eQ=", "requires": { - "glob": "4.5.3", - "glob2base": "0.0.12", - "minimatch": "2.0.10", - "ordered-read-streams": "0.1.0", - "through2": "0.6.5", - "unique-stream": "1.0.0" + "extend": "3.0.1", + "glob": "7.1.2", + "glob-parent": "3.1.0", + "is-negated-glob": "1.0.0", + "ordered-read-streams": "1.0.1", + "pumpify": "1.5.1", + "readable-stream": "2.3.6", + "remove-trailing-separator": "1.1.0", + "to-absolute-glob": "2.0.2", + "unique-stream": "2.2.1" }, "dependencies": { - "glob": { - "version": "4.5.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-4.5.3.tgz", - "integrity": "sha1-xstz0yJsHv7wTePFbQEvAzd+4V8=", - "dev": true, + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" + }, + "readable-stream": { + "version": "2.3.6", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "requires": { - "inflight": "1.0.6", + "core-util-is": "1.0.2", "inherits": "2.0.3", - "minimatch": "2.0.10", - "once": "1.4.0" + "isarray": "1.0.0", + "process-nextick-args": "2.0.0", + "safe-buffer": "5.1.2", + "string_decoder": "1.1.1", + "util-deprecate": "1.0.2" + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "5.1.2" } } } @@ -4888,34 +5545,16 @@ "dev": true }, "globby": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/globby/-/globby-3.0.1.tgz", - "integrity": "sha1-IJSvhCHhkVIVDViT62QWsxLZoi8=", + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/globby/-/globby-6.1.0.tgz", + "integrity": "sha1-9abXDoOV4hyFj7BInWTfAkJNUGw=", "dev": true, "requires": { "array-union": "1.0.2", - "arrify": "1.0.1", - "glob": "5.0.15", + "glob": "7.1.2", "object-assign": "4.1.1", "pify": "2.3.0", - "pinkie-promise": "1.0.0" - }, - "dependencies": { - "pinkie": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/pinkie/-/pinkie-1.0.0.tgz", - "integrity": "sha1-Wkfyi6EBXQIBvae/DzWOR77Ix+Q=", - "dev": true - }, - "pinkie-promise": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/pinkie-promise/-/pinkie-promise-1.0.0.tgz", - "integrity": "sha1-0dpn9UglY7t89X8oauKCLs+/NnA=", - "dev": true, - "requires": { - "pinkie": "1.0.0" - } - } + "pinkie-promise": "2.0.1" } }, "globule": { @@ -4985,132 +5624,51 @@ "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=", "dev": true }, + "growly": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/growly/-/growly-1.3.0.tgz", + "integrity": "sha1-8QdIy+dq+WS3yWyTxrzCivEgwIE=", + "dev": true + }, "gulp": { - "version": "3.8.11", - "resolved": "https://registry.npmjs.org/gulp/-/gulp-3.8.11.tgz", - "integrity": "sha1-1Vfgpyg+tBNkkZabBJd2eXLx0oo=", + "version": "3.9.1", + "resolved": "https://registry.npmjs.org/gulp/-/gulp-3.9.1.tgz", + "integrity": "sha1-VxzkWSjdQK9lFPxAEYZgFsE4RbQ=", "dev": true, "requires": { "archy": "1.0.0", - "chalk": "0.5.1", + "chalk": "1.1.3", "deprecated": "0.0.1", - "gulp-util": "3.0.4", - "interpret": "0.3.10", + "gulp-util": "3.0.8", + "interpret": "1.1.0", "liftoff": "2.5.0", "minimist": "1.2.0", "orchestrator": "0.3.8", - "pretty-hrtime": "0.2.2", + "pretty-hrtime": "1.0.3", "semver": "4.3.6", "tildify": "1.2.0", "v8flags": "2.1.1", "vinyl-fs": "0.3.14" }, "dependencies": { - "ansi-regex": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-0.2.1.tgz", - "integrity": "sha1-DY6UaWej2BQ/k+JOKYUl/BsiNfk=", - "dev": true - }, - "ansi-styles": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-1.1.0.tgz", - "integrity": "sha1-6uy/Zs1waIJ2Cy9GkVgrj1XXp94=", - "dev": true - }, - "chalk": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-0.5.1.tgz", - "integrity": "sha1-Zjs6ZItotV0EaQ1JFnqoN4WPIXQ=", - "dev": true, - "requires": { - "ansi-styles": "1.1.0", - "escape-string-regexp": "1.0.5", - "has-ansi": "0.1.0", - "strip-ansi": "0.3.0", - "supports-color": "0.2.0" - } - }, - "has-ansi": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-0.1.0.tgz", - "integrity": "sha1-hPJlqujA5qiKEtcCKJS3VoiUxi4=", - "dev": true, - "requires": { - "ansi-regex": "0.2.1" - } - }, - "strip-ansi": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-0.3.0.tgz", - "integrity": "sha1-JfSOoiynkYfzF0pNuHWTR7sSYiA=", - "dev": true, - "requires": { - "ansi-regex": "0.2.1" - } - }, - "supports-color": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-0.2.0.tgz", - "integrity": "sha1-2S3iaU6z9nMjlz1649i1W0wiGQo=", + "semver": { + "version": "4.3.6", + "resolved": "https://registry.npmjs.org/semver/-/semver-4.3.6.tgz", + "integrity": "sha1-MAvG4OhjdPe6YQaLWx7NV/xlMto=", "dev": true } } }, "gulp-babel": { - "version": "6.1.2", - "resolved": "https://registry.npmjs.org/gulp-babel/-/gulp-babel-6.1.2.tgz", - "integrity": "sha1-fAF25Lo/JExgWIoMSzIKRdGt784=", + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/gulp-babel/-/gulp-babel-7.0.1.tgz", + "integrity": "sha512-UqHS3AdxZyJCRxqnAX603Dj3k/Wx6hzcgmav3QcxvsIFq3Y8ZkU7iXd0O+JwD5ivqCc6o0r1S7tCB/xxLnuSNw==", "dev": true, "requires": { - "babel-core": "6.8.0", - "gulp-util": "3.0.4", - "object-assign": "4.1.1", + "plugin-error": "1.0.1", "replace-ext": "0.0.1", "through2": "2.0.3", "vinyl-sourcemaps-apply": "0.2.1" - }, - "dependencies": { - "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", - "dev": true - }, - "readable-stream": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", - "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", - "dev": true, - "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.3", - "isarray": "1.0.0", - "process-nextick-args": "2.0.0", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" - } - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "requires": { - "safe-buffer": "5.1.2" - } - }, - "through2": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.3.tgz", - "integrity": "sha1-AARWmzfHx0ujnEPzzteNGtlBQL4=", - "dev": true, - "requires": { - "readable-stream": "2.3.6", - "xtend": "4.0.1" - } - } } }, "gulp-jsdoc-to-markdown": { @@ -5122,210 +5680,71 @@ "gulp-util": "3.0.8", "jsdoc-to-markdown": "1.3.9", "through2": "2.0.3" - }, - "dependencies": { - "clone": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=", - "dev": true - }, - "dateformat": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-2.2.0.tgz", - "integrity": "sha1-QGXiATz5+5Ft39gu+1Bq1MZ2kGI=", - "dev": true - }, - "gulp-util": { - "version": "3.0.8", - "resolved": "https://registry.npmjs.org/gulp-util/-/gulp-util-3.0.8.tgz", - "integrity": "sha1-AFTh50RQLifATBh8PsxQXdVLu08=", - "dev": true, - "requires": { - "array-differ": "1.0.0", - "array-uniq": "1.0.3", - "beeper": "1.1.1", - "chalk": "1.1.1", - "dateformat": "2.2.0", - "fancy-log": "1.3.2", - "gulplog": "1.0.0", - "has-gulplog": "0.1.0", - "lodash._reescape": "3.0.0", - "lodash._reevaluate": "3.0.0", - "lodash._reinterpolate": "3.0.0", - "lodash.template": "3.6.2", - "minimist": "1.2.0", - "multipipe": "0.1.2", - "object-assign": "3.0.0", - "replace-ext": "0.0.1", - "through2": "2.0.3", - "vinyl": "0.5.3" - } - }, - "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", - "dev": true - }, - "object-assign": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-3.0.0.tgz", - "integrity": "sha1-m+3VygiXlJvKR+f/QIBi1Un1h/I=", - "dev": true - }, - "readable-stream": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", - "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", - "dev": true, - "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.3", - "isarray": "1.0.0", - "process-nextick-args": "2.0.0", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" - } - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "requires": { - "safe-buffer": "5.1.2" - } - }, - "through2": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.3.tgz", - "integrity": "sha1-AARWmzfHx0ujnEPzzteNGtlBQL4=", - "dev": true, - "requires": { - "readable-stream": "2.3.6", - "xtend": "4.0.1" - } - }, - "vinyl": { - "version": "0.5.3", - "resolved": "https://registry.npmjs.org/vinyl/-/vinyl-0.5.3.tgz", - "integrity": "sha1-sEVbOPxeDPMNQyUTLkYZcMIJHN4=", - "dev": true, - "requires": { - "clone": "1.0.4", - "clone-stats": "0.0.1", - "replace-ext": "0.0.1" - } - } } }, "gulp-rename": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/gulp-rename/-/gulp-rename-1.2.2.tgz", - "integrity": "sha1-OtRCh2PwXidk3sHGfYaNsnVoeBc=", + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/gulp-rename/-/gulp-rename-1.3.0.tgz", + "integrity": "sha512-nEuZB7/9i0IZ8AXORTizl2QLP9tcC9uWc/s329zElBLJw1CfOhmMXBxwVlCRKjDyrWuhVP0uBKl61KeQ32TiCg==", "dev": true }, "gulp-sourcemaps": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/gulp-sourcemaps/-/gulp-sourcemaps-1.6.0.tgz", - "integrity": "sha1-uG/zSdgBzrVuHZ59x7vLS33uYAw=", + "version": "2.6.4", + "resolved": "https://registry.npmjs.org/gulp-sourcemaps/-/gulp-sourcemaps-2.6.4.tgz", + "integrity": "sha1-y7IAhFCxvM5s0jv5gze+dRv24wo=", "dev": true, "requires": { + "@gulp-sourcemaps/identity-map": "1.0.2", + "@gulp-sourcemaps/map-sources": "1.0.0", + "acorn": "5.7.1", "convert-source-map": "1.5.1", + "css": "2.2.3", + "debug-fabulous": "1.1.0", + "detect-newline": "2.1.0", "graceful-fs": "4.1.11", - "strip-bom": "2.0.0", - "through2": "2.0.3", - "vinyl": "1.2.0" + "source-map": "0.6.1", + "strip-bom-string": "1.0.0", + "through2": "2.0.3" }, "dependencies": { - "clone": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=", - "dev": true - }, - "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true - }, - "readable-stream": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", - "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", - "dev": true, - "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.3", - "isarray": "1.0.0", - "process-nextick-args": "2.0.0", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" - } - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "requires": { - "safe-buffer": "5.1.2" - } - }, - "through2": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.3.tgz", - "integrity": "sha1-AARWmzfHx0ujnEPzzteNGtlBQL4=", - "dev": true, - "requires": { - "readable-stream": "2.3.6", - "xtend": "4.0.1" - } - }, - "vinyl": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/vinyl/-/vinyl-1.2.0.tgz", - "integrity": "sha1-XIgDbPVl5d8FVYv8kR+GVt8hiIQ=", - "dev": true, - "requires": { - "clone": "1.0.4", - "clone-stats": "0.0.1", - "replace-ext": "0.0.1" - } } } }, "gulp-util": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/gulp-util/-/gulp-util-3.0.4.tgz", - "integrity": "sha1-7HNVMJD9sj2I+gKBKtG2EiWFSIE=", + "version": "3.0.8", + "resolved": "https://registry.npmjs.org/gulp-util/-/gulp-util-3.0.8.tgz", + "integrity": "sha1-AFTh50RQLifATBh8PsxQXdVLu08=", "dev": true, "requires": { "array-differ": "1.0.0", "array-uniq": "1.0.3", "beeper": "1.1.1", - "chalk": "1.1.1", - "dateformat": "1.0.12", + "chalk": "1.1.3", + "dateformat": "2.2.0", + "fancy-log": "1.3.2", + "gulplog": "1.0.0", + "has-gulplog": "0.1.0", "lodash._reescape": "3.0.0", "lodash._reevaluate": "3.0.0", "lodash._reinterpolate": "3.0.0", "lodash.template": "3.6.2", "minimist": "1.2.0", "multipipe": "0.1.2", - "object-assign": "2.1.1", + "object-assign": "3.0.0", "replace-ext": "0.0.1", - "through2": "0.6.5", - "vinyl": "0.4.6" + "through2": "2.0.3", + "vinyl": "0.5.3" }, "dependencies": { "object-assign": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-2.1.1.tgz", - "integrity": "sha1-Q8NuXVaf+OSBbE76i+AtJpZ8GKo=", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-3.0.0.tgz", + "integrity": "sha1-m+3VygiXlJvKR+f/QIBi1Un1h/I=", "dev": true } } @@ -5423,6 +5842,41 @@ "requires": { "ajv": "5.5.2", "har-schema": "2.0.0" + }, + "dependencies": { + "ajv": { + "version": "5.5.2", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-5.5.2.tgz", + "integrity": "sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU=", + "dev": true, + "requires": { + "co": "4.6.0", + "fast-deep-equal": "1.1.0", + "fast-json-stable-stringify": "2.0.0", + "json-schema-traverse": "0.3.1" + } + }, + "fast-deep-equal": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-1.1.0.tgz", + "integrity": "sha1-wFNHeBfIa1HaqFPIHgWbcz0CNhQ=", + "dev": true + }, + "json-schema-traverse": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz", + "integrity": "sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A=", + "dev": true + } + } + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, + "requires": { + "function-bind": "1.1.1" } }, "has-ansi": { @@ -5435,9 +5889,9 @@ } }, "has-flag": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", - "integrity": "sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", "dev": true }, "has-gulplog": { @@ -5449,6 +5903,12 @@ "sparkles": "1.0.1" } }, + "has-symbols": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.0.tgz", + "integrity": "sha1-uhqPGvKg/DllD1yFA2dwQSIGO0Q=", + "dev": true + }, "has-value": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/has-value/-/has-value-1.0.0.tgz", @@ -5530,13 +5990,13 @@ } }, "help-me": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/help-me/-/help-me-0.1.0.tgz", - "integrity": "sha1-D7OkBTetUmW2tJQTAixg01tJU5o=", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/help-me/-/help-me-1.1.0.tgz", + "integrity": "sha1-jy1QjQYAtKRW2i8IZVbn5cBWo8Y=", "requires": { - "concat-stream": "1.6.2", - "pump": "1.0.3", - "readable-stream": "1.1.14", + "callback-stream": "1.1.0", + "glob-stream": "6.1.0", + "through2": "2.0.3", "xtend": "4.0.1" } }, @@ -5628,26 +6088,6 @@ "eventemitter3": "3.1.0", "follow-redirects": "1.5.0", "requires-port": "1.0.0" - }, - "dependencies": { - "debug": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz", - "integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==", - "dev": true, - "requires": { - "ms": "2.0.0" - } - }, - "follow-redirects": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.5.0.tgz", - "integrity": "sha512-fdrt472/9qQ6Kgjvb935ig6vJCuofpBUD14f9Vb+SLlm7xIe4Qva5gey8EKtv8lp7ahE1wilg3xL1znpVGtZIA==", - "dev": true, - "requires": { - "debug": "3.1.0" - } - } } }, "http-signature": { @@ -5662,21 +6102,24 @@ } }, "https-browserify": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/https-browserify/-/https-browserify-0.0.1.tgz", - "integrity": "sha1-P5E2XKvmC3ftDruiS0VOPgnZWoI=", + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/https-browserify/-/https-browserify-1.0.0.tgz", + "integrity": "sha1-7AbBDgo0wPL68Zn3/X/Hj//QPHM=", "dev": true }, "humps": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/humps/-/humps-1.1.0.tgz", - "integrity": "sha1-maBcyAsTrnVKPR4akhgvJx7x2Y8=" + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/humps/-/humps-2.0.1.tgz", + "integrity": "sha1-3QLqYIG9BWjcXQcxhEY5V7qe+ao=" }, "iconv-lite": { - "version": "0.4.19", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.19.tgz", - "integrity": "sha512-oTZqweIP51xaGPI4uPa56/Pri/480R+mo7SeU+YETByQNhDG55ycFyNLIgta9vXhILrxXDmF7ZGhqZIcuN0gJQ==", - "dev": true + "version": "0.4.23", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.23.tgz", + "integrity": "sha512-neyTUVFtahjf0mB3dZT77u+8O0QB89jFdnBkd5P1JgYPbPaia3gXXOVL2fq8VyU2gMMD7SaN7QukTB/pmXYvDA==", + "dev": true, + "requires": { + "safer-buffer": "2.1.2" + } }, "ieee754": { "version": "1.1.12", @@ -5690,21 +6133,22 @@ "integrity": "sha512-Pgs951kaMm5GXP7MOvxERINe3gsaVjUWFm+UZPSq9xYriQAksyhg0csnS0KXSNRD5NmNdapXEpjxG49+AKh/ug==", "dev": true }, + "import-local": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/import-local/-/import-local-1.0.0.tgz", + "integrity": "sha512-vAaZHieK9qjGo58agRBg+bhHX3hoTZU/Oa3GESWLz7t1U62fk63aHuDJJEteXoDeTCcPmUT+z38gkHPZkkmpmQ==", + "dev": true, + "requires": { + "pkg-dir": "2.0.0", + "resolve-cwd": "2.0.0" + } + }, "imurmurhash": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", "dev": true }, - "indent-string": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-2.1.0.tgz", - "integrity": "sha1-ji1INIdCEhtKghi3oTfppSBJ3IA=", - "dev": true, - "requires": { - "repeating": "2.0.1" - } - }, "indexof": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/indexof/-/indexof-0.0.1.tgz", @@ -5715,7 +6159,6 @@ "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", - "dev": true, "requires": { "once": "1.4.0", "wrappy": "1.0.2" @@ -5733,30 +6176,76 @@ "dev": true }, "inquirer": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-0.12.0.tgz", - "integrity": "sha1-HvK/1jUE3wvHV4X/+MLEHfEvB34=", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-5.2.0.tgz", + "integrity": "sha512-E9BmnJbAKLPGonz0HeWHtbKf+EeSP93paWO3ZYoUpq/aowXvYGjjCSuashhXPpzbArIjBbji39THkxTz9ZeEUQ==", "dev": true, "requires": { - "ansi-escapes": "1.4.0", - "ansi-regex": "2.1.1", - "chalk": "1.1.1", - "cli-cursor": "1.0.2", + "ansi-escapes": "3.1.0", + "chalk": "2.4.1", + "cli-cursor": "2.1.0", "cli-width": "2.2.0", - "figures": "1.7.0", - "lodash": "4.11.2", - "readline2": "1.0.1", - "run-async": "0.1.0", - "rx-lite": "3.1.2", - "string-width": "1.0.2", - "strip-ansi": "3.0.1", + "external-editor": "2.2.0", + "figures": "2.0.0", + "lodash": "4.17.10", + "mute-stream": "0.0.7", + "run-async": "2.3.0", + "rxjs": "5.5.11", + "string-width": "2.1.1", + "strip-ansi": "4.0.0", "through": "2.3.8" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "dev": true, + "requires": { + "ansi-regex": "3.0.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } } }, "interpret": { - "version": "0.3.10", - "resolved": "https://registry.npmjs.org/interpret/-/interpret-0.3.10.tgz", - "integrity": "sha1-CIwl3nMcbFsRKpDwBxz69Fnlp7s=", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/interpret/-/interpret-1.1.0.tgz", + "integrity": "sha1-ftGxQQxqDg94z5XTuEQMY/eLhhQ=", "dev": true }, "invariant": { @@ -5768,6 +6257,12 @@ "loose-envify": "1.3.1" } }, + "invert-kv": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-1.0.0.tgz", + "integrity": "sha1-EEqOSqym09jNFXqO+L+rLXo//bY=", + "dev": true + }, "ipaddr.js": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.6.0.tgz", @@ -5778,7 +6273,6 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-absolute/-/is-absolute-1.0.0.tgz", "integrity": "sha512-dOWoqflvcydARa360Gvv18DZ/gRuHKi2NU/wU5X1ZFzdYfH29nkiNZsF3mp4OJ3H4yo9Mx8A/uAGNzpzPN3yBA==", - "dev": true, "requires": { "is-relative": "1.0.0", "is-windows": "1.0.2" @@ -5811,8 +6305,7 @@ "is-buffer": { "version": "1.1.6", "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", - "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==", - "dev": true + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" }, "is-builtin-module": { "version": "1.0.0", @@ -5823,6 +6316,21 @@ "builtin-modules": "1.1.1" } }, + "is-callable": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.1.4.tgz", + "integrity": "sha512-r5p9sxJjYnArLjObpjA4xu5EKI3CuKHkJXMhT7kwbpUyIFD1n5PMAsoPvWnvtZiNz7LjkYDRZhd7FlI0eMijEA==", + "dev": true + }, + "is-ci": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-ci/-/is-ci-1.1.0.tgz", + "integrity": "sha512-c7TnwxLePuqIlxHgr7xtxzycJPegNHFuIrBkwbf8hc58//+Op1CqFkyS+xnIMkwn9UsJIwc174BIjkyBmSpjKg==", + "dev": true, + "requires": { + "ci-info": "1.1.3" + } + }, "is-data-descriptor": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", @@ -5832,6 +6340,12 @@ "kind-of": "3.2.2" } }, + "is-date-object": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.1.tgz", + "integrity": "sha1-mqIOtq7rv/d/vTPnTKAbM1gdOhY=", + "dev": true + }, "is-descriptor": { "version": "0.1.6", "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", @@ -5873,10 +6387,9 @@ "dev": true }, "is-extglob": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", - "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", - "dev": true + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=" }, "is-finite": { "version": "1.0.2", @@ -5888,41 +6401,29 @@ } }, "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", + "dev": true + }, + "is-generator-fn": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", - "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", - "dev": true, - "requires": { - "number-is-nan": "1.0.1" - } + "resolved": "https://registry.npmjs.org/is-generator-fn/-/is-generator-fn-1.0.0.tgz", + "integrity": "sha1-lp1J4bszKfa7fwkIm+JleLLd1Go=", + "dev": true }, "is-glob": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", - "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", - "dev": true, + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-3.1.0.tgz", + "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=", "requires": { - "is-extglob": "1.0.0" + "is-extglob": "2.1.1" } }, - "is-my-ip-valid": { + "is-negated-glob": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-my-ip-valid/-/is-my-ip-valid-1.0.0.tgz", - "integrity": "sha512-gmh/eWXROncUzRnIa1Ubrt5b8ep/MGSnfAUI3aRp+sqTCs1tv1Isl8d8F6JmkN3dXKc3ehZMrtiPN9eL03NuaQ==", - "dev": true - }, - "is-my-json-valid": { - "version": "2.17.2", - "resolved": "https://registry.npmjs.org/is-my-json-valid/-/is-my-json-valid-2.17.2.tgz", - "integrity": "sha512-IBhBslgngMQN8DDSppmgDv7RNrlFotuuDsKcrCP3+HbFaVivIBU7u9oiiErw8sH4ynx3+gOGQ3q2otkgiSi6kg==", - "dev": true, - "requires": { - "generate-function": "2.0.0", - "generate-object-property": "1.2.0", - "is-my-ip-valid": "1.0.0", - "jsonpointer": "4.0.1", - "xtend": "4.0.1" - } + "resolved": "https://registry.npmjs.org/is-negated-glob/-/is-negated-glob-1.0.0.tgz", + "integrity": "sha1-aRC8pdqMleeEtXUbl2z1oQ/uNtI=" }, "is-number": { "version": "2.1.0", @@ -5986,17 +6487,25 @@ "integrity": "sha1-IHurkWOEmcB7Kt8kCkGochADRXU=", "dev": true }, - "is-property": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-property/-/is-property-1.0.2.tgz", - "integrity": "sha1-V/4cTkhHTt1lsJkR8msc1Ald2oQ=", + "is-promise": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-2.1.0.tgz", + "integrity": "sha1-eaKp7OfwlugPNtKy87wWwf9L8/o=", "dev": true }, + "is-regex": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.0.4.tgz", + "integrity": "sha1-VRdIm1RwkbCTDglWVM7SXul+lJE=", + "dev": true, + "requires": { + "has": "1.0.3" + } + }, "is-relative": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-relative/-/is-relative-1.0.0.tgz", "integrity": "sha512-Kw/ReK0iqwKeu0MITLFuj0jbPAmEiOsIwyIXvvbfa6QfmN9pkD1M+8pdk7Rl/dTKbH34/XBFMbgD4iMJhLQbGA==", - "dev": true, "requires": { "is-unc-path": "1.0.0" } @@ -6007,6 +6516,18 @@ "integrity": "sha512-qgDYXFSR5WvEfuS5dMj6oTMEbrrSaM0CrFk2Yiq/gXnBvD9pMa2jGXxyhGLfvhZpuMZe18CJpFxAt3CRs42NMg==", "dev": true }, + "is-stream": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", + "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=", + "dev": true + }, + "is-symbol": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.1.tgz", + "integrity": "sha1-PMWfAAJRlLarLjjbrmaJJWtmBXI=", + "dev": true + }, "is-typedarray": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", @@ -6016,7 +6537,6 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-unc-path/-/is-unc-path-1.0.0.tgz", "integrity": "sha512-mrGpVd0fs7WWLfVsStvgF6iEJnbjDFZh9/emhRDcGWTduTfNHd9CHeUwH3gYIjdbwo4On6hunkztwOaAw0yllQ==", - "dev": true, "requires": { "unc-path-regex": "0.1.2" } @@ -6030,8 +6550,7 @@ "is-windows": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", - "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==", - "dev": true + "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==" }, "isarray": { "version": "0.0.1", @@ -6067,26 +6586,116 @@ "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=", "dev": true }, - "istanbul": { - "version": "0.4.5", - "resolved": "https://registry.npmjs.org/istanbul/-/istanbul-0.4.5.tgz", - "integrity": "sha1-ZcfXPUxNqE1POsMQuRj7C4Azczs=", + "istanbul-api": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/istanbul-api/-/istanbul-api-1.3.1.tgz", + "integrity": "sha512-duj6AlLcsWNwUpfyfHt0nWIeRiZpuShnP40YTxOGQgtaN8fd6JYSxsvxUphTDy8V5MfDXo4s/xVCIIvVCO808g==", + "dev": true, + "requires": { + "async": "2.6.1", + "compare-versions": "3.3.0", + "fileset": "2.0.3", + "istanbul-lib-coverage": "1.2.0", + "istanbul-lib-hook": "1.2.1", + "istanbul-lib-instrument": "1.10.1", + "istanbul-lib-report": "1.1.4", + "istanbul-lib-source-maps": "1.2.5", + "istanbul-reports": "1.3.0", + "js-yaml": "3.12.0", + "mkdirp": "0.5.1", + "once": "1.4.0" + }, + "dependencies": { + "async": { + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/async/-/async-2.6.1.tgz", + "integrity": "sha512-fNEiL2+AZt6AlAw/29Cr0UDe4sRAHCpEHh54WMz+Bb7QfNcFw4h3loofyJpLeQs4Yx7yuqu/2dLgM5hKOs6HlQ==", + "dev": true, + "requires": { + "lodash": "4.17.10" + } + } + } + }, + "istanbul-lib-coverage": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-1.2.0.tgz", + "integrity": "sha512-GvgM/uXRwm+gLlvkWHTjDAvwynZkL9ns15calTrmhGgowlwJBbWMYzWbKqE2DT6JDP1AFXKa+Zi0EkqNCUqY0A==", + "dev": true + }, + "istanbul-lib-hook": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-hook/-/istanbul-lib-hook-1.2.1.tgz", + "integrity": "sha512-eLAMkPG9FU0v5L02lIkcj/2/Zlz9OuluaXikdr5iStk8FDbSwAixTK9TkYxbF0eNnzAJTwM2fkV2A1tpsIp4Jg==", "dev": true, "requires": { - "abbrev": "1.0.9", - "async": "1.5.2", - "escodegen": "1.8.1", - "esprima": "2.7.3", - "glob": "5.0.15", - "handlebars": "4.0.11", - "js-yaml": "3.12.0", + "append-transform": "1.0.0" + } + }, + "istanbul-lib-instrument": { + "version": "1.10.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-1.10.1.tgz", + "integrity": "sha512-1dYuzkOCbuR5GRJqySuZdsmsNKPL3PTuyPevQfoCXJePT9C8y1ga75neU+Tuy9+yS3G/dgx8wgOmp2KLpgdoeQ==", + "dev": true, + "requires": { + "babel-generator": "6.26.1", + "babel-template": "6.26.0", + "babel-traverse": "6.26.0", + "babel-types": "6.26.0", + "babylon": "6.18.0", + "istanbul-lib-coverage": "1.2.0", + "semver": "5.5.0" + } + }, + "istanbul-lib-report": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-1.1.4.tgz", + "integrity": "sha512-Azqvq5tT0U09nrncK3q82e/Zjkxa4tkFZv7E6VcqP0QCPn6oNljDPfrZEC/umNXds2t7b8sRJfs6Kmpzt8m2kA==", + "dev": true, + "requires": { + "istanbul-lib-coverage": "1.2.0", "mkdirp": "0.5.1", - "nopt": "3.0.6", - "once": "1.4.0", - "resolve": "1.1.7", - "supports-color": "3.2.3", - "which": "1.3.1", - "wordwrap": "1.0.0" + "path-parse": "1.0.5", + "supports-color": "3.2.3" + }, + "dependencies": { + "has-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", + "integrity": "sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=", + "dev": true + }, + "supports-color": { + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-3.2.3.tgz", + "integrity": "sha1-ZawFBLOVQXHYpklGsq48u4pfVPY=", + "dev": true, + "requires": { + "has-flag": "1.0.0" + } + } + } + }, + "istanbul-lib-source-maps": { + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-1.2.5.tgz", + "integrity": "sha512-8O2T/3VhrQHn0XcJbP1/GN7kXMiRAlPi+fj3uEHrjBD8Oz7Py0prSC25C09NuAZS6bgW1NNKAvCSHZXB0irSGA==", + "dev": true, + "requires": { + "debug": "3.1.0", + "istanbul-lib-coverage": "1.2.0", + "mkdirp": "0.5.1", + "rimraf": "2.6.2", + "source-map": "0.5.7" + } + }, + "istanbul-reports": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-1.3.0.tgz", + "integrity": "sha512-y2Z2IMqE1gefWUaVjrBm0mSKvUkaBy9Vqz8iwr/r40Y9hBbIteH5wqHG/9DLTfJ9xUnUT2j7A3+VVJ6EaYBllA==", + "dev": true, + "requires": { + "handlebars": "4.0.11" }, "dependencies": { "async": { @@ -6095,12 +6704,6 @@ "integrity": "sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo=", "dev": true }, - "esprima": { - "version": "2.7.3", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-2.7.3.tgz", - "integrity": "sha1-luO3DVd59q1JzQMmc9HDEnZ7pYE=", - "dev": true - }, "handlebars": { "version": "4.0.11", "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.0.11.tgz", @@ -6113,12 +6716,6 @@ "uglify-js": "2.8.29" } }, - "resolve": { - "version": "1.1.7", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.1.7.tgz", - "integrity": "sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs=", - "dev": true - }, "source-map": { "version": "0.4.4", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.4.4.tgz", @@ -6128,15 +6725,6 @@ "amdefine": "1.0.1" } }, - "supports-color": { - "version": "3.2.3", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-3.2.3.tgz", - "integrity": "sha1-ZawFBLOVQXHYpklGsq48u4pfVPY=", - "dev": true, - "requires": { - "has-flag": "1.0.0" - } - }, "uglify-js": { "version": "2.8.29", "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-2.8.29.tgz", @@ -6157,125 +6745,1969 @@ "optional": true } } + }, + "yargs": { + "version": "3.10.0", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-3.10.0.tgz", + "integrity": "sha1-9+572FfdfB0tOMDnTvvWgdFDH9E=", + "dev": true, + "optional": true, + "requires": { + "camelcase": "1.2.1", + "cliui": "2.1.0", + "decamelize": "1.2.0", + "window-size": "0.1.0" + } } } }, + "jest-changed-files": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-changed-files/-/jest-changed-files-23.2.0.tgz", + "integrity": "sha1-oUWm5LZtASn8fJnO4TTck3pkPZw=", + "dev": true, + "requires": { + "throat": "4.1.0" + } + }, "jest-cli": { - "version": "12.0.2", - "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-12.0.2.tgz", - "integrity": "sha1-WVUtFGwcCg++cpubLTUbehMwj40=", + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-23.3.0.tgz", + "integrity": "sha1-MH6b53M0Q7eJqCedaUBU0FGp5eI=", "dev": true, "requires": { - "chalk": "1.1.1", - "cover": "0.2.9", - "diff": "2.2.3", + "ansi-escapes": "3.1.0", + "chalk": "2.4.1", + "exit": "0.1.2", + "glob": "7.1.2", "graceful-fs": "4.1.11", - "istanbul": "0.4.5", - "jest-environment-jsdom": "12.1.0", - "jest-environment-node": "12.1.0", - "jest-haste-map": "12.1.0", - "jest-jasmine1": "12.1.0", - "jest-jasmine2": "12.1.0", - "jest-mock": "12.1.0", - "jest-util": "12.1.0", - "json-stable-stringify": "1.0.1", - "lodash.template": "4.4.0", - "mkdirp": "0.5.1", - "optimist": "0.6.1", - "resolve": "1.8.1", - "sane": "1.7.0", + "import-local": "1.0.0", + "is-ci": "1.1.0", + "istanbul-api": "1.3.1", + "istanbul-lib-coverage": "1.2.0", + "istanbul-lib-instrument": "1.10.1", + "istanbul-lib-source-maps": "1.2.5", + "jest-changed-files": "23.2.0", + "jest-config": "23.3.0", + "jest-environment-jsdom": "23.3.0", + "jest-get-type": "22.4.3", + "jest-haste-map": "23.2.0", + "jest-message-util": "23.3.0", + "jest-regex-util": "23.3.0", + "jest-resolve-dependencies": "23.3.0", + "jest-runner": "23.3.0", + "jest-runtime": "23.3.0", + "jest-snapshot": "23.3.0", + "jest-util": "23.3.0", + "jest-validate": "23.3.0", + "jest-watcher": "23.2.0", + "jest-worker": "23.2.0", + "micromatch": "3.1.10", + "node-notifier": "5.2.1", + "prompts": "0.1.10", + "realpath-native": "1.0.1", + "rimraf": "2.6.2", + "slash": "1.0.0", + "string-length": "2.0.0", + "strip-ansi": "4.0.0", "which": "1.3.1", - "worker-farm": "1.6.0" + "yargs": "11.1.0" }, "dependencies": { - "lodash.template": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/lodash.template/-/lodash.template-4.4.0.tgz", - "integrity": "sha1-5zoDhcg1VZF0bgILmWecaQ5o+6A=", + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "lodash._reinterpolate": "3.0.0", - "lodash.templatesettings": "4.1.0" + "color-convert": "1.9.2" } }, - "lodash.templatesettings": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/lodash.templatesettings/-/lodash.templatesettings-4.1.0.tgz", - "integrity": "sha1-K01OlbpEDZFf8IvImeRVNmZxMxY=", + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", + "dev": true + }, + "array-unique": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=", + "dev": true + }, + "braces": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", + "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", "dev": true, "requires": { - "lodash._reinterpolate": "3.0.0" - } - } + "arr-flatten": "1.1.0", + "array-unique": "0.3.2", + "extend-shallow": "2.0.1", + "fill-range": "4.0.0", + "isobject": "3.0.1", + "repeat-element": "1.1.2", + "snapdragon": "0.8.2", + "snapdragon-node": "2.1.1", + "split-string": "3.1.0", + "to-regex": "3.0.2" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, + "expand-brackets": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", + "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", + "dev": true, + "requires": { + "debug": "2.6.9", + "define-property": "0.2.5", + "extend-shallow": "2.0.1", + "posix-character-classes": "0.1.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "dev": true, + "requires": { + "is-descriptor": "0.1.6" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==", + "dev": true + } + } + }, + "extglob": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", + "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", + "dev": true, + "requires": { + "array-unique": "0.3.2", + "define-property": "1.0.0", + "expand-brackets": "2.1.4", + "extend-shallow": "2.0.1", + "fragment-cache": "0.2.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "dev": true, + "requires": { + "is-descriptor": "1.0.2" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "fill-range": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", + "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", + "dev": true, + "requires": { + "extend-shallow": "2.0.1", + "is-number": "3.0.0", + "repeat-string": "1.6.1", + "to-regex-range": "2.1.1" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "dev": true, + "requires": { + "kind-of": "6.0.2" + } + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "dev": true, + "requires": { + "kind-of": "6.0.2" + } + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "1.0.0", + "is-data-descriptor": "1.0.0", + "kind-of": "6.0.2" + } + }, + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=", + "dev": true + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==", + "dev": true + }, + "micromatch": { + "version": "3.1.10", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", + "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", + "dev": true, + "requires": { + "arr-diff": "4.0.0", + "array-unique": "0.3.2", + "braces": "2.3.2", + "define-property": "2.0.2", + "extend-shallow": "3.0.2", + "extglob": "2.0.4", + "fragment-cache": "0.2.1", + "kind-of": "6.0.2", + "nanomatch": "1.2.13", + "object.pick": "1.3.0", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + } + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "dev": true, + "requires": { + "ansi-regex": "3.0.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } + } + }, + "jest-config": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-23.3.0.tgz", + "integrity": "sha1-u01Ttw+VAPr933GNImq7U7E7gyM=", + "dev": true, + "requires": { + "babel-core": "6.26.3", + "babel-jest": "23.2.0", + "chalk": "2.4.1", + "glob": "7.1.2", + "jest-environment-jsdom": "23.3.0", + "jest-environment-node": "23.3.0", + "jest-get-type": "22.4.3", + "jest-jasmine2": "23.3.0", + "jest-regex-util": "23.3.0", + "jest-resolve": "23.2.0", + "jest-util": "23.3.0", + "jest-validate": "23.3.0", + "pretty-format": "23.2.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } + } + }, + "jest-diff": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-23.2.0.tgz", + "integrity": "sha1-nyz0tR4Sx5FVAgCrwWtHEwrxBio=", + "dev": true, + "requires": { + "chalk": "2.4.1", + "diff": "3.5.0", + "jest-get-type": "22.4.3", + "pretty-format": "23.2.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } + } + }, + "jest-docblock": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-23.2.0.tgz", + "integrity": "sha1-8IXh8YVI2Z/dabICB+b9VdkTg6c=", + "dev": true, + "requires": { + "detect-newline": "2.1.0" + } + }, + "jest-each": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-23.2.0.tgz", + "integrity": "sha1-pAD4HIVwg/UMT1M5mxCfEgI/sZ0=", + "dev": true, + "requires": { + "chalk": "2.4.1", + "pretty-format": "23.2.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } + } + }, + "jest-environment-jsdom": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-environment-jsdom/-/jest-environment-jsdom-23.3.0.tgz", + "integrity": "sha1-GQRX+RyeYVRUxBhgVgZdtu16Tio=", + "dev": true, + "requires": { + "jest-mock": "23.2.0", + "jest-util": "23.3.0", + "jsdom": "11.11.0" + } + }, + "jest-environment-node": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-23.3.0.tgz", + "integrity": "sha1-Ho3yHIR6pdA7dlc/DcFvzeUDTDI=", + "dev": true, + "requires": { + "jest-mock": "23.2.0", + "jest-util": "23.3.0" + } + }, + "jest-get-type": { + "version": "22.4.3", + "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-22.4.3.tgz", + "integrity": "sha512-/jsz0Y+V29w1chdXVygEKSz2nBoHoYqNShPe+QgxSNjAuP1i8+k4LbQNrfoliKej0P45sivkSCh7yiD6ubHS3w==", + "dev": true + }, + "jest-haste-map": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-haste-map/-/jest-haste-map-23.2.0.tgz", + "integrity": "sha1-0Qy6wAfGlZSMjvGCGisu0tTy1Ng=", + "dev": true, + "requires": { + "fb-watchman": "2.0.0", + "graceful-fs": "4.1.11", + "jest-docblock": "23.2.0", + "jest-serializer": "23.0.1", + "jest-worker": "23.2.0", + "micromatch": "3.1.10", + "sane": "2.5.2" + }, + "dependencies": { + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", + "dev": true + }, + "array-unique": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=", + "dev": true + }, + "braces": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", + "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", + "dev": true, + "requires": { + "arr-flatten": "1.1.0", + "array-unique": "0.3.2", + "extend-shallow": "2.0.1", + "fill-range": "4.0.0", + "isobject": "3.0.1", + "repeat-element": "1.1.2", + "snapdragon": "0.8.2", + "snapdragon-node": "2.1.1", + "split-string": "3.1.0", + "to-regex": "3.0.2" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, + "expand-brackets": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", + "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", + "dev": true, + "requires": { + "debug": "2.6.9", + "define-property": "0.2.5", + "extend-shallow": "2.0.1", + "posix-character-classes": "0.1.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "dev": true, + "requires": { + "is-descriptor": "0.1.6" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==", + "dev": true + } + } + }, + "extglob": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", + "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", + "dev": true, + "requires": { + "array-unique": "0.3.2", + "define-property": "1.0.0", + "expand-brackets": "2.1.4", + "extend-shallow": "2.0.1", + "fragment-cache": "0.2.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "dev": true, + "requires": { + "is-descriptor": "1.0.2" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "fill-range": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", + "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", + "dev": true, + "requires": { + "extend-shallow": "2.0.1", + "is-number": "3.0.0", + "repeat-string": "1.6.1", + "to-regex-range": "2.1.1" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "dev": true, + "requires": { + "kind-of": "6.0.2" + } + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "dev": true, + "requires": { + "kind-of": "6.0.2" + } + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "1.0.0", + "is-data-descriptor": "1.0.0", + "kind-of": "6.0.2" + } + }, + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=", + "dev": true + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==", + "dev": true + }, + "micromatch": { + "version": "3.1.10", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", + "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", + "dev": true, + "requires": { + "arr-diff": "4.0.0", + "array-unique": "0.3.2", + "braces": "2.3.2", + "define-property": "2.0.2", + "extend-shallow": "3.0.2", + "extglob": "2.0.4", + "fragment-cache": "0.2.1", + "kind-of": "6.0.2", + "nanomatch": "1.2.13", + "object.pick": "1.3.0", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + } + } + } + }, + "jest-jasmine2": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-jasmine2/-/jest-jasmine2-23.3.0.tgz", + "integrity": "sha1-qHBrqsI8ihMNWqjvVGSp1JCW0bU=", + "dev": true, + "requires": { + "chalk": "2.4.1", + "co": "4.6.0", + "expect": "23.3.0", + "is-generator-fn": "1.0.0", + "jest-diff": "23.2.0", + "jest-each": "23.2.0", + "jest-matcher-utils": "23.2.0", + "jest-message-util": "23.3.0", + "jest-snapshot": "23.3.0", + "jest-util": "23.3.0", + "pretty-format": "23.2.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } + } + }, + "jest-leak-detector": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-23.2.0.tgz", + "integrity": "sha1-wonZYdxjjxQ1fU75bgQx7MGqN30=", + "dev": true, + "requires": { + "pretty-format": "23.2.0" + } + }, + "jest-matcher-utils": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-23.2.0.tgz", + "integrity": "sha1-TUmB8jIT6Tnjzt8j3DTHR7WuGRM=", + "dev": true, + "requires": { + "chalk": "2.4.1", + "jest-get-type": "22.4.3", + "pretty-format": "23.2.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } + } + }, + "jest-message-util": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-23.3.0.tgz", + "integrity": "sha1-vAexHOxpcftd2d4t+2DrwiFQwWA=", + "dev": true, + "requires": { + "@babel/code-frame": "7.0.0-beta.44", + "chalk": "2.4.1", + "micromatch": "3.1.10", + "slash": "1.0.0", + "stack-utils": "1.0.1" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", + "dev": true + }, + "array-unique": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=", + "dev": true + }, + "braces": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", + "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", + "dev": true, + "requires": { + "arr-flatten": "1.1.0", + "array-unique": "0.3.2", + "extend-shallow": "2.0.1", + "fill-range": "4.0.0", + "isobject": "3.0.1", + "repeat-element": "1.1.2", + "snapdragon": "0.8.2", + "snapdragon-node": "2.1.1", + "split-string": "3.1.0", + "to-regex": "3.0.2" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, + "expand-brackets": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", + "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", + "dev": true, + "requires": { + "debug": "2.6.9", + "define-property": "0.2.5", + "extend-shallow": "2.0.1", + "posix-character-classes": "0.1.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "dev": true, + "requires": { + "is-descriptor": "0.1.6" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==", + "dev": true + } + } + }, + "extglob": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", + "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", + "dev": true, + "requires": { + "array-unique": "0.3.2", + "define-property": "1.0.0", + "expand-brackets": "2.1.4", + "extend-shallow": "2.0.1", + "fragment-cache": "0.2.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "dev": true, + "requires": { + "is-descriptor": "1.0.2" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "fill-range": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", + "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", + "dev": true, + "requires": { + "extend-shallow": "2.0.1", + "is-number": "3.0.0", + "repeat-string": "1.6.1", + "to-regex-range": "2.1.1" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "dev": true, + "requires": { + "kind-of": "6.0.2" + } + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "dev": true, + "requires": { + "kind-of": "6.0.2" + } + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "1.0.0", + "is-data-descriptor": "1.0.0", + "kind-of": "6.0.2" + } + }, + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=", + "dev": true + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==", + "dev": true + }, + "micromatch": { + "version": "3.1.10", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", + "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", + "dev": true, + "requires": { + "arr-diff": "4.0.0", + "array-unique": "0.3.2", + "braces": "2.3.2", + "define-property": "2.0.2", + "extend-shallow": "3.0.2", + "extglob": "2.0.4", + "fragment-cache": "0.2.1", + "kind-of": "6.0.2", + "nanomatch": "1.2.13", + "object.pick": "1.3.0", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } + } + }, + "jest-mock": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-23.2.0.tgz", + "integrity": "sha1-rRxg8p6HGdR8JuETgJi20YsmETQ=", + "dev": true + }, + "jest-regex-util": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-23.3.0.tgz", + "integrity": "sha1-X4ZylUfCeFxAAs6qj4Sf6MpHG8U=", + "dev": true + }, + "jest-resolve": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-resolve/-/jest-resolve-23.2.0.tgz", + "integrity": "sha1-oHkK1aO5kAKrTb/L+Nni1qabPZk=", + "dev": true, + "requires": { + "browser-resolve": "1.11.3", + "chalk": "2.4.1", + "realpath-native": "1.0.1" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } + } + }, + "jest-resolve-dependencies": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-resolve-dependencies/-/jest-resolve-dependencies-23.3.0.tgz", + "integrity": "sha1-hETTsLEoi4CGTYgB/1C0Sk1pXR0=", + "dev": true, + "requires": { + "jest-regex-util": "23.3.0", + "jest-snapshot": "23.3.0" + } + }, + "jest-runner": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-23.3.0.tgz", + "integrity": "sha1-BMfkWKYXUBpIddsNf/vg48vUO/s=", + "dev": true, + "requires": { + "exit": "0.1.2", + "graceful-fs": "4.1.11", + "jest-config": "23.3.0", + "jest-docblock": "23.2.0", + "jest-haste-map": "23.2.0", + "jest-jasmine2": "23.3.0", + "jest-leak-detector": "23.2.0", + "jest-message-util": "23.3.0", + "jest-runtime": "23.3.0", + "jest-util": "23.3.0", + "jest-worker": "23.2.0", + "source-map-support": "0.5.6", + "throat": "4.1.0" + }, + "dependencies": { + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true + }, + "source-map-support": { + "version": "0.5.6", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.6.tgz", + "integrity": "sha512-N4KXEz7jcKqPf2b2vZF11lQIz9W5ZMuUcIOGj243lduidkf2fjkVKJS9vNxVWn3u/uxX38AcE8U9nnH9FPcq+g==", + "dev": true, + "requires": { + "buffer-from": "1.1.0", + "source-map": "0.6.1" + } + } + } + }, + "jest-runtime": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-23.3.0.tgz", + "integrity": "sha1-SGWqtM7/gvnOxjNf164UIswd598=", + "dev": true, + "requires": { + "babel-core": "6.26.3", + "babel-plugin-istanbul": "4.1.6", + "chalk": "2.4.1", + "convert-source-map": "1.5.1", + "exit": "0.1.2", + "fast-json-stable-stringify": "2.0.0", + "graceful-fs": "4.1.11", + "jest-config": "23.3.0", + "jest-haste-map": "23.2.0", + "jest-message-util": "23.3.0", + "jest-regex-util": "23.3.0", + "jest-resolve": "23.2.0", + "jest-snapshot": "23.3.0", + "jest-util": "23.3.0", + "jest-validate": "23.3.0", + "micromatch": "3.1.10", + "realpath-native": "1.0.1", + "slash": "1.0.0", + "strip-bom": "3.0.0", + "write-file-atomic": "2.3.0", + "yargs": "11.1.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", + "dev": true + }, + "array-unique": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=", + "dev": true + }, + "braces": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", + "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", + "dev": true, + "requires": { + "arr-flatten": "1.1.0", + "array-unique": "0.3.2", + "extend-shallow": "2.0.1", + "fill-range": "4.0.0", + "isobject": "3.0.1", + "repeat-element": "1.1.2", + "snapdragon": "0.8.2", + "snapdragon-node": "2.1.1", + "split-string": "3.1.0", + "to-regex": "3.0.2" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, + "expand-brackets": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", + "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", + "dev": true, + "requires": { + "debug": "2.6.9", + "define-property": "0.2.5", + "extend-shallow": "2.0.1", + "posix-character-classes": "0.1.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "dev": true, + "requires": { + "is-descriptor": "0.1.6" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==", + "dev": true + } + } + }, + "extglob": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", + "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", + "dev": true, + "requires": { + "array-unique": "0.3.2", + "define-property": "1.0.0", + "expand-brackets": "2.1.4", + "extend-shallow": "2.0.1", + "fragment-cache": "0.2.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "dev": true, + "requires": { + "is-descriptor": "1.0.2" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "fill-range": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", + "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", + "dev": true, + "requires": { + "extend-shallow": "2.0.1", + "is-number": "3.0.0", + "repeat-string": "1.6.1", + "to-regex-range": "2.1.1" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "dev": true, + "requires": { + "kind-of": "6.0.2" + } + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "dev": true, + "requires": { + "kind-of": "6.0.2" + } + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "1.0.0", + "is-data-descriptor": "1.0.0", + "kind-of": "6.0.2" + } + }, + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=", + "dev": true + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==", + "dev": true + }, + "micromatch": { + "version": "3.1.10", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", + "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", + "dev": true, + "requires": { + "arr-diff": "4.0.0", + "array-unique": "0.3.2", + "braces": "2.3.2", + "define-property": "2.0.2", + "extend-shallow": "3.0.2", + "extglob": "2.0.4", + "fragment-cache": "0.2.1", + "kind-of": "6.0.2", + "nanomatch": "1.2.13", + "object.pick": "1.3.0", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + } + }, + "strip-bom": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", + "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=", + "dev": true + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } } }, - "jest-environment-jsdom": { - "version": "12.1.0", - "resolved": "https://registry.npmjs.org/jest-environment-jsdom/-/jest-environment-jsdom-12.1.0.tgz", - "integrity": "sha1-1jCmGpAO+yqJnfsNkjOprm7bpR4=", - "dev": true, - "requires": { - "jest-util": "12.1.0", - "jsdom": "9.12.0" - } + "jest-serializer": { + "version": "23.0.1", + "resolved": "https://registry.npmjs.org/jest-serializer/-/jest-serializer-23.0.1.tgz", + "integrity": "sha1-o3dq6zEekP6D+rnlM+hRAr0WQWU=", + "dev": true }, - "jest-environment-node": { - "version": "12.1.0", - "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-12.1.0.tgz", - "integrity": "sha1-+BiQ+JX16fw912UCSKNfJQLCQzM=", + "jest-snapshot": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-23.3.0.tgz", + "integrity": "sha1-/E6fgeRUMtEFB+J/ULzmD0TYFCQ=", "dev": true, "requires": { - "jest-util": "12.1.0" + "babel-traverse": "6.26.0", + "babel-types": "6.26.0", + "chalk": "2.4.1", + "jest-diff": "23.2.0", + "jest-matcher-utils": "23.2.0", + "jest-message-util": "23.3.0", + "jest-resolve": "23.2.0", + "mkdirp": "0.5.1", + "natural-compare": "1.4.0", + "pretty-format": "23.2.0", + "semver": "5.5.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } } }, - "jest-haste-map": { - "version": "12.1.0", - "resolved": "https://registry.npmjs.org/jest-haste-map/-/jest-haste-map-12.1.0.tgz", - "integrity": "sha1-4m/vm4CkORFFMx9ks/li7P+yEi8=", + "jest-util": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-23.3.0.tgz", + "integrity": "sha1-efNbsMMBAO9hHZY+5riPjthzqB0=", "dev": true, "requires": { - "fb-watchman": "1.9.2", + "callsites": "2.0.0", + "chalk": "2.4.1", "graceful-fs": "4.1.11", - "worker-farm": "1.6.0" + "is-ci": "1.1.0", + "jest-message-util": "23.3.0", + "mkdirp": "0.5.1", + "slash": "1.0.0", + "source-map": "0.6.1" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "callsites": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/callsites/-/callsites-2.0.0.tgz", + "integrity": "sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA=", + "dev": true + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } } }, - "jest-jasmine1": { - "version": "12.1.0", - "resolved": "https://registry.npmjs.org/jest-jasmine1/-/jest-jasmine1-12.1.0.tgz", - "integrity": "sha1-BAkETQOE7HZeiivDj9eNtfbFW/8=", + "jest-validate": { + "version": "23.3.0", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-23.3.0.tgz", + "integrity": "sha1-1Jvqaq2YwwrNLLtUJDR5igzBP3Y=", "dev": true, "requires": { - "graceful-fs": "4.1.11", - "jest-util": "12.1.0" + "chalk": "2.4.1", + "jest-get-type": "22.4.3", + "leven": "2.1.0", + "pretty-format": "23.2.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "leven": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/leven/-/leven-2.1.0.tgz", + "integrity": "sha1-wuep93IJTe6dNCAq6KzORoeHVYA=", + "dev": true + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } } }, - "jest-jasmine2": { - "version": "12.1.0", - "resolved": "https://registry.npmjs.org/jest-jasmine2/-/jest-jasmine2-12.1.0.tgz", - "integrity": "sha1-IpwezDbQTXHVOLwBM8cdhwdxEus=", + "jest-watcher": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-23.2.0.tgz", + "integrity": "sha1-Z46FKJbpGenZoOtLi68a4nliDqk=", "dev": true, "requires": { - "graceful-fs": "4.1.11", - "jest-util": "12.1.0" + "ansi-escapes": "3.1.0", + "chalk": "2.4.1", + "string-length": "2.0.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" + } + }, + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", + "dev": true, + "requires": { + "has-flag": "3.0.0" + } + } } }, - "jest-mock": { - "version": "12.1.0", - "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-12.1.0.tgz", - "integrity": "sha1-RyuJYpT3uR4j3N28ts+j5uSygEk=", - "dev": true - }, - "jest-util": { - "version": "12.1.0", - "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-12.1.0.tgz", - "integrity": "sha1-PTZz6B8X4OyWfp3ceFFgpRq57BI=", + "jest-worker": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-23.2.0.tgz", + "integrity": "sha1-+vcGqNo2+uYOsmlXJX+ntdjqArk=", "dev": true, "requires": { - "chalk": "1.1.1", - "diff": "2.2.3", - "graceful-fs": "4.1.11", - "jest-mock": "12.1.0", - "mkdirp": "0.5.1" + "merge-stream": "1.0.1" } }, "js-tokens": { @@ -6327,6 +8759,21 @@ "underscore": "1.8.3" }, "dependencies": { + "acorn": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-3.3.0.tgz", + "integrity": "sha1-ReN/s56No/JbruP/U2niu18iAXo=", + "dev": true + }, + "acorn-jsx": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-3.0.1.tgz", + "integrity": "sha1-r9+UiPsezvyDSPb7IvRk4ypYs2s=", + "dev": true, + "requires": { + "acorn": "3.3.0" + } + }, "bluebird": { "version": "3.4.7", "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.4.7.tgz", @@ -6343,10 +8790,10 @@ "acorn-jsx": "3.0.1" } }, - "strip-json-comments": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", - "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", + "underscore": { + "version": "1.8.3", + "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.8.3.tgz", + "integrity": "sha1-Tz+1OxBuYJf8+ctBCfKl6b36UCI=", "dev": true } } @@ -6498,6 +8945,15 @@ "once": "1.4.0" } }, + "minimatch": { + "version": "2.0.10", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-2.0.10.tgz", + "integrity": "sha1-jQh8OcazjAAbl/ynzm0OHoCvusc=", + "dev": true, + "requires": { + "brace-expansion": "1.1.11" + } + }, "test-value": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/test-value/-/test-value-1.1.0.tgz", @@ -6548,37 +9004,48 @@ } }, "jsdom": { - "version": "9.12.0", - "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-9.12.0.tgz", - "integrity": "sha1-6MVG//ywbADUgzyoRBD+1/igl9Q=", + "version": "11.11.0", + "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-11.11.0.tgz", + "integrity": "sha512-ou1VyfjwsSuWkudGxb03FotDajxAto6USAlmMZjE2lc0jCznt7sBWkhfRBRaWwbnmDqdMSTKTLT5d9sBFkkM7A==", "dev": true, "requires": { "abab": "1.0.4", - "acorn": "4.0.13", - "acorn-globals": "3.1.0", + "acorn": "5.7.1", + "acorn-globals": "4.1.0", "array-equal": "1.0.0", - "content-type-parser": "1.0.2", "cssom": "0.3.4", - "cssstyle": "0.2.37", - "escodegen": "1.8.1", + "cssstyle": "0.3.1", + "data-urls": "1.0.0", + "domexception": "1.0.1", + "escodegen": "1.10.0", "html-encoding-sniffer": "1.0.2", - "nwmatcher": "1.4.4", - "parse5": "1.5.1", + "left-pad": "1.3.0", + "nwsapi": "2.0.4", + "parse5": "4.0.0", + "pn": "1.1.0", "request": "2.87.0", + "request-promise-native": "1.0.5", "sax": "1.2.4", "symbol-tree": "3.2.2", - "tough-cookie": "2.3.4", + "tough-cookie": "2.4.3", + "w3c-hr-time": "1.0.1", "webidl-conversions": "4.0.2", "whatwg-encoding": "1.0.3", - "whatwg-url": "4.8.0", - "xml-name-validator": "2.0.1" + "whatwg-mimetype": "2.1.0", + "whatwg-url": "6.5.0", + "ws": "4.1.0", + "xml-name-validator": "3.0.0" }, "dependencies": { - "acorn": { - "version": "4.0.13", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-4.0.13.tgz", - "integrity": "sha1-EFSVrlNh1pe9GVyCUZLhrX8lN4c=", - "dev": true + "ws": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-4.1.0.tgz", + "integrity": "sha512-ZGh/8kF9rrRNffkLFV4AzhvooEclrOH0xaugmqGsIfFgOE/pIz4fMc4Ef+5HSQqTEug2S9JZIWDR47duDSLfaA==", + "dev": true, + "requires": { + "async-limiter": "1.0.0", + "safe-buffer": "5.1.2" + } } } }, @@ -6589,9 +9056,9 @@ "dev": true }, "json-loader": { - "version": "0.5.2", - "resolved": "https://registry.npmjs.org/json-loader/-/json-loader-0.5.2.tgz", - "integrity": "sha1-7XkBnE83eEIuzNYkJ+tSZhLG70A=", + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/json-loader/-/json-loader-0.5.7.tgz", + "integrity": "sha512-QLPs8Dj7lnf3e3QYS1zkCo+4ZwqOiF9d/nZnYozTISxXWCfNs9yuky5rJw4/W34s7POaNlbZmQGaB5NiXCbP4w==", "dev": true }, "json-schema": { @@ -6601,20 +9068,25 @@ "dev": true }, "json-schema-traverse": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz", - "integrity": "sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A=", + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", + "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", "dev": true }, "json-stable-stringify": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz", "integrity": "sha1-mnWdOcXy/1A/1TAGRu1EX4jE+a8=", - "dev": true, "requires": { "jsonify": "0.0.0" } }, + "json-stable-stringify-without-jsonify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", + "integrity": "sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=", + "dev": true + }, "json-stringify-safe": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", @@ -6628,22 +9100,15 @@ "dev": true }, "json5": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/json5/-/json5-0.4.0.tgz", - "integrity": "sha1-BUNS5MTIDIbAkjh31EneF2pzLI0=", + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/json5/-/json5-0.5.1.tgz", + "integrity": "sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE=", "dev": true }, "jsonify": { "version": "0.0.0", "resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.0.tgz", - "integrity": "sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM=", - "dev": true - }, - "jsonpointer": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/jsonpointer/-/jsonpointer-4.0.1.tgz", - "integrity": "sha1-T9kss04OnbPInIYi7PUfm5eMbLk=", - "dev": true + "integrity": "sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM=" }, "jsprim": { "version": "1.4.1", @@ -6657,6 +9122,15 @@ "verror": "1.10.0" } }, + "jsx-ast-utils": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/jsx-ast-utils/-/jsx-ast-utils-2.0.1.tgz", + "integrity": "sha1-6AGxs5mF4g//yHtA43SAgOLcrH8=", + "dev": true, + "requires": { + "array-includes": "3.0.3" + } + }, "kind-of": { "version": "3.2.2", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", @@ -6681,6 +9155,21 @@ "integrity": "sha1-odePw6UEdMuAhF07O24dpJpEbo4=", "dev": true }, + "lcid": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/lcid/-/lcid-1.0.0.tgz", + "integrity": "sha1-MIrMr6C8SDo4Z7S28rlQYlHRuDU=", + "dev": true, + "requires": { + "invert-kv": "1.0.0" + } + }, + "left-pad": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/left-pad/-/left-pad-1.3.0.tgz", + "integrity": "sha512-XI5MPzVNApjAyhQzphX8BkmKsKUxD4LdyK24iZeQGinBN9yTQT3bFlCBy/aVx2HrNcqQGsdot8ghrjyrvMCoEA==", + "dev": true + }, "leven": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/leven/-/leven-1.0.2.tgz", @@ -6725,30 +9214,82 @@ "strip-bom": "2.0.0" } }, - "loader-utils": { - "version": "0.2.17", - "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-0.2.17.tgz", - "integrity": "sha1-+G5jdNQyBabmxg6RlvF8Apm/s0g=", + "loader-fs-cache": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/loader-fs-cache/-/loader-fs-cache-1.0.1.tgz", + "integrity": "sha1-VuC/CL2XCLJqdltoUJhAyN7J/bw=", "dev": true, "requires": { - "big.js": "3.2.0", - "emojis-list": "2.1.0", - "json5": "0.5.1", - "object-assign": "4.1.1" + "find-cache-dir": "0.1.1", + "mkdirp": "0.5.1" }, "dependencies": { - "json5": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/json5/-/json5-0.5.1.tgz", - "integrity": "sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE=", - "dev": true + "find-cache-dir": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-0.1.1.tgz", + "integrity": "sha1-yN765XyKUqinhPnjHFfHQumToLk=", + "dev": true, + "requires": { + "commondir": "1.0.1", + "mkdirp": "0.5.1", + "pkg-dir": "1.0.0" + } + }, + "find-up": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz", + "integrity": "sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8=", + "dev": true, + "requires": { + "path-exists": "2.1.0", + "pinkie-promise": "2.0.1" + } + }, + "path-exists": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz", + "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=", + "dev": true, + "requires": { + "pinkie-promise": "2.0.1" + } + }, + "pkg-dir": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-1.0.0.tgz", + "integrity": "sha1-ektQio1bstYp1EcFb/TpyTFM89Q=", + "dev": true, + "requires": { + "find-up": "1.1.2" + } } } }, + "loader-utils": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-1.1.0.tgz", + "integrity": "sha1-yYrvSIvM7aL/teLeZG1qdUQp9c0=", + "dev": true, + "requires": { + "big.js": "3.2.0", + "emojis-list": "2.1.0", + "json5": "0.5.1" + } + }, + "locate-path": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz", + "integrity": "sha1-K1aLJl7slExtnA3pw9u7ygNUzY4=", + "dev": true, + "requires": { + "p-locate": "2.0.0", + "path-exists": "3.0.0" + } + }, "lodash": { - "version": "4.11.2", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.11.2.tgz", - "integrity": "sha1-1rQzixEKWOIdrlzrz9u/0rxM2zs=" + "version": "4.17.10", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", + "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==" }, "lodash._basecopy": { "version": "3.0.1", @@ -6804,24 +9345,6 @@ "integrity": "sha1-+6HEUkwZ7ppfgTa0YJ8BfPTe1pI=", "dev": true }, - "lodash.assign": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/lodash.assign/-/lodash.assign-4.2.0.tgz", - "integrity": "sha1-DZnzzNem0mHRm9rrkkUAXShYCOc=", - "dev": true - }, - "lodash.cond": { - "version": "4.5.2", - "resolved": "https://registry.npmjs.org/lodash.cond/-/lodash.cond-4.5.2.tgz", - "integrity": "sha1-9HGh2khr5g9quVXRcRVSPdHSVdU=", - "dev": true - }, - "lodash.endswith": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/lodash.endswith/-/lodash.endswith-4.2.1.tgz", - "integrity": "sha1-/tWawXOO0+I27dcGTsRWRIs3vAk=", - "dev": true - }, "lodash.escape": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/lodash.escape/-/lodash.escape-3.2.0.tgz", @@ -6831,12 +9354,6 @@ "lodash._root": "3.0.1" } }, - "lodash.find": { - "version": "4.6.0", - "resolved": "https://registry.npmjs.org/lodash.find/-/lodash.find-4.6.0.tgz", - "integrity": "sha1-ywcE1Hq3F4n/oN6Ll92Sb7iLE7E=", - "dev": true - }, "lodash.isarguments": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/lodash.isarguments/-/lodash.isarguments-3.1.0.tgz", @@ -6866,18 +9383,18 @@ "integrity": "sha1-UvBWEP/53tQiYRRB7R/BI6AwAbM=", "dev": true }, - "lodash.pickby": { - "version": "4.6.0", - "resolved": "https://registry.npmjs.org/lodash.pickby/-/lodash.pickby-4.6.0.tgz", - "integrity": "sha1-feoh2MGNdwOifHBMFdO4SmfjOv8=", - "dev": true - }, "lodash.restparam": { "version": "3.6.1", "resolved": "https://registry.npmjs.org/lodash.restparam/-/lodash.restparam-3.6.1.tgz", "integrity": "sha1-k2pOMJ7zMKdkXtQUWYbIWuWyCAU=", "dev": true }, + "lodash.sortby": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash.sortby/-/lodash.sortby-4.7.0.tgz", + "integrity": "sha1-7dFMgk4sycHgsKG0K7UhBRakJDg=", + "dev": true + }, "lodash.template": { "version": "3.6.2", "resolved": "https://registry.npmjs.org/lodash.template/-/lodash.template-3.6.2.tgz", @@ -6905,15 +9422,6 @@ "lodash.escape": "3.2.0" } }, - "log-symbols": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-1.0.2.tgz", - "integrity": "sha1-N2/3tY6jCGoPCfrMdGF+ylAeGhg=", - "dev": true, - "requires": { - "chalk": "1.1.1" - } - }, "longest": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/longest/-/longest-1.0.1.tgz", @@ -6929,22 +9437,38 @@ "js-tokens": "3.0.2" } }, - "loud-rejection": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/loud-rejection/-/loud-rejection-1.6.0.tgz", - "integrity": "sha1-W0b4AUft7leIcPCG0Eghz5mOVR8=", - "dev": true, - "requires": { - "currently-unhandled": "0.4.1", - "signal-exit": "3.0.2" - } - }, "lru-cache": { "version": "2.7.3", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-2.7.3.tgz", "integrity": "sha1-bUUk6LlV+V1PW1iFHOId1y+06VI=", "dev": true }, + "lru-queue": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/lru-queue/-/lru-queue-0.1.0.tgz", + "integrity": "sha1-Jzi9nw089PhEkMVzbEhpmsYyzaM=", + "dev": true, + "requires": { + "es5-ext": "0.10.45" + } + }, + "make-dir": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-1.3.0.tgz", + "integrity": "sha512-2w31R7SJtieJJnQtGc7RVL2StM2vGYVfqUOvUDxH6bC6aJTxPxTF0GnIgCyu7tjockiUWAYQRbxa7vKn34s5sQ==", + "dev": true, + "requires": { + "pify": "3.0.0" + }, + "dependencies": { + "pify": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", + "integrity": "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=", + "dev": true + } + } + }, "make-iterator": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/make-iterator/-/make-iterator-1.0.1.tgz", @@ -6977,12 +9501,6 @@ "integrity": "sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8=", "dev": true }, - "map-obj": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-1.0.1.tgz", - "integrity": "sha1-2TPOuSBdgr3PSIb2dCvcK03qFG0=", - "dev": true - }, "map-visit": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/map-visit/-/map-visit-1.0.0.tgz", @@ -7020,6 +9538,31 @@ "integrity": "sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g=", "dev": true }, + "mem": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/mem/-/mem-1.1.0.tgz", + "integrity": "sha1-Xt1StIXKHZAP5kiVUFOZoN+kX3Y=", + "dev": true, + "requires": { + "mimic-fn": "1.2.0" + } + }, + "memoizee": { + "version": "0.4.12", + "resolved": "https://registry.npmjs.org/memoizee/-/memoizee-0.4.12.tgz", + "integrity": "sha512-sprBu6nwxBWBvBOh5v2jcsGqiGLlL2xr2dLub3vR8dnE8YB17omwtm/0NSHl8jjNbcsJd5GMWJAnTSVe/O0Wfg==", + "dev": true, + "requires": { + "d": "1.0.0", + "es5-ext": "0.10.45", + "es6-weak-map": "2.0.2", + "event-emitter": "0.3.5", + "is-promise": "2.1.0", + "lru-queue": "0.1.0", + "next-tick": "1.0.0", + "timers-ext": "0.1.5" + } + }, "memory-fs": { "version": "0.3.0", "resolved": "https://registry.npmjs.org/memory-fs/-/memory-fs-0.3.0.tgz", @@ -7062,24 +9605,6 @@ } } }, - "meow": { - "version": "3.7.0", - "resolved": "https://registry.npmjs.org/meow/-/meow-3.7.0.tgz", - "integrity": "sha1-cstmi0JSKCkKu/qFaJJYcwioAfs=", - "dev": true, - "requires": { - "camelcase-keys": "2.1.0", - "decamelize": "1.2.0", - "loud-rejection": "1.6.0", - "map-obj": "1.0.1", - "minimist": "1.2.0", - "normalize-package-data": "2.4.0", - "object-assign": "4.1.1", - "read-pkg-up": "1.0.1", - "redent": "1.0.0", - "trim-newlines": "1.0.0" - } - }, "merge": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/merge/-/merge-1.2.0.tgz", @@ -7092,9 +9617,9 @@ "dev": true }, "merge-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-1.0.0.tgz", - "integrity": "sha1-nP0Vb+81Qh4rVAPOEdxusZYrAm4=", + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-1.0.1.tgz", + "integrity": "sha1-QEEgLVCKNCugAXQAjfDCUbjBNeE=", "dev": true, "requires": { "readable-stream": "2.3.6" @@ -7157,6 +9682,23 @@ "object.omit": "2.0.1", "parse-glob": "3.0.4", "regex-cache": "0.4.4" + }, + "dependencies": { + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", + "dev": true + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "dev": true, + "requires": { + "is-extglob": "1.0.0" + } + } } }, "miller-rabin": { @@ -7190,6 +9732,12 @@ "mime-db": "1.33.0" } }, + "mimic-fn": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-1.2.0.tgz", + "integrity": "sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ==", + "dev": true + }, "minimalistic-assert": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", @@ -7203,10 +9751,9 @@ "dev": true }, "minimatch": { - "version": "2.0.10", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-2.0.10.tgz", - "integrity": "sha1-jQh8OcazjAAbl/ynzm0OHoCvusc=", - "dev": true, + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", "requires": { "brace-expansion": "1.1.11" } @@ -7261,57 +9808,63 @@ "dev": true }, "mqtt": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/mqtt/-/mqtt-1.10.0.tgz", - "integrity": "sha1-DoLqm7PN5rOFyuDCxyimkh0zjHw=", + "version": "2.18.2", + "resolved": "https://registry.npmjs.org/mqtt/-/mqtt-2.18.2.tgz", + "integrity": "sha512-egP6gbLES2aELu6LNtwOtpC779Hu7LVTYm6HKE5wJdTuX2jZ4JOOtK7HS2JWyW6IfKN5U99u/VU155tLwFAKbQ==", "requires": { "commist": "1.0.0", "concat-stream": "1.6.2", "end-of-stream": "1.4.1", - "help-me": "0.1.0", + "help-me": "1.1.0", "inherits": "2.0.3", "minimist": "1.2.0", - "mqtt-connection": "2.1.1", - "mqtt-packet": "3.5.0", - "pump": "1.0.3", - "readable-stream": "1.0.34", + "mqtt-packet": "5.6.0", + "pump": "3.0.0", + "readable-stream": "2.3.6", "reinterval": "1.1.0", "split2": "2.2.0", - "websocket-stream": "3.3.3", + "websocket-stream": "5.1.2", "xtend": "4.0.1" }, "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" + }, "readable-stream": { - "version": "1.0.34", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", - "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", + "version": "2.3.6", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "requires": { "core-util-is": "1.0.2", "inherits": "2.0.3", - "isarray": "0.0.1", - "string_decoder": "0.10.31" + "isarray": "1.0.0", + "process-nextick-args": "2.0.0", + "safe-buffer": "5.1.2", + "string_decoder": "1.1.1", + "util-deprecate": "1.0.2" + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "5.1.2" } } } }, - "mqtt-connection": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/mqtt-connection/-/mqtt-connection-2.1.1.tgz", - "integrity": "sha1-ey6YWnThlmGUML69NdoWLDTE5Wo=", - "requires": { - "inherits": "2.0.3", - "mqtt-packet": "3.5.0", - "reduplexer": "1.1.0", - "through2": "0.6.5" - } - }, "mqtt-packet": { - "version": "3.5.0", - "resolved": "https://registry.npmjs.org/mqtt-packet/-/mqtt-packet-3.5.0.tgz", - "integrity": "sha512-lfeRZ95Mr3fcuYArDUG+bfC6jBQ07dNK3cXAYvN0d4sFttPx4VuizyZwTxkPJvxjJcx8TZZLVUK9gFt5OFcF5g==", + "version": "5.6.0", + "resolved": "https://registry.npmjs.org/mqtt-packet/-/mqtt-packet-5.6.0.tgz", + "integrity": "sha512-QECe2ivqcR1LRsPobRsjenEKAC3i1a5gmm+jNKJLrsiq9PaSQ18LlKFuxvhGxWkvGEPadWv6rKd31O4ICqS1Xw==", "requires": { "bl": "1.2.2", - "inherits": "2.0.3" + "inherits": "2.0.3", + "process-nextick-args": "2.0.0", + "safe-buffer": "5.1.2" } }, "ms": { @@ -7329,9 +9882,9 @@ } }, "mute-stream": { - "version": "0.0.5", - "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.5.tgz", - "integrity": "sha1-j7+rsKmKJT0xhDMfno3rc3L6xsA=", + "version": "0.0.7", + "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.7.tgz", + "integrity": "sha1-MHXOk7whuPq0PhvE2n6BFe0ee6s=", "dev": true }, "nan": { @@ -7385,6 +9938,12 @@ "integrity": "sha512-Q29yeg9aFKwhLVdkTAejM/HvYG0Y1Am1+HUkFQGn5k2j8GS+v60TVmZh6nujpEAj/qql+wGUrlryO8bF+b1jEg==", "dev": true }, + "natural-compare": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", + "integrity": "sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=", + "dev": true + }, "negotiator": { "version": "0.6.1", "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.1.tgz", @@ -7397,6 +9956,12 @@ "integrity": "sha1-yobR/ogoFpsBICCOPchCS524NCw=", "dev": true }, + "nice-try": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.4.tgz", + "integrity": "sha512-2NpiFHqC87y/zFke0fC0spBXL3bBsoh/p5H1EFhshxjCR5+0g2d6BiXbUFz9v1sAcxsk2htp2eQnNIci2dIYcA==", + "dev": true + }, "node-int64": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", @@ -7404,30 +9969,30 @@ "dev": true }, "node-libs-browser": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/node-libs-browser/-/node-libs-browser-1.0.0.tgz", - "integrity": "sha1-/4rWws+ngEO90AkewH8KqlgWIPw=", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/node-libs-browser/-/node-libs-browser-2.1.0.tgz", + "integrity": "sha512-5AzFzdoIMb89hBGMZglEegffzgRg+ZFoUmisQ8HI4j1KDdpx13J0taNp2y9xPbur6W61gepGDDotGBVQ7mfUCg==", "dev": true, "requires": { "assert": "1.4.1", - "browserify-zlib": "0.1.4", + "browserify-zlib": "0.2.0", "buffer": "4.9.1", "console-browserify": "1.1.0", "constants-browserify": "1.0.0", "crypto-browserify": "3.12.0", "domain-browser": "1.2.0", "events": "1.1.1", - "http-browserify": "1.7.0", - "https-browserify": "0.0.1", - "os-browserify": "0.2.1", + "https-browserify": "1.0.0", + "os-browserify": "0.3.0", "path-browserify": "0.0.0", "process": "0.11.10", "punycode": "1.4.1", "querystring-es3": "0.2.1", "readable-stream": "2.3.6", "stream-browserify": "2.0.1", - "string_decoder": "0.10.31", - "timers-browserify": "1.4.2", + "stream-http": "2.8.3", + "string_decoder": "1.1.1", + "timers-browserify": "2.0.10", "tty-browserify": "0.0.0", "url": "0.11.0", "util": "0.10.4", @@ -7440,6 +10005,12 @@ "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", "dev": true }, + "punycode": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", + "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", + "dev": true + }, "readable-stream": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", @@ -7453,28 +10024,29 @@ "safe-buffer": "5.1.2", "string_decoder": "1.1.1", "util-deprecate": "1.0.2" - }, - "dependencies": { - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "requires": { - "safe-buffer": "5.1.2" - } - } + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dev": true, + "requires": { + "safe-buffer": "5.1.2" } } } }, - "nopt": { - "version": "3.0.6", - "resolved": "https://registry.npmjs.org/nopt/-/nopt-3.0.6.tgz", - "integrity": "sha1-xkZdvwirzU2zWTF/eaxopkayj/k=", + "node-notifier": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/node-notifier/-/node-notifier-5.2.1.tgz", + "integrity": "sha512-MIBs+AAd6dJ2SklbbE8RUDRlIVhU8MaNLh1A9SUZDUHPiZkWLFde6UNwG41yQHZEToHgJMXqyVZ9UcS/ReOVTg==", "dev": true, "requires": { - "abbrev": "1.0.9" + "growly": "1.3.0", + "semver": "5.5.0", + "shellwords": "0.1.1", + "which": "1.3.1" } }, "normalize-package-data": { @@ -7485,7 +10057,7 @@ "requires": { "hosted-git-info": "2.6.1", "is-builtin-module": "1.0.0", - "semver": "4.3.6", + "semver": "5.5.0", "validate-npm-package-license": "3.0.3" } }, @@ -7498,16 +10070,25 @@ "remove-trailing-separator": "1.1.0" } }, + "npm-run-path": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz", + "integrity": "sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8=", + "dev": true, + "requires": { + "path-key": "2.0.1" + } + }, "number-is-nan": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", "dev": true }, - "nwmatcher": { - "version": "1.4.4", - "resolved": "https://registry.npmjs.org/nwmatcher/-/nwmatcher-1.4.4.tgz", - "integrity": "sha512-3iuY4N5dhgMpCUrOVnuAdGrgxVqV2cJpM+XNccjR2DKOB1RUP0aA+wGXEiNziG/UKboFyGBIoKOaNlJxx8bciQ==", + "nwsapi": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.0.4.tgz", + "integrity": "sha512-Zt6HRR6RcJkuj5/N9zeE7FN6YitRW//hK2wTOwX274IBphbY3Zf5+yn5mZ9v/SzAOTMjQNxZf9KkmPLWn0cV4g==", "dev": true }, "oauth-sign": { @@ -7550,6 +10131,18 @@ "integrity": "sha1-ciu9tgA576R8rTxtws5RqFwCxa4=", "dev": true }, + "object-hash": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/object-hash/-/object-hash-1.3.0.tgz", + "integrity": "sha512-05KzQ70lSeGSrZJQXE5wNDiTkBJDlUT/myi6RX9dVIvz7a7Qh4oH93BQdiPMn27nldYvVQCKMUaM83AfizZlsQ==", + "dev": true + }, + "object-keys": { + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.0.12.tgz", + "integrity": "sha512-FTMyFUm2wBcGHnH2eXmz7tC6IwlqQZ6mVZ+6dm6vZ4IQIHjs6FdNsQBuKGPuUUUY6NfJw2PshC08Tn6LzLDOag==", + "dev": true + }, "object-to-spawn-args": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/object-to-spawn-args/-/object-to-spawn-args-1.1.1.tgz", @@ -7598,6 +10191,18 @@ } } }, + "object.assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", + "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", + "dev": true, + "requires": { + "define-properties": "1.1.2", + "function-bind": "1.1.1", + "has-symbols": "1.0.0", + "object-keys": "1.0.12" + } + }, "object.defaults": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/object.defaults/-/object.defaults-1.1.0.tgz", @@ -7627,6 +10232,28 @@ } } }, + "object.entries": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/object.entries/-/object.entries-1.0.4.tgz", + "integrity": "sha1-G/mk3SKI9bM/Opk9JXZh8F0WGl8=", + "dev": true, + "requires": { + "define-properties": "1.1.2", + "es-abstract": "1.12.0", + "function-bind": "1.1.1", + "has": "1.0.3" + } + }, + "object.getownpropertydescriptors": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.0.3.tgz", + "integrity": "sha1-h1jIRvW0B62rDyNuCYbxSwUcqhY=", + "dev": true, + "requires": { + "define-properties": "1.1.2", + "es-abstract": "1.12.0" + } + }, "object.map": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/object.map/-/object.map-1.0.1.tgz", @@ -7699,10 +10326,13 @@ } }, "onetime": { - "version": "1.1.0", - "resolved": "http://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz", - "integrity": "sha1-ofeDj4MUxRbwXs78vEzP4EtO14k=", - "dev": true + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-2.0.1.tgz", + "integrity": "sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ=", + "dev": true, + "requires": { + "mimic-fn": "1.2.0" + } }, "optimist": { "version": "0.6.1", @@ -7742,11 +10372,6 @@ "wordwrap": "1.0.0" } }, - "options": { - "version": "0.0.6", - "resolved": "https://registry.npmjs.org/options/-/options-0.0.6.tgz", - "integrity": "sha1-7CLTEoBrtT5zF3Pnza788cZDEo8=" - }, "orchestrator": { "version": "0.3.8", "resolved": "https://registry.npmjs.org/orchestrator/-/orchestrator-0.3.8.tgz", @@ -7779,10 +10404,41 @@ } }, "ordered-read-streams": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/ordered-read-streams/-/ordered-read-streams-0.1.0.tgz", - "integrity": "sha1-/VZamvjrRHO6abbtijQ1LLVS8SY=", - "dev": true + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/ordered-read-streams/-/ordered-read-streams-1.0.1.tgz", + "integrity": "sha1-d8DLN8QVJdZBZtmQ/61+xqDhNj4=", + "requires": { + "readable-stream": "2.3.6" + }, + "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" + }, + "readable-stream": { + "version": "2.3.6", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", + "requires": { + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "2.0.0", + "safe-buffer": "5.1.2", + "string_decoder": "1.1.1", + "util-deprecate": "1.0.2" + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "5.1.2" + } + } + } }, "original": { "version": "1.0.1", @@ -7794,9 +10450,9 @@ } }, "os-browserify": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/os-browserify/-/os-browserify-0.2.1.tgz", - "integrity": "sha1-Y/xMzuXS13Y9Jrv4YBB45sLgBE8=", + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/os-browserify/-/os-browserify-0.3.0.tgz", + "integrity": "sha1-hUNzx/XCMVkU/Jv8a9gjj92h7Cc=", "dev": true }, "os-homedir": { @@ -7805,27 +10461,74 @@ "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", "dev": true }, + "os-locale": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/os-locale/-/os-locale-2.1.0.tgz", + "integrity": "sha512-3sslG3zJbEYcaC4YVAvDorjGxc7tv6KVATnLPZONiljsUncvihe9BQoVCEs0RZ1kmf4Hk9OBqlZfJZWI4GanKA==", + "dev": true, + "requires": { + "execa": "0.7.0", + "lcid": "1.0.0", + "mem": "1.1.0" + } + }, "os-tmpdir": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", "dev": true }, - "output-file-sync": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/output-file-sync/-/output-file-sync-1.1.2.tgz", - "integrity": "sha1-0KM+7+YaIF+suQCS6CZZjVJFznY=", + "output-file-sync": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/output-file-sync/-/output-file-sync-1.1.2.tgz", + "integrity": "sha1-0KM+7+YaIF+suQCS6CZZjVJFznY=", + "dev": true, + "requires": { + "graceful-fs": "4.1.11", + "mkdirp": "0.5.1", + "object-assign": "4.1.1" + } + }, + "p-finally": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", + "integrity": "sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4=", + "dev": true + }, + "p-limit": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz", + "integrity": "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==", + "dev": true, + "requires": { + "p-try": "1.0.0" + } + }, + "p-locate": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz", + "integrity": "sha1-IKAQOyIqcMj9OcwuWAaA893l7EM=", "dev": true, "requires": { - "graceful-fs": "4.1.11", - "mkdirp": "0.5.1", - "object-assign": "4.1.1" + "p-limit": "1.3.0" } }, + "p-map": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/p-map/-/p-map-1.2.0.tgz", + "integrity": "sha512-r6zKACMNhjPJMTl8KcFH4li//gkrXWfbD6feV8l6doRHlzljFWGJ2AP6iKaCJXyZmAUMOPtvbW7EXkbWO/pLEA==", + "dev": true + }, + "p-try": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz", + "integrity": "sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M=", + "dev": true + }, "pako": { - "version": "0.2.9", - "resolved": "https://registry.npmjs.org/pako/-/pako-0.2.9.tgz", - "integrity": "sha1-8/dSL073gjSNqBYbrZ7P1Rv4OnU=", + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/pako/-/pako-1.0.6.tgz", + "integrity": "sha512-lQe48YPsMJAig+yngZ87Lus+NF+3mtu7DVOBu6b/gHO1YpKwIj5AWjZ/TOS7i46HD/UixzWb1zeWDZfGZ3iYcg==", "dev": true }, "parse-asn1": { @@ -7862,6 +10565,23 @@ "is-dotfile": "1.0.3", "is-extglob": "1.0.0", "is-glob": "2.0.1" + }, + "dependencies": { + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", + "dev": true + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "dev": true, + "requires": { + "is-extglob": "1.0.0" + } + } } }, "parse-json": { @@ -7880,9 +10600,9 @@ "dev": true }, "parse5": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/parse5/-/parse5-1.5.1.tgz", - "integrity": "sha1-m387DeMr543CQBsXVzzK8Pb1nZQ=", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-4.0.0.tgz", + "integrity": "sha512-VrZ7eOd3T1Fk4XWNXMgiGBK/z0MG48BWG2uQNU4I72fkQuKUTZpl+u9k+CxEG0twMVzSmXEEz12z5Fnw1jIQFA==", "dev": true }, "parseurl": { @@ -7913,17 +10633,21 @@ "integrity": "sha1-oLhwcpquIUAFt9UDLsLLuw+0RRo=", "dev": true }, + "path-dirname": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/path-dirname/-/path-dirname-1.0.2.tgz", + "integrity": "sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA=" + }, "path-exists": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-1.0.0.tgz", - "integrity": "sha1-1aiZjrce83p0w06w2eum6HjuoIE=", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", "dev": true }, "path-is-absolute": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", - "dev": true + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" }, "path-is-inside": { "version": "1.0.2", @@ -7931,6 +10655,12 @@ "integrity": "sha1-NlQX3t5EQw0cEa9hAn+s8HS9/FM=", "dev": true }, + "path-key": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", + "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=", + "dev": true + }, "path-parse": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.5.tgz", @@ -8015,19 +10745,45 @@ "pinkie": "2.0.4" } }, - "pkg-up": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/pkg-up/-/pkg-up-1.0.0.tgz", - "integrity": "sha1-Pgj7RhUlxEIWJKM7n35tCvWwWiY=", + "pkg-dir": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-2.0.0.tgz", + "integrity": "sha1-9tXREJ4Z1j7fQo4L1X4Sd3YVM0s=", "dev": true, "requires": { - "find-up": "1.1.2" + "find-up": "2.1.0" + } + }, + "plugin-error": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/plugin-error/-/plugin-error-1.0.1.tgz", + "integrity": "sha512-L1zP0dk7vGweZME2i+EeakvUNqSrdiI3F91TwEoYiGrAfUXmVv6fJIq4g82PAXxNsWOp0J7ZqQy/3Szz0ajTxA==", + "dev": true, + "requires": { + "ansi-colors": "1.1.0", + "arr-diff": "4.0.0", + "arr-union": "3.1.0", + "extend-shallow": "3.0.2" + }, + "dependencies": { + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", + "dev": true + } } }, "pluralize": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/pluralize/-/pluralize-1.2.1.tgz", - "integrity": "sha1-0aIUg/0iu0HlihL6NCGCMUCJfEU=", + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/pluralize/-/pluralize-7.0.0.tgz", + "integrity": "sha512-ARhBOdzS3e41FbkW/XWrTEtukqqLoK5+Z/4UeDaLuSW+39JPeFgs4gCGqsrJHVZX0fUrx//4OF0K1CUGwlIFow==", + "dev": true + }, + "pn": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/pn/-/pn-1.1.0.tgz", + "integrity": "sha512-2qHaIQr2VLRFoxe2nASzsV6ef4yOOH+Fi9FBOVH6cqeSgUnoyySPZkxzLuzd+RYOQTRpROA0ztTMqxROKSb/nA==", "dev": true }, "posix-character-classes": { @@ -8048,10 +10804,37 @@ "integrity": "sha1-gV7R9uvGWSb4ZbMQwHE7yzMVzks=", "dev": true }, + "pretty-format": { + "version": "23.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-23.2.0.tgz", + "integrity": "sha1-OwqqY8AYpTWDNzwcs6XZbMXoMBc=", + "dev": true, + "requires": { + "ansi-regex": "3.0.0", + "ansi-styles": "3.2.1" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + } + } + }, "pretty-hrtime": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/pretty-hrtime/-/pretty-hrtime-0.2.2.tgz", - "integrity": "sha1-1P2INR46R0H4Fzr31qS4RvmJXAA=", + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz", + "integrity": "sha1-t+PqQkNaTJsnWdmeDyAesZWALuE=", "dev": true }, "private": { @@ -8072,9 +10855,9 @@ "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==" }, "progress": { - "version": "1.1.8", - "resolved": "https://registry.npmjs.org/progress/-/progress-1.1.8.tgz", - "integrity": "sha1-4mDHj2Fhzdmw5WzD4Khd4Xx6V74=", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.0.tgz", + "integrity": "sha1-ihvjZr+Pwj2yvSPxDG/pILQ4nR8=", "dev": true }, "promise": { @@ -8092,6 +10875,26 @@ "integrity": "sha1-kRgvkckkhplXQPoF4NqUKsmGvvo=", "dev": true }, + "prompts": { + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/prompts/-/prompts-0.1.10.tgz", + "integrity": "sha512-/MPwms6+g/m6fvXZlQyOL4m4ziDim2+Wc6CdWVjp+nVCkzEkK2N4rR74m/bbGf+dkta+/SBpo1FfES8Wgrk/Fw==", + "dev": true, + "requires": { + "clorox": "1.0.3", + "sisteransi": "0.1.1" + } + }, + "prop-types": { + "version": "15.6.2", + "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.6.2.tgz", + "integrity": "sha512-3pboPvLiWD7dkI3qf3KbUe6hKFKa52w+AE0VCqECtf+QHAKgOL37tTaNCnuX1nAAQ4ZhyP+kYVKf8rLmJ/feDQ==", + "dev": true, + "requires": { + "loose-envify": "1.3.1", + "object-assign": "4.1.1" + } + }, "proxy-addr": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.3.tgz", @@ -8108,6 +10911,18 @@ "integrity": "sha1-0/wRS6BplaRexok/SEzrHXj19HY=", "dev": true }, + "pseudomap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz", + "integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=", + "dev": true + }, + "psl": { + "version": "1.1.28", + "resolved": "https://registry.npmjs.org/psl/-/psl-1.1.28.tgz", + "integrity": "sha512-+AqO1Ae+N/4r7Rvchrdm432afjT9hqJRyBN3DQv9At0tPz4hIFSGKbq64fN9dVoCow4oggIIax5/iONx0r9hZw==", + "dev": true + }, "public-encrypt": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/public-encrypt/-/public-encrypt-4.0.2.tgz", @@ -8122,18 +10937,39 @@ } }, "pump": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/pump/-/pump-1.0.3.tgz", - "integrity": "sha512-8k0JupWme55+9tCVE+FS5ULT3K6AbgqrGa58lTT49RpyfwwcGedHqaC5LlQNdEAumn/wFsu6aPwkuPMioy8kqw==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", + "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", "requires": { "end-of-stream": "1.4.1", "once": "1.4.0" } }, + "pumpify": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/pumpify/-/pumpify-1.5.1.tgz", + "integrity": "sha512-oClZI37HvuUJJxSKKrC17bZ9Cu0ZYhEAGPsPUy9KlMUmv9dKX2o77RUmq7f3XjIxbwyGwYzbzQ1L2Ks8sIradQ==", + "requires": { + "duplexify": "3.6.0", + "inherits": "2.0.3", + "pump": "2.0.1" + }, + "dependencies": { + "pump": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/pump/-/pump-2.0.1.tgz", + "integrity": "sha512-ruPMNRkN3MHP1cWJc9OWr+T/xDP0jhXYCLfJcBuX54hhfIBnaQmAUMfDcG4DM5UMWByBbJY69QSphm3jtDKIkA==", + "requires": { + "end-of-stream": "1.4.1", + "once": "1.4.0" + } + } + } + }, "punycode": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", - "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", + "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", "dev": true }, "qs": { @@ -8240,6 +11076,12 @@ "statuses": "1.4.0" } }, + "iconv-lite": { + "version": "0.4.19", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.19.tgz", + "integrity": "sha512-oTZqweIP51xaGPI4uPa56/Pri/480R+mo7SeU+YETByQNhDG55ycFyNLIgta9vXhILrxXDmF7ZGhqZIcuN0gJQ==", + "dev": true + }, "setprototypeof": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.0.3.tgz", @@ -8267,6 +11109,27 @@ "requires": { "find-up": "1.1.2", "read-pkg": "1.1.0" + }, + "dependencies": { + "find-up": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz", + "integrity": "sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8=", + "dev": true, + "requires": { + "path-exists": "2.1.0", + "pinkie-promise": "2.0.1" + } + }, + "path-exists": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz", + "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=", + "dev": true, + "requires": { + "pinkie-promise": "2.0.1" + } + } } }, "readable-stream": { @@ -8298,15 +11161,6 @@ "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", "dev": true }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "dev": true, - "requires": { - "brace-expansion": "1.1.11" - } - }, "readable-stream": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", @@ -8333,15 +11187,13 @@ } } }, - "readline2": { + "realpath-native": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/readline2/-/readline2-1.0.1.tgz", - "integrity": "sha1-QQWWCP/BVHV7cV2ZidGZ/783LjU=", + "resolved": "https://registry.npmjs.org/realpath-native/-/realpath-native-1.0.1.tgz", + "integrity": "sha512-W14EcXuqUvKP8dkWkD7B95iMy77lpMnlFXbbk409bQtNCbeu0kvRE5reo+yIZ3JXxg6frbGsz2DLQ39lrCB40g==", "dev": true, "requires": { - "code-point-at": "1.1.0", - "is-fullwidth-code-point": "1.0.0", - "mute-stream": "0.0.5" + "util.promisify": "1.0.0" } }, "rechoir": { @@ -8353,16 +11205,6 @@ "resolve": "1.8.1" } }, - "redent": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/redent/-/redent-1.0.0.tgz", - "integrity": "sha1-z5Fqsf1fHxbfsggi3W7H9zDCr94=", - "dev": true, - "requires": { - "indent-string": "2.1.0", - "strip-indent": "1.0.1" - } - }, "reduce-extract": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/reduce-extract/-/reduce-extract-1.0.0.tgz", @@ -8405,28 +11247,6 @@ "test-value": "2.1.0" } }, - "reduplexer": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/reduplexer/-/reduplexer-1.1.0.tgz", - "integrity": "sha1-ff7RimeedJwdetNt4BrLUV8I4UA=", - "requires": { - "inherits": "2.0.3", - "readable-stream": "1.0.34" - }, - "dependencies": { - "readable-stream": { - "version": "1.0.34", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", - "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", - "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.3", - "isarray": "0.0.1", - "string_decoder": "0.10.31" - } - } - } - }, "regenerate": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.0.tgz", @@ -8469,6 +11289,21 @@ "safe-regex": "1.1.0" } }, + "regexp.prototype.flags": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.2.0.tgz", + "integrity": "sha512-ztaw4M1VqgMwl9HlPpOuiYgItcHlunW0He2fE6eNfT6E/CF2FtYi9ofOYe4mKntstYk0Fyh/rDRBdS3AnxjlrA==", + "dev": true, + "requires": { + "define-properties": "1.1.2" + } + }, + "regexpp": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-1.1.0.tgz", + "integrity": "sha512-LOPw8FpgdQF9etWMaAfG/WRthIdXJGYp4mJ2Jgn/2lpkbod9jPn0t9UqN7AxBOKNfzRbYyVfgc7Vk4t/MpnXgw==", + "dev": true + }, "regexpu-core": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/regexpu-core/-/regexpu-core-2.0.0.tgz", @@ -8511,8 +11346,7 @@ "remove-trailing-separator": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz", - "integrity": "sha1-wkvOKig62tW8P1jg1IJJuSN52O8=", - "dev": true + "integrity": "sha1-wkvOKig62tW8P1jg1IJJuSN52O8=" }, "repeat-element": { "version": "1.1.2", @@ -8580,8 +11414,63 @@ "tough-cookie": "2.3.4", "tunnel-agent": "0.6.0", "uuid": "3.3.2" + }, + "dependencies": { + "punycode": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", + "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", + "dev": true + }, + "tough-cookie": { + "version": "2.3.4", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.3.4.tgz", + "integrity": "sha512-TZ6TTfI5NtZnuyy/Kecv+CnoROnyXn2DN97LontgQpCwsX2XyLYCC0ENhYkehSOwAp8rTQKc/NUIF7BkQ5rKLA==", + "dev": true, + "requires": { + "punycode": "1.4.1" + } + } + } + }, + "request-promise-core": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/request-promise-core/-/request-promise-core-1.1.1.tgz", + "integrity": "sha1-Pu4AssWqgyOc+wTFcA2jb4HNCLY=", + "dev": true, + "requires": { + "lodash": "4.17.10" + } + }, + "request-promise-native": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/request-promise-native/-/request-promise-native-1.0.5.tgz", + "integrity": "sha1-UoF3D2jgyXGeUWP9P6tIIhX0/aU=", + "dev": true, + "requires": { + "request-promise-core": "1.1.1", + "stealthy-require": "1.1.1", + "tough-cookie": "2.4.3" } }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", + "dev": true + }, + "require-main-filename": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-1.0.1.tgz", + "integrity": "sha1-l/cXtp1IeE9fUmpsWqj/3aBVpNE=", + "dev": true + }, + "require-package-name": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/require-package-name/-/require-package-name-2.0.1.tgz", + "integrity": "sha1-wR6XJ2tluOKSP3Xav1+y7ww4Qbk=", + "dev": true + }, "require-uncached": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/require-uncached/-/require-uncached-1.0.3.tgz", @@ -8624,6 +11513,23 @@ "path-parse": "1.0.5" } }, + "resolve-cwd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/resolve-cwd/-/resolve-cwd-2.0.0.tgz", + "integrity": "sha1-AKn3OHVW4nA46uIyyqNypqWbZlo=", + "dev": true, + "requires": { + "resolve-from": "3.0.0" + }, + "dependencies": { + "resolve-from": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-3.0.0.tgz", + "integrity": "sha1-six699nWiBvItuZTM17rywoYh0g=", + "dev": true + } + } + }, "resolve-dir": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/resolve-dir/-/resolve-dir-1.0.1.tgz", @@ -8640,156 +11546,408 @@ "integrity": "sha1-Jsv+k10a7uq7Kbw/5a6wHpPUQiY=", "dev": true }, - "resolve-url": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/resolve-url/-/resolve-url-0.2.1.tgz", - "integrity": "sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo=", + "resolve-url": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/resolve-url/-/resolve-url-0.2.1.tgz", + "integrity": "sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo=", + "dev": true + }, + "restore-cursor": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-2.0.0.tgz", + "integrity": "sha1-n37ih/gv0ybU/RYpI9YhKe7g368=", + "dev": true, + "requires": { + "onetime": "2.0.1", + "signal-exit": "3.0.2" + } + }, + "ret": { + "version": "0.1.15", + "resolved": "https://registry.npmjs.org/ret/-/ret-0.1.15.tgz", + "integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg==", + "dev": true + }, + "right-align": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/right-align/-/right-align-0.1.3.tgz", + "integrity": "sha1-YTObci/mo1FWiSENJOFMlhSGE+8=", + "dev": true, + "requires": { + "align-text": "0.1.4" + } + }, + "rimraf": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.2.tgz", + "integrity": "sha512-lreewLK/BlghmxtfH36YYVg1i8IAce4TI7oao75I1g245+6BctqTVQiBP3YUJ9C6DQOXJmkYR9X9fCLtCOJc5w==", + "dev": true, + "requires": { + "glob": "7.1.2" + } + }, + "ripemd160": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/ripemd160/-/ripemd160-2.0.2.tgz", + "integrity": "sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA==", + "dev": true, + "requires": { + "hash-base": "3.0.4", + "inherits": "2.0.3" + } + }, + "rsvp": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/rsvp/-/rsvp-3.6.2.tgz", + "integrity": "sha512-OfWGQTb9vnwRjwtA2QwpG2ICclHC3pgXZO5xt8H2EfgDquO0qVdSb5T88L4qJVAEugbS56pAuV4XZM58UX8ulw==", "dev": true }, - "restore-cursor": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-1.0.1.tgz", - "integrity": "sha1-NGYfRohjJ/7SmRR5FSJS35LapUE=", + "run-async": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/run-async/-/run-async-2.3.0.tgz", + "integrity": "sha1-A3GrSuC91yDUFm19/aZP96RFpsA=", "dev": true, "requires": { - "exit-hook": "1.1.1", - "onetime": "1.1.0" + "is-promise": "2.1.0" } }, - "ret": { - "version": "0.1.15", - "resolved": "https://registry.npmjs.org/ret/-/ret-0.1.15.tgz", - "integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg==", - "dev": true + "rxjs": { + "version": "5.5.11", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-5.5.11.tgz", + "integrity": "sha512-3bjO7UwWfA2CV7lmwYMBzj4fQ6Cq+ftHc2MvUe+WMS7wcdJ1LosDWmdjPQanYp2dBRj572p7PeU81JUxHKOcBA==", + "dev": true, + "requires": { + "symbol-observable": "1.0.1" + } }, - "right-align": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/right-align/-/right-align-0.1.3.tgz", - "integrity": "sha1-YTObci/mo1FWiSENJOFMlhSGE+8=", + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "safe-regex": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/safe-regex/-/safe-regex-1.1.0.tgz", + "integrity": "sha1-QKNmnzsHfR6UPURinhV91IAjvy4=", "dev": true, "requires": { - "align-text": "0.1.4" + "ret": "0.1.15" } }, - "rimraf": { - "version": "2.6.2", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.2.tgz", - "integrity": "sha512-lreewLK/BlghmxtfH36YYVg1i8IAce4TI7oao75I1g245+6BctqTVQiBP3YUJ9C6DQOXJmkYR9X9fCLtCOJc5w==", + "safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "dev": true + }, + "sane": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/sane/-/sane-2.5.2.tgz", + "integrity": "sha1-tNwYYcIbQn6SlQej51HiosuKs/o=", "dev": true, "requires": { - "glob": "7.1.2" + "anymatch": "2.0.0", + "capture-exit": "1.2.0", + "exec-sh": "0.2.2", + "fb-watchman": "2.0.0", + "fsevents": "1.2.4", + "micromatch": "3.1.10", + "minimist": "1.2.0", + "walker": "1.0.7", + "watch": "0.18.0" }, "dependencies": { - "glob": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", - "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", + "anymatch": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-2.0.0.tgz", + "integrity": "sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw==", + "dev": true, + "requires": { + "micromatch": "3.1.10", + "normalize-path": "2.1.1" + } + }, + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", + "dev": true + }, + "array-unique": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=", + "dev": true + }, + "braces": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", + "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", + "dev": true, + "requires": { + "arr-flatten": "1.1.0", + "array-unique": "0.3.2", + "extend-shallow": "2.0.1", + "fill-range": "4.0.0", + "isobject": "3.0.1", + "repeat-element": "1.1.2", + "snapdragon": "0.8.2", + "snapdragon-node": "2.1.1", + "split-string": "3.1.0", + "to-regex": "3.0.2" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, + "expand-brackets": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", + "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", + "dev": true, + "requires": { + "debug": "2.6.9", + "define-property": "0.2.5", + "extend-shallow": "2.0.1", + "posix-character-classes": "0.1.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "dev": true, + "requires": { + "is-descriptor": "0.1.6" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==", + "dev": true + } + } + }, + "extglob": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", + "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", + "dev": true, + "requires": { + "array-unique": "0.3.2", + "define-property": "1.0.0", + "expand-brackets": "2.1.4", + "extend-shallow": "2.0.1", + "fragment-cache": "0.2.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "dev": true, + "requires": { + "is-descriptor": "1.0.2" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "fill-range": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", + "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", + "dev": true, + "requires": { + "extend-shallow": "2.0.1", + "is-number": "3.0.0", + "repeat-string": "1.6.1", + "to-regex-range": "2.1.1" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", "dev": true, "requires": { - "fs.realpath": "1.0.0", - "inflight": "1.0.6", - "inherits": "2.0.3", - "minimatch": "3.0.4", - "once": "1.4.0", - "path-is-absolute": "1.0.1" + "kind-of": "6.0.2" } }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", "dev": true, "requires": { - "brace-expansion": "1.1.11" + "kind-of": "6.0.2" } - } - } - }, - "ripemd160": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/ripemd160/-/ripemd160-2.0.2.tgz", - "integrity": "sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA==", - "dev": true, - "requires": { - "hash-base": "3.0.4", - "inherits": "2.0.3" - } - }, - "run-async": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/run-async/-/run-async-0.1.0.tgz", - "integrity": "sha1-yK1KXhEGYeQCp9IbUw4AnyX444k=", - "dev": true, - "requires": { - "once": "1.4.0" - } - }, - "rx-lite": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/rx-lite/-/rx-lite-3.1.2.tgz", - "integrity": "sha1-Gc5QLKVyZl87ZHsQk5+X/RYV8QI=", - "dev": true - }, - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" - }, - "safe-regex": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/safe-regex/-/safe-regex-1.1.0.tgz", - "integrity": "sha1-QKNmnzsHfR6UPURinhV91IAjvy4=", - "dev": true, - "requires": { - "ret": "0.1.15" - } - }, - "safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "dev": true - }, - "sane": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/sane/-/sane-1.7.0.tgz", - "integrity": "sha1-s1ebzLRclM8gNVzIESSZDf00bjA=", - "dev": true, - "requires": { - "anymatch": "1.3.2", - "exec-sh": "0.2.2", - "fb-watchman": "2.0.0", - "minimatch": "3.0.4", - "minimist": "1.2.0", - "walker": "1.0.7", - "watch": "0.10.0" - }, - "dependencies": { - "bser": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/bser/-/bser-2.0.0.tgz", - "integrity": "sha1-mseNPtXZFYBP2HrLFYvHlxR6Fxk=", + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", "dev": true, "requires": { - "node-int64": "0.4.0" + "is-accessor-descriptor": "1.0.0", + "is-data-descriptor": "1.0.0", + "kind-of": "6.0.2" } }, - "fb-watchman": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.0.tgz", - "integrity": "sha1-VOmr99+i8mzZsWNsWIwa/AXeXVg=", + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", "dev": true, "requires": { - "bser": "2.0.0" + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } } }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=", + "dev": true + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==", + "dev": true + }, + "micromatch": { + "version": "3.1.10", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", + "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", "dev": true, "requires": { - "brace-expansion": "1.1.11" + "arr-diff": "4.0.0", + "array-unique": "0.3.2", + "braces": "2.3.2", + "define-property": "2.0.2", + "extend-shallow": "3.0.2", + "extglob": "2.0.4", + "fragment-cache": "0.2.1", + "kind-of": "6.0.2", + "nanomatch": "1.2.13", + "object.pick": "1.3.0", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" } } } @@ -8801,34 +11959,11 @@ "dev": true }, "semver": { - "version": "4.3.6", - "resolved": "https://registry.npmjs.org/semver/-/semver-4.3.6.tgz", - "integrity": "sha1-MAvG4OhjdPe6YQaLWx7NV/xlMto=", - "dev": true - }, - "semver-regex": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/semver-regex/-/semver-regex-1.0.0.tgz", - "integrity": "sha1-kqSWkGX5xwxpR1PVUkj8aPj2Usk=", + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.5.0.tgz", + "integrity": "sha512-4SJ3dm0WAwWy/NVeioZh5AntkdJoWKxHxcmyP622fOkgHa4z3R0TdBJICINyaSDE6uNwVc8gZr+ZinwZAH4xIA==", "dev": true }, - "semver-truncate": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/semver-truncate/-/semver-truncate-1.1.2.tgz", - "integrity": "sha1-V/Qd5pcHpicJp+AQS6IRcQnqR+g=", - "dev": true, - "requires": { - "semver": "5.5.0" - }, - "dependencies": { - "semver": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.5.0.tgz", - "integrity": "sha512-4SJ3dm0WAwWy/NVeioZh5AntkdJoWKxHxcmyP622fOkgHa4z3R0TdBJICINyaSDE6uNwVc8gZr+ZinwZAH4xIA==", - "dev": true - } - } - }, "send": { "version": "0.16.2", "resolved": "https://registry.npmjs.org/send/-/send-0.16.2.tgz", @@ -8848,6 +11983,17 @@ "on-finished": "2.3.0", "range-parser": "1.2.0", "statuses": "1.4.0" + }, + "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + } } }, "sequencify": { @@ -8869,6 +12015,17 @@ "http-errors": "1.6.3", "mime-types": "2.1.18", "parseurl": "1.3.2" + }, + "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + } } }, "serve-static": { @@ -8883,6 +12040,12 @@ "send": "0.16.2" } }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", + "dev": true + }, "set-immediate-shim": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz", @@ -8912,6 +12075,12 @@ } } }, + "setimmediate": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", + "integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU=", + "dev": true + }, "setprototypeof": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.0.tgz", @@ -8928,16 +12097,25 @@ "safe-buffer": "5.1.2" } }, + "shebang-command": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", + "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", + "dev": true, + "requires": { + "shebang-regex": "1.0.0" + } + }, "shebang-regex": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=", "dev": true }, - "shelljs": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/shelljs/-/shelljs-0.6.1.tgz", - "integrity": "sha1-7GIRvtGSBEIIj+D3Cyg3Iy7SyKg=", + "shellwords": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/shellwords/-/shellwords-0.1.1.tgz", + "integrity": "sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==", "dev": true }, "sigmund": { @@ -8952,6 +12130,12 @@ "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", "dev": true }, + "sisteransi": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-0.1.1.tgz", + "integrity": "sha512-PmGOd02bM9YO5ifxpw36nrNMBTptEtfRl4qUYl9SndkolplkrZZOW7PGHjrZL53QvMVj9nQ+TKqUnRsw4tJa4g==", + "dev": true + }, "slash": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/slash/-/slash-1.0.0.tgz", @@ -8959,10 +12143,13 @@ "dev": true }, "slice-ansi": { - "version": "0.0.4", - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-0.0.4.tgz", - "integrity": "sha1-7b+JA/ZvfOL46v1s7tZeJkyDGzU=", - "dev": true + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-1.0.0.tgz", + "integrity": "sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg==", + "dev": true, + "requires": { + "is-fullwidth-code-point": "2.0.0" + } }, "snapdragon": { "version": "0.8.2", @@ -8980,6 +12167,15 @@ "use": "3.1.0" }, "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, "define-property": { "version": "0.2.5", "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", @@ -9096,6 +12292,15 @@ "url-parse": "1.4.1" }, "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, "faye-websocket": { "version": "0.11.1", "resolved": "https://registry.npmjs.org/faye-websocket/-/faye-websocket-0.11.1.tgz", @@ -9192,63 +12397,25 @@ }, "spdx-license-ids": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.0.tgz", - "integrity": "sha512-2+EPwgbnmOIl8HjGBXXMd9NAu02vLjOO1nWw4kmeRDFyHn+M/ETfHxQUK0oXg8ctgVnl9t3rosNVsZ1jG61nDA==", - "dev": true - }, - "split-string": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/split-string/-/split-string-3.1.0.tgz", - "integrity": "sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==", - "dev": true, - "requires": { - "extend-shallow": "3.0.2" - } - }, - "split2": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/split2/-/split2-2.2.0.tgz", - "integrity": "sha512-RAb22TG39LhI31MbreBgIuKiIKhVsawfTgEGqKHTK87aG+ul/PB8Sqoi3I7kVdRWiCfrKxK3uo4/YUkpNvhPbw==", - "requires": { - "through2": "2.0.3" - }, - "dependencies": { - "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" - }, - "readable-stream": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", - "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", - "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.3", - "isarray": "1.0.0", - "process-nextick-args": "2.0.0", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" - } - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "requires": { - "safe-buffer": "5.1.2" - } - }, - "through2": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.3.tgz", - "integrity": "sha1-AARWmzfHx0ujnEPzzteNGtlBQL4=", - "requires": { - "readable-stream": "2.3.6", - "xtend": "4.0.1" - } - } + "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.0.tgz", + "integrity": "sha512-2+EPwgbnmOIl8HjGBXXMd9NAu02vLjOO1nWw4kmeRDFyHn+M/ETfHxQUK0oXg8ctgVnl9t3rosNVsZ1jG61nDA==", + "dev": true + }, + "split-string": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/split-string/-/split-string-3.1.0.tgz", + "integrity": "sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==", + "dev": true, + "requires": { + "extend-shallow": "3.0.2" + } + }, + "split2": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/split2/-/split2-2.2.0.tgz", + "integrity": "sha512-RAb22TG39LhI31MbreBgIuKiIKhVsawfTgEGqKHTK87aG+ul/PB8Sqoi3I7kVdRWiCfrKxK3uo4/YUkpNvhPbw==", + "requires": { + "through2": "2.0.3" } }, "sprintf-js": { @@ -9274,6 +12441,12 @@ "tweetnacl": "0.14.5" } }, + "stack-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-1.0.1.tgz", + "integrity": "sha1-1PM6tU6OOHeLDKXP07OvsS22hiA=", + "dev": true + }, "static-extend": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/static-extend/-/static-extend-0.1.2.tgz", @@ -9301,6 +12474,12 @@ "integrity": "sha512-zhSCtt8v2NDrRlPQpCNtw/heZLtfUDqxBM1udqikb/Hbk52LK4nQSwr10u77iopCW5LsyHpuXS0GnEc48mLeew==", "dev": true }, + "stealthy-require": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/stealthy-require/-/stealthy-require-1.1.1.tgz", + "integrity": "sha1-NbCYdbT/SfJqd35QmzCQoyJr8ks=", + "dev": true + }, "stompjs": { "version": "git://github.com/gfoiani/stomp-websocket.git#f7fe1d8fcdd9649f53c174f5e1a9470b23b36dfd", "requires": { @@ -9329,235 +12508,632 @@ "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.3", - "isarray": "1.0.0", - "process-nextick-args": "2.0.0", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "2.0.0", + "safe-buffer": "5.1.2", + "string_decoder": "1.1.1", + "util-deprecate": "1.0.2" + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dev": true, + "requires": { + "safe-buffer": "5.1.2" + } + } + } + }, + "stream-cache": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/stream-cache/-/stream-cache-0.0.2.tgz", + "integrity": "sha1-GsWtaDJCjKVWZ9ve45Xa1ObbEY8=", + "dev": true + }, + "stream-connect": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/stream-connect/-/stream-connect-1.0.2.tgz", + "integrity": "sha1-GLyB8u2zW4tdmoAJIAqYUxRCipc=", + "dev": true, + "requires": { + "array-back": "1.0.4" + } + }, + "stream-consume": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/stream-consume/-/stream-consume-0.1.1.tgz", + "integrity": "sha512-tNa3hzgkjEP7XbCkbRXe1jpg+ievoa0O4SCFlMOYEscGSS4JJsckGL8swUyAa/ApGU3Ae4t6Honor4HhL+tRyg==", + "dev": true + }, + "stream-handlebars": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/stream-handlebars/-/stream-handlebars-0.1.6.tgz", + "integrity": "sha1-cwW1BkID2hcWCMR4rPZCoUmJKi8=", + "dev": true, + "requires": { + "handlebars": "3.0.3", + "object-tools": "1.6.7" + }, + "dependencies": { + "object-tools": { + "version": "1.6.7", + "resolved": "https://registry.npmjs.org/object-tools/-/object-tools-1.6.7.tgz", + "integrity": "sha1-UtQA/IdSUJk9u7O6KY18ebsGmNA=", + "dev": true, + "requires": { + "array-tools": "1.8.6", + "typical": "2.6.1" + } + } + } + }, + "stream-http": { + "version": "2.8.3", + "resolved": "https://registry.npmjs.org/stream-http/-/stream-http-2.8.3.tgz", + "integrity": "sha512-+TSkfINHDo4J+ZobQLWiMouQYB+UVYFttRA94FpEzzJ7ZdqcL4uUUQ7WkdkI4DSozGmgBUE/a47L+38PenXhUw==", + "dev": true, + "requires": { + "builtin-status-codes": "3.0.0", + "inherits": "2.0.3", + "readable-stream": "2.3.6", + "to-arraybuffer": "1.0.1", + "xtend": "4.0.1" + }, + "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", + "dev": true + }, + "readable-stream": { + "version": "2.3.6", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", + "dev": true, + "requires": { + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "2.0.0", + "safe-buffer": "5.1.2", + "string_decoder": "1.1.1", + "util-deprecate": "1.0.2" + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dev": true, + "requires": { + "safe-buffer": "5.1.2" + } + } + } + }, + "stream-shift": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stream-shift/-/stream-shift-1.0.0.tgz", + "integrity": "sha1-1cdSgl5TZ+eG944Y5EXqIjoVWVI=" + }, + "stream-via": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/stream-via/-/stream-via-0.1.1.tgz", + "integrity": "sha1-DO5d+clZ+x0/TtpIGfKJ1fkgWvw=", + "dev": true + }, + "string-length": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/string-length/-/string-length-2.0.0.tgz", + "integrity": "sha1-1A27aGo6zpYMHP/KVivyxF+DY+0=", + "dev": true, + "requires": { + "astral-regex": "1.0.0", + "strip-ansi": "4.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "dev": true, + "requires": { + "ansi-regex": "3.0.0" + } + } + } + }, + "string-tools": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/string-tools/-/string-tools-1.0.0.tgz", + "integrity": "sha1-xpqdV4iFiZfaZvHZI7pxE+pGa1o=", + "dev": true + }, + "string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "dev": true, + "requires": { + "is-fullwidth-code-point": "2.0.0", + "strip-ansi": "4.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "dev": true, + "requires": { + "ansi-regex": "3.0.0" + } + } + } + }, + "string.prototype.matchall": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/string.prototype.matchall/-/string.prototype.matchall-2.0.0.tgz", + "integrity": "sha512-WoZ+B2ypng1dp4iFLF2kmZlwwlE19gmjgKuhL1FJfDgCREWb3ye3SDVHSzLH6bxfnvYmkCxbzkmWcQZHA4P//Q==", + "dev": true, + "requires": { + "define-properties": "1.1.2", + "es-abstract": "1.12.0", + "function-bind": "1.1.1", + "has-symbols": "1.0.0", + "regexp.prototype.flags": "1.2.0" + } + }, + "string_decoder": { + "version": "0.10.31", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=" + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "dev": true, + "requires": { + "ansi-regex": "2.1.1" + } + }, + "strip-bom": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-2.0.0.tgz", + "integrity": "sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4=", + "dev": true, + "requires": { + "is-utf8": "0.2.1" + } + }, + "strip-bom-string": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-bom-string/-/strip-bom-string-1.0.0.tgz", + "integrity": "sha1-5SEekiQ2n7uB1jOi8ABE3IztrZI=", + "dev": true + }, + "strip-eof": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", + "integrity": "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=", + "dev": true + }, + "strip-json-comments": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", + "dev": true + }, + "supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=", + "dev": true + }, + "symbol-observable": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/symbol-observable/-/symbol-observable-1.0.1.tgz", + "integrity": "sha1-g0D8RwLDEi310iKI+IKD9RPT/dQ=", + "dev": true + }, + "symbol-tree": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.2.tgz", + "integrity": "sha1-rifbOPZgp64uHDt9G8KQgZuFGeY=", + "dev": true + }, + "table": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/table/-/table-4.0.3.tgz", + "integrity": "sha512-S7rnFITmBH1EnyKcvxBh1LjYeQMmnZtCXSEbHcH6S0NoKit24ZuFO/T1vDcLdYsLQkM188PVVhQmzKIuThNkKg==", + "dev": true, + "requires": { + "ajv": "6.5.2", + "ajv-keywords": "3.2.0", + "chalk": "2.4.1", + "lodash": "4.17.10", + "slice-ansi": "1.0.0", + "string-width": "2.1.1" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "1.9.2" + } + }, + "chalk": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", + "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "dev": true, + "requires": { + "ansi-styles": "3.2.1", + "escape-string-regexp": "1.0.5", + "supports-color": "5.4.0" } }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "supports-color": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz", + "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", "dev": true, "requires": { - "safe-buffer": "5.1.2" + "has-flag": "3.0.0" } } } }, - "stream-cache": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/stream-cache/-/stream-cache-0.0.2.tgz", - "integrity": "sha1-GsWtaDJCjKVWZ9ve45Xa1ObbEY8=", - "dev": true - }, - "stream-connect": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/stream-connect/-/stream-connect-1.0.2.tgz", - "integrity": "sha1-GLyB8u2zW4tdmoAJIAqYUxRCipc=", + "table-layout": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/table-layout/-/table-layout-0.3.0.tgz", + "integrity": "sha1-buINxIPbNxs+XIf3BO0vfHmdLJo=", "dev": true, "requires": { - "array-back": "1.0.4" + "array-back": "1.0.4", + "core-js": "2.5.7", + "deep-extend": "0.4.2", + "feature-detect-es6": "1.4.1", + "typical": "2.6.1", + "wordwrapjs": "2.0.0" } }, - "stream-consume": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/stream-consume/-/stream-consume-0.1.1.tgz", - "integrity": "sha512-tNa3hzgkjEP7XbCkbRXe1jpg+ievoa0O4SCFlMOYEscGSS4JJsckGL8swUyAa/ApGU3Ae4t6Honor4HhL+tRyg==" + "taffydb": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/taffydb/-/taffydb-2.6.2.tgz", + "integrity": "sha1-fLy2S1oUG2ou/CxdLGe04VCyomg=", + "dev": true }, - "stream-handlebars": { - "version": "0.1.6", - "resolved": "https://registry.npmjs.org/stream-handlebars/-/stream-handlebars-0.1.6.tgz", - "integrity": "sha1-cwW1BkID2hcWCMR4rPZCoUmJKi8=", + "tapable": { + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/tapable/-/tapable-0.1.10.tgz", + "integrity": "sha1-KcNXB8K3DlDQdIK10gLo7URtr9Q=", + "dev": true + }, + "temp-path": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/temp-path/-/temp-path-1.0.0.tgz", + "integrity": "sha1-JLFUOXOrRCiW2a02fdnL2/r+kYs=", + "dev": true + }, + "test-exclude": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-4.2.1.tgz", + "integrity": "sha512-qpqlP/8Zl+sosLxBcVKl9vYy26T9NPalxSzzCP/OY6K7j938ui2oKgo+kRZYfxAeIpLqpbVnsHq1tyV70E4lWQ==", "dev": true, "requires": { - "handlebars": "3.0.3", - "object-tools": "1.6.7" + "arrify": "1.0.1", + "micromatch": "3.1.10", + "object-assign": "4.1.1", + "read-pkg-up": "1.0.1", + "require-main-filename": "1.0.1" }, "dependencies": { - "object-tools": { - "version": "1.6.7", - "resolved": "https://registry.npmjs.org/object-tools/-/object-tools-1.6.7.tgz", - "integrity": "sha1-UtQA/IdSUJk9u7O6KY18ebsGmNA=", + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", + "dev": true + }, + "array-unique": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=", + "dev": true + }, + "braces": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", + "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", + "dev": true, + "requires": { + "arr-flatten": "1.1.0", + "array-unique": "0.3.2", + "extend-shallow": "2.0.1", + "fill-range": "4.0.0", + "isobject": "3.0.1", + "repeat-element": "1.1.2", + "snapdragon": "0.8.2", + "snapdragon-node": "2.1.1", + "split-string": "3.1.0", + "to-regex": "3.0.2" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, + "expand-brackets": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", + "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", + "dev": true, + "requires": { + "debug": "2.6.9", + "define-property": "0.2.5", + "extend-shallow": "2.0.1", + "posix-character-classes": "0.1.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "dev": true, + "requires": { + "is-descriptor": "0.1.6" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==", + "dev": true + } + } + }, + "extglob": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", + "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", + "dev": true, + "requires": { + "array-unique": "0.3.2", + "define-property": "1.0.0", + "expand-brackets": "2.1.4", + "extend-shallow": "2.0.1", + "fragment-cache": "0.2.1", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "dependencies": { + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "dev": true, + "requires": { + "is-descriptor": "1.0.2" + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "fill-range": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", + "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", + "dev": true, + "requires": { + "extend-shallow": "2.0.1", + "is-number": "3.0.0", + "repeat-string": "1.6.1", + "to-regex-range": "2.1.1" + }, + "dependencies": { + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "dev": true, + "requires": { + "is-extendable": "0.1.1" + } + } + } + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", "dev": true, "requires": { - "array-tools": "1.8.6", - "typical": "2.6.1" + "kind-of": "6.0.2" } - } - } - }, - "stream-shift": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/stream-shift/-/stream-shift-1.0.0.tgz", - "integrity": "sha1-1cdSgl5TZ+eG944Y5EXqIjoVWVI=" - }, - "stream-via": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/stream-via/-/stream-via-0.1.1.tgz", - "integrity": "sha1-DO5d+clZ+x0/TtpIGfKJ1fkgWvw=", - "dev": true - }, - "string-tools": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/string-tools/-/string-tools-1.0.0.tgz", - "integrity": "sha1-xpqdV4iFiZfaZvHZI7pxE+pGa1o=", - "dev": true - }, - "string-width": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", - "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", - "dev": true, - "requires": { - "code-point-at": "1.1.0", - "is-fullwidth-code-point": "1.0.0", - "strip-ansi": "3.0.1" - } - }, - "string_decoder": { - "version": "0.10.31", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", - "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=" - }, - "strip-ansi": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", - "dev": true, - "requires": { - "ansi-regex": "2.1.1" - } - }, - "strip-bom": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-2.0.0.tgz", - "integrity": "sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4=", - "dev": true, - "requires": { - "is-utf8": "0.2.1" - } - }, - "strip-indent": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-1.0.1.tgz", - "integrity": "sha1-DHlipq3vp7vUrDZkYKY4VSrhoKI=", - "dev": true, - "requires": { - "get-stdin": "4.0.1" - } - }, - "strip-json-comments": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-1.0.4.tgz", - "integrity": "sha1-HhX7ysl9Pumb8tc7TGVrCCu6+5E=", - "dev": true - }, - "supports-color": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", - "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=", - "dev": true - }, - "symbol-tree": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.2.tgz", - "integrity": "sha1-rifbOPZgp64uHDt9G8KQgZuFGeY=", - "dev": true - }, - "table": { - "version": "3.8.3", - "resolved": "https://registry.npmjs.org/table/-/table-3.8.3.tgz", - "integrity": "sha1-K7xULw/amGGnVdOUf+/Ys/UThV8=", - "dev": true, - "requires": { - "ajv": "4.11.8", - "ajv-keywords": "1.5.1", - "chalk": "1.1.1", - "lodash": "4.11.2", - "slice-ansi": "0.0.4", - "string-width": "2.1.1" - }, - "dependencies": { - "ajv": { - "version": "4.11.8", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-4.11.8.tgz", - "integrity": "sha1-gv+wKynmYq5TvcIK8VlHcGc5xTY=", + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", "dev": true, "requires": { - "co": "4.6.0", - "json-stable-stringify": "1.0.1" + "kind-of": "6.0.2" } }, - "ansi-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", - "dev": true - }, - "is-fullwidth-code-point": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", - "dev": true + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "dev": true, + "requires": { + "is-accessor-descriptor": "1.0.0", + "is-data-descriptor": "1.0.0", + "kind-of": "6.0.2" + } }, - "string-width": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", "dev": true, "requires": { - "is-fullwidth-code-point": "2.0.0", - "strip-ansi": "4.0.0" + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.6" + } + } } }, - "strip-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=", + "dev": true + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==", + "dev": true + }, + "micromatch": { + "version": "3.1.10", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", + "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", "dev": true, "requires": { - "ansi-regex": "3.0.0" + "arr-diff": "4.0.0", + "array-unique": "0.3.2", + "braces": "2.3.2", + "define-property": "2.0.2", + "extend-shallow": "3.0.2", + "extglob": "2.0.4", + "fragment-cache": "0.2.1", + "kind-of": "6.0.2", + "nanomatch": "1.2.13", + "object.pick": "1.3.0", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" } } } }, - "table-layout": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/table-layout/-/table-layout-0.3.0.tgz", - "integrity": "sha1-buINxIPbNxs+XIf3BO0vfHmdLJo=", - "dev": true, - "requires": { - "array-back": "1.0.4", - "core-js": "2.5.7", - "deep-extend": "0.4.2", - "feature-detect-es6": "1.4.1", - "typical": "2.6.1", - "wordwrapjs": "2.0.0" - } - }, - "taffydb": { - "version": "2.6.2", - "resolved": "https://registry.npmjs.org/taffydb/-/taffydb-2.6.2.tgz", - "integrity": "sha1-fLy2S1oUG2ou/CxdLGe04VCyomg=", - "dev": true - }, - "tapable": { - "version": "0.1.10", - "resolved": "https://registry.npmjs.org/tapable/-/tapable-0.1.10.tgz", - "integrity": "sha1-KcNXB8K3DlDQdIK10gLo7URtr9Q=", - "dev": true - }, - "temp-path": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/temp-path/-/temp-path-1.0.0.tgz", - "integrity": "sha1-JLFUOXOrRCiW2a02fdnL2/r+kYs=", - "dev": true - }, "test-value": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/test-value/-/test-value-2.1.0.tgz", @@ -9583,6 +13159,12 @@ "promise": "7.3.1" } }, + "throat": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/throat/-/throat-4.1.0.tgz", + "integrity": "sha1-iQN8vJLFarGJJua6TLsgDhVnKmo=", + "dev": true + }, "through": { "version": "2.3.8", "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", @@ -9590,27 +13172,52 @@ "dev": true }, "through2": { - "version": "0.6.5", - "resolved": "https://registry.npmjs.org/through2/-/through2-0.6.5.tgz", - "integrity": "sha1-QaucZ7KdVyCQcUEOHXp6lozTrUg=", + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.3.tgz", + "integrity": "sha1-AARWmzfHx0ujnEPzzteNGtlBQL4=", "requires": { - "readable-stream": "1.0.34", + "readable-stream": "2.3.6", "xtend": "4.0.1" }, "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" + }, "readable-stream": { - "version": "1.0.34", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", - "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", + "version": "2.3.6", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "requires": { "core-util-is": "1.0.2", "inherits": "2.0.3", - "isarray": "0.0.1", - "string_decoder": "0.10.31" + "isarray": "1.0.0", + "process-nextick-args": "2.0.0", + "safe-buffer": "5.1.2", + "string_decoder": "1.1.1", + "util-deprecate": "1.0.2" + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "5.1.2" } } } }, + "through2-filter": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/through2-filter/-/through2-filter-2.0.0.tgz", + "integrity": "sha1-YLxVoNrLdghdsfna6Zq0P4PWIuw=", + "requires": { + "through2": "2.0.3", + "xtend": "4.0.1" + } + }, "tildify": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/tildify/-/tildify-1.2.0.tgz", @@ -9626,13 +13233,32 @@ "integrity": "sha1-dkpaEa9QVhkhsTPztE5hhofg9cM=", "dev": true }, - "timers-browserify": { - "version": "1.4.2", - "resolved": "https://registry.npmjs.org/timers-browserify/-/timers-browserify-1.4.2.tgz", - "integrity": "sha1-ycWLV1voQHN1y14kYtrO50NZ9B0=", + "timers-browserify": { + "version": "2.0.10", + "resolved": "https://registry.npmjs.org/timers-browserify/-/timers-browserify-2.0.10.tgz", + "integrity": "sha512-YvC1SV1XdOUaL6gx5CoGroT3Gu49pK9+TZ38ErPldOWW4j49GI1HKs9DV+KGq/w6y+LZ72W1c8cKz2vzY+qpzg==", + "dev": true, + "requires": { + "setimmediate": "1.0.5" + } + }, + "timers-ext": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/timers-ext/-/timers-ext-0.1.5.tgz", + "integrity": "sha512-tsEStd7kmACHENhsUPaxb8Jf8/+GZZxyNFQbZD07HQOyooOa6At1rQqjffgvg7n+dxscQa9cjjMdWhJtsP2sxg==", + "dev": true, + "requires": { + "es5-ext": "0.10.45", + "next-tick": "1.0.0" + } + }, + "tmp": { + "version": "0.0.33", + "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", + "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", "dev": true, "requires": { - "process": "0.11.10" + "os-tmpdir": "1.0.2" } }, "tmpl": { @@ -9641,6 +13267,21 @@ "integrity": "sha1-I2QN17QtAEM5ERQIIOXPRA5SHdE=", "dev": true }, + "to-absolute-glob": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/to-absolute-glob/-/to-absolute-glob-2.0.2.tgz", + "integrity": "sha1-GGX0PZ50sIItufFFt4z/fQ98hJs=", + "requires": { + "is-absolute": "1.0.0", + "is-negated-glob": "1.0.0" + } + }, + "to-arraybuffer": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/to-arraybuffer/-/to-arraybuffer-1.0.1.tgz", + "integrity": "sha1-fSKbH8xjfkZsoIEYCDanqr/4P0M=", + "dev": true + }, "to-fast-properties": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-1.0.3.tgz", @@ -9690,25 +13331,31 @@ } }, "tough-cookie": { - "version": "2.3.4", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.3.4.tgz", - "integrity": "sha512-TZ6TTfI5NtZnuyy/Kecv+CnoROnyXn2DN97LontgQpCwsX2XyLYCC0ENhYkehSOwAp8rTQKc/NUIF7BkQ5rKLA==", + "version": "2.4.3", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.4.3.tgz", + "integrity": "sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ==", "dev": true, "requires": { + "psl": "1.1.28", "punycode": "1.4.1" + }, + "dependencies": { + "punycode": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", + "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", + "dev": true + } } }, "tr46": { - "version": "0.0.3", - "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", - "integrity": "sha1-gYT9NH2snNwYWZLzpmIuFLnZq2o=", - "dev": true - }, - "trim-newlines": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/trim-newlines/-/trim-newlines-1.0.0.tgz", - "integrity": "sha1-WIeWa7WCpFA6QetST301ARgVphM=", - "dev": true + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-1.0.1.tgz", + "integrity": "sha1-qLE/1r/SSJUZZ0zN5VujaTtwbQk=", + "dev": true, + "requires": { + "punycode": "2.1.1" + } }, "trim-right": { "version": "1.0.1", @@ -9825,20 +13472,19 @@ "dev": true }, "ultron": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/ultron/-/ultron-1.0.2.tgz", - "integrity": "sha1-rOEWq1V80Zc4ak6I9GhTeMiy5Po=" + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/ultron/-/ultron-1.1.1.tgz", + "integrity": "sha512-UIEXBNeYmKptWH6z8ZnqTeS8fV74zG0/eRU9VGkpzz+LIJNs8W/zM/L+7ctCkRrgbNnnR0xxw4bKOr0cW0N0Og==" }, "unc-path-regex": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/unc-path-regex/-/unc-path-regex-0.1.2.tgz", - "integrity": "sha1-5z3T17DXxe2G+6xrCufYxqadUPo=", - "dev": true + "integrity": "sha1-5z3T17DXxe2G+6xrCufYxqadUPo=" }, "underscore": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.8.3.tgz", - "integrity": "sha1-Tz+1OxBuYJf8+ctBCfKl6b36UCI=" + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.9.1.tgz", + "integrity": "sha512-5/4etnCkd9c8gwgowi5/om/mYO5ajCaOgdzj/oW+0eQV9WxKBDZw5+ycmKmeaTXjInS/W0BzpGLo2xR2aBwZdg==" }, "underscore-contrib": { "version": "0.3.0", @@ -9857,12 +13503,6 @@ } } }, - "underscore.string": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/underscore.string/-/underscore.string-2.0.0.tgz", - "integrity": "sha1-dHCFilSguzVg0DfaVtzGe1GB4Ro=", - "dev": true - }, "union-value": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/union-value/-/union-value-1.0.0.tgz", @@ -9899,10 +13539,13 @@ } }, "unique-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/unique-stream/-/unique-stream-1.0.0.tgz", - "integrity": "sha1-1ZpKdUJ0R9mqbJHnAmP40mpLEEs=", - "dev": true + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/unique-stream/-/unique-stream-2.2.1.tgz", + "integrity": "sha1-WqADz76Uxf+GbE59ZouxxNuts2k=", + "requires": { + "json-stable-stringify": "1.0.1", + "through2-filter": "2.0.0" + } }, "unpipe": { "version": "1.0.0", @@ -9962,6 +13605,15 @@ } } }, + "uri-js": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", + "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", + "dev": true, + "requires": { + "punycode": "2.1.1" + } + }, "urix": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/urix/-/urix-0.1.0.tgz", @@ -10050,6 +13702,16 @@ "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" }, + "util.promisify": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/util.promisify/-/util.promisify-1.0.0.tgz", + "integrity": "sha512-i+6qA2MPhvoKLuxnJNpXAGhg7HphQOSUq2LKMZD0m15EiskXUkMvKdF4Uui0WYeCUGea+o2cw/ZuwehtfsrNkA==", + "dev": true, + "requires": { + "define-properties": "1.1.2", + "object.getownpropertydescriptors": "2.0.3" + } + }, "utils-merge": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", @@ -10099,13 +13761,14 @@ } }, "vinyl": { - "version": "0.4.6", - "resolved": "https://registry.npmjs.org/vinyl/-/vinyl-0.4.6.tgz", - "integrity": "sha1-LzVsh6VQolVGHza76ypbqL94SEc=", + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/vinyl/-/vinyl-0.5.3.tgz", + "integrity": "sha1-sEVbOPxeDPMNQyUTLkYZcMIJHN4=", "dev": true, "requires": { - "clone": "0.2.0", - "clone-stats": "0.0.1" + "clone": "1.0.4", + "clone-stats": "0.0.1", + "replace-ext": "0.0.1" } }, "vinyl-fs": { @@ -10124,6 +13787,38 @@ "vinyl": "0.4.6" }, "dependencies": { + "clone": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/clone/-/clone-0.2.0.tgz", + "integrity": "sha1-xhJqkK1Pctv1rNskPMN3JP6T/B8=", + "dev": true + }, + "glob": { + "version": "4.5.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-4.5.3.tgz", + "integrity": "sha1-xstz0yJsHv7wTePFbQEvAzd+4V8=", + "dev": true, + "requires": { + "inflight": "1.0.6", + "inherits": "2.0.3", + "minimatch": "2.0.10", + "once": "1.4.0" + } + }, + "glob-stream": { + "version": "3.1.18", + "resolved": "https://registry.npmjs.org/glob-stream/-/glob-stream-3.1.18.tgz", + "integrity": "sha1-kXCl8St5Awb9/lmPMT+PeVT9FDs=", + "dev": true, + "requires": { + "glob": "4.5.3", + "glob2base": "0.0.12", + "minimatch": "2.0.10", + "ordered-read-streams": "0.1.0", + "through2": "0.6.5", + "unique-stream": "1.0.0" + } + }, "graceful-fs": { "version": "3.0.11", "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.11.tgz", @@ -10133,6 +13828,33 @@ "natives": "1.1.4" } }, + "minimatch": { + "version": "2.0.10", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-2.0.10.tgz", + "integrity": "sha1-jQh8OcazjAAbl/ynzm0OHoCvusc=", + "dev": true, + "requires": { + "brace-expansion": "1.1.11" + } + }, + "ordered-read-streams": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/ordered-read-streams/-/ordered-read-streams-0.1.0.tgz", + "integrity": "sha1-/VZamvjrRHO6abbtijQ1LLVS8SY=", + "dev": true + }, + "readable-stream": { + "version": "1.0.34", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", + "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", + "dev": true, + "requires": { + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "0.0.1", + "string_decoder": "0.10.31" + } + }, "strip-bom": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-1.0.0.tgz", @@ -10142,6 +13864,32 @@ "first-chunk-stream": "1.0.0", "is-utf8": "0.2.1" } + }, + "through2": { + "version": "0.6.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-0.6.5.tgz", + "integrity": "sha1-QaucZ7KdVyCQcUEOHXp6lozTrUg=", + "dev": true, + "requires": { + "readable-stream": "1.0.34", + "xtend": "4.0.1" + } + }, + "unique-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unique-stream/-/unique-stream-1.0.0.tgz", + "integrity": "sha1-1ZpKdUJ0R9mqbJHnAmP40mpLEEs=", + "dev": true + }, + "vinyl": { + "version": "0.4.6", + "resolved": "https://registry.npmjs.org/vinyl/-/vinyl-0.4.6.tgz", + "integrity": "sha1-LzVsh6VQolVGHza76ypbqL94SEc=", + "dev": true, + "requires": { + "clone": "0.2.0", + "clone-stats": "0.0.1" + } } } }, @@ -10163,6 +13911,15 @@ "indexof": "0.0.1" } }, + "w3c-hr-time": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/w3c-hr-time/-/w3c-hr-time-1.0.1.tgz", + "integrity": "sha1-gqwr/2PZUOqeMYmlimViX+3xkEU=", + "dev": true, + "requires": { + "browser-process-hrtime": "0.1.2" + } + }, "walk-back": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/walk-back/-/walk-back-2.0.1.tgz", @@ -10179,10 +13936,14 @@ } }, "watch": { - "version": "0.10.0", - "resolved": "https://registry.npmjs.org/watch/-/watch-0.10.0.tgz", - "integrity": "sha1-d3mLLaD5kQ1ZXxrOWwwiWFIfIdw=", - "dev": true + "version": "0.18.0", + "resolved": "https://registry.npmjs.org/watch/-/watch-0.18.0.tgz", + "integrity": "sha1-KAlUdsbffJDJYxOJkMClQj60uYY=", + "dev": true, + "requires": { + "exec-sh": "0.2.2", + "minimist": "1.2.0" + } }, "watchpack": { "version": "0.2.9", @@ -10232,17 +13993,26 @@ "webpack-core": "0.6.9" }, "dependencies": { + "acorn": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-3.3.0.tgz", + "integrity": "sha1-ReN/s56No/JbruP/U2niu18iAXo=", + "dev": true + }, "async": { "version": "1.5.2", "resolved": "https://registry.npmjs.org/async/-/async-1.5.2.tgz", "integrity": "sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo=", "dev": true }, - "clone": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=", - "dev": true + "browserify-zlib": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/browserify-zlib/-/browserify-zlib-0.1.4.tgz", + "integrity": "sha1-uzX4pRn2AOD6a4SFJByXnQFB+y0=", + "dev": true, + "requires": { + "pako": "0.2.9" + } }, "constants-browserify": { "version": "0.0.1", @@ -10261,6 +14031,12 @@ "sha.js": "2.2.6" } }, + "has-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", + "integrity": "sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=", + "dev": true + }, "https-browserify": { "version": "0.0.0", "resolved": "https://registry.npmjs.org/https-browserify/-/https-browserify-0.0.0.tgz", @@ -10273,6 +14049,18 @@ "integrity": "sha1-/s16GOfOXKar+5U+H4YhOknxYls=", "dev": true }, + "loader-utils": { + "version": "0.2.17", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-0.2.17.tgz", + "integrity": "sha1-+G5jdNQyBabmxg6RlvF8Apm/s0g=", + "dev": true, + "requires": { + "big.js": "3.2.0", + "emojis-list": "2.1.0", + "json5": "0.5.1", + "object-assign": "4.1.1" + } + }, "node-libs-browser": { "version": "0.6.0", "resolved": "https://registry.npmjs.org/node-libs-browser/-/node-libs-browser-0.6.0.tgz", @@ -10310,6 +14098,18 @@ "integrity": "sha1-ScoCk+CxlZCl9d4Qx/JlphfY/lQ=", "dev": true }, + "pako": { + "version": "0.2.9", + "resolved": "https://registry.npmjs.org/pako/-/pako-0.2.9.tgz", + "integrity": "sha1-8/dSL073gjSNqBYbrZ7P1Rv4OnU=", + "dev": true + }, + "punycode": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", + "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", + "dev": true + }, "ripemd160": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/ripemd160/-/ripemd160-0.2.0.tgz", @@ -10341,6 +14141,15 @@ "has-flag": "1.0.0" } }, + "timers-browserify": { + "version": "1.4.2", + "resolved": "https://registry.npmjs.org/timers-browserify/-/timers-browserify-1.4.2.tgz", + "integrity": "sha1-ycWLV1voQHN1y14kYtrO50NZ9B0=", + "dev": true, + "requires": { + "process": "0.11.10" + } + }, "uglify-js": { "version": "2.6.4", "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-2.6.4.tgz", @@ -10378,6 +14187,18 @@ "dev": true } } + }, + "yargs": { + "version": "3.10.0", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-3.10.0.tgz", + "integrity": "sha1-9+572FfdfB0tOMDnTvvWgdFDH9E=", + "dev": true, + "requires": { + "camelcase": "1.2.1", + "cliui": "2.1.0", + "decamelize": "1.2.0", + "window-size": "0.1.0" + } } } }, @@ -10489,6 +14310,12 @@ "webpack-dev-middleware": "1.12.2" }, "dependencies": { + "has-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", + "integrity": "sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=", + "dev": true + }, "supports-color": { "version": "3.2.3", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-3.2.3.tgz", @@ -10516,6 +14343,17 @@ "nan": "2.10.0", "typedarray-to-buffer": "3.1.5", "yaeti": "0.0.6" + }, + "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "optional": true, + "requires": { + "ms": "2.0.0" + } + } } }, "websocket-driver": { @@ -10535,14 +14373,15 @@ "dev": true }, "websocket-stream": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/websocket-stream/-/websocket-stream-3.3.3.tgz", - "integrity": "sha1-Nh2lQEozfmDPvCm0pGNodiZ53ws=", + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/websocket-stream/-/websocket-stream-5.1.2.tgz", + "integrity": "sha512-lchLOk435iDWs0jNuL+hiU14i3ERSrMA0IKSiJh7z6X/i4XNsutBZrtqu2CPOZuA4G/zabiqVAos0vW+S7GEVw==", "requires": { "duplexify": "3.6.0", "inherits": "2.0.3", - "through2": "2.0.3", - "ws": "1.1.5", + "readable-stream": "2.3.6", + "safe-buffer": "5.1.2", + "ws": "3.3.3", "xtend": "4.0.1" }, "dependencies": { @@ -10572,15 +14411,6 @@ "requires": { "safe-buffer": "5.1.2" } - }, - "through2": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.3.tgz", - "integrity": "sha1-AARWmzfHx0ujnEPzzteNGtlBQL4=", - "requires": { - "readable-stream": "2.3.6", - "xtend": "4.0.1" - } } } }, @@ -10591,30 +14421,37 @@ "dev": true, "requires": { "iconv-lite": "0.4.19" + }, + "dependencies": { + "iconv-lite": { + "version": "0.4.19", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.19.tgz", + "integrity": "sha512-oTZqweIP51xaGPI4uPa56/Pri/480R+mo7SeU+YETByQNhDG55ycFyNLIgta9vXhILrxXDmF7ZGhqZIcuN0gJQ==", + "dev": true + } } }, + "whatwg-mimetype": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-2.1.0.tgz", + "integrity": "sha512-FKxhYLytBQiUKjkYteN71fAUA3g6KpNXoho1isLiLSB3N1G4F35Q5vUxWfKFhBwi5IWF27VE6WxhrnnC+m0Mew==", + "dev": true + }, "whatwg-url": { - "version": "4.8.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-4.8.0.tgz", - "integrity": "sha1-0pgaqRSMHgCkHFphMRZqtGg7vMA=", + "version": "6.5.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-6.5.0.tgz", + "integrity": "sha512-rhRZRqx/TLJQWUpQ6bmrt2UV4f0HCQ463yQuONJqC6fO2VoEb1pTYddbe59SkYq87aoM5A3bdhMZiUiVws+fzQ==", "dev": true, "requires": { - "tr46": "0.0.3", - "webidl-conversions": "3.0.1" - }, - "dependencies": { - "webidl-conversions": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", - "integrity": "sha1-JFNCdeKnvGvnvIZhHMFq4KVlSHE=", - "dev": true - } + "lodash.sortby": "4.7.0", + "tr46": "1.0.1", + "webidl-conversions": "4.0.2" } }, "when": { - "version": "3.7.5", - "resolved": "https://registry.npmjs.org/when/-/when-3.7.5.tgz", - "integrity": "sha1-GZ/xFCmJYklXv/YawaLnFa8/YQo=" + "version": "3.7.8", + "resolved": "https://registry.npmjs.org/when/-/when-3.7.8.tgz", + "integrity": "sha1-xxMLan6gRpPoQs3J56Hyqjmjn4I=" }, "which": { "version": "1.3.1", @@ -10625,6 +14462,12 @@ "isexe": "2.0.0" } }, + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", + "dev": true + }, "window-size": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/window-size/-/window-size-0.1.0.tgz", @@ -10649,13 +14492,36 @@ "typical": "2.6.1" } }, - "worker-farm": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/worker-farm/-/worker-farm-1.6.0.tgz", - "integrity": "sha512-6w+3tHbM87WnSWnENBUvA2pxJPLhQUg5LKwUQHq3r+XPhIM+Gh2R5ycbwPCyuGbNg+lPgdcnQUhuC02kJCvffQ==", + "wrap-ansi": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz", + "integrity": "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=", "dev": true, "requires": { - "errno": "0.1.7" + "string-width": "1.0.2", + "strip-ansi": "3.0.1" + }, + "dependencies": { + "is-fullwidth-code-point": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", + "dev": true, + "requires": { + "number-is-nan": "1.0.1" + } + }, + "string-width": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", + "dev": true, + "requires": { + "code-point-at": "1.1.0", + "is-fullwidth-code-point": "1.0.0", + "strip-ansi": "3.0.1" + } + } } }, "wrappy": { @@ -10672,19 +14538,31 @@ "mkdirp": "0.5.1" } }, + "write-file-atomic": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.3.0.tgz", + "integrity": "sha512-xuPeK4OdjWqtfi59ylvVL0Yn35SF3zgcAcv7rBPFHVaEapaDr4GdGgm3j7ckTwH9wHL7fGmgfAnb0+THrHb8tA==", + "dev": true, + "requires": { + "graceful-fs": "4.1.11", + "imurmurhash": "0.1.4", + "signal-exit": "3.0.2" + } + }, "ws": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/ws/-/ws-1.1.5.tgz", - "integrity": "sha512-o3KqipXNUdS7wpQzBHSe180lBGO60SoK0yVo3CYJgb2MkobuWuBX6dhkYP5ORCLd55y+SaflMOV5fqAB53ux4w==", + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/ws/-/ws-3.3.3.tgz", + "integrity": "sha512-nnWLa/NwZSt4KQJu51MYlCcSQ5g7INpOrOMt4XV8j4dqTXdmlUmSHQ8/oLC069ckre0fRsgfvsKwbTdtKLCDkA==", "requires": { - "options": "0.0.6", - "ultron": "1.0.2" + "async-limiter": "1.0.0", + "safe-buffer": "5.1.2", + "ultron": "1.1.1" } }, "xml-name-validator": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-2.0.1.tgz", - "integrity": "sha1-TYuPHszTQZqjYgYb7O9RXh5VljU=", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-3.0.0.tgz", + "integrity": "sha512-A5CUptxDsvxKJEU3yO6DuWBSJz/qizqzJKOMIfUJHETbBw/sFaDxgd6fxm1ewUaM0jZ444Fc5vC5ROYurg/4Pw==", "dev": true }, "xtend": { @@ -10692,28 +14570,85 @@ "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.1.tgz", "integrity": "sha1-pcbVMr5lbiPbgg77lDofBJmNY68=" }, + "y18n": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-3.2.1.tgz", + "integrity": "sha1-bRX7qITAhnnA136I53WegR4H+kE=", + "dev": true + }, "yaeti": { "version": "0.0.6", "resolved": "https://registry.npmjs.org/yaeti/-/yaeti-0.0.6.tgz", "integrity": "sha1-8m9ITXJoTPQr7ft2lwqhYI+/lXc=", "optional": true }, + "yallist": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", + "integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=", + "dev": true + }, "yargs": { - "version": "3.10.0", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-3.10.0.tgz", - "integrity": "sha1-9+572FfdfB0tOMDnTvvWgdFDH9E=", + "version": "11.1.0", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-11.1.0.tgz", + "integrity": "sha512-NwW69J42EsCSanF8kyn5upxvjp5ds+t3+udGBeTbFnERA+lF541DDpMawzo4z6W/QrzNM18D+BPMiOBibnFV5A==", "dev": true, "requires": { - "camelcase": "1.2.1", - "cliui": "2.1.0", + "cliui": "4.1.0", "decamelize": "1.2.0", - "window-size": "0.1.0" + "find-up": "2.1.0", + "get-caller-file": "1.0.2", + "os-locale": "2.1.0", + "require-directory": "2.1.1", + "require-main-filename": "1.0.1", + "set-blocking": "2.0.0", + "string-width": "2.1.1", + "which-module": "2.0.0", + "y18n": "3.2.1", + "yargs-parser": "9.0.2" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "cliui": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz", + "integrity": "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==", + "dev": true, + "requires": { + "string-width": "2.1.1", + "strip-ansi": "4.0.0", + "wrap-ansi": "2.1.0" + } + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "dev": true, + "requires": { + "ansi-regex": "3.0.0" + } + } + } + }, + "yargs-parser": { + "version": "9.0.2", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-9.0.2.tgz", + "integrity": "sha1-nM9qQ0YP5O1Aqbto9I1DuKaMwHc=", + "dev": true, + "requires": { + "camelcase": "4.1.0" }, "dependencies": { "camelcase": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-1.2.1.tgz", - "integrity": "sha1-m7UwTS4LVmmLLHWLCKPqqdqlijk=", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz", + "integrity": "sha1-1UVjW+HjPFQmScaRc+Xeas+uNN0=", "dev": true } } diff --git a/package.json b/package.json index d342dc6..54bad89 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "spacebunny", - "version": "0.5.0", + "version": "0.5.1", "description": "NodeJS client library for Space Bunny IoT platform", "main": "lib/index.js", "scripts": { @@ -33,47 +33,47 @@ "author": "Fancy Pixel (http://fancypixel.it)", "license": "MIT", "devDependencies": { - "babel": "6.5.1", - "babel-cli": "6.8.0", - "babel-core": "6.8.0", - "babel-eslint": "6.0.4", - "babel-jest": "12.0.2", - "babel-loader": "6.2.4", - "babel-plugin-lodash": "3.0.0", - "babel-preset-es2015": "6.6.0", - "babel-preset-stage-0": "6.5.0", - "del": "2.0.2", - "eslint": "2.9.0", - "eslint-config-airbnb": "8.0.0", - "eslint-loader": "1.2.1", - "eslint-plugin-import": "1.6.1", - "eslint-plugin-jsx-a11y": "1.0.4", - "eslint-plugin-react": "5.0.1", - "gulp": "3.8.11", - "gulp-babel": "6.1.2", + "babel": "6.23.0", + "babel-cli": "6.26.0", + "babel-core": "6.26.3", + "babel-eslint": "8.2.5", + "babel-jest": "23.2.0", + "babel-loader": "7.1.4", + "babel-plugin-lodash": "3.3.4", + "babel-preset-es2015": "6.24.1", + "babel-preset-stage-0": "6.24.1", + "del": "3.0.0", + "eslint": "5.0.1", + "eslint-config-airbnb": "17.0.0", + "eslint-loader": "2.0.0", + "eslint-plugin-import": "2.13.0", + "eslint-plugin-jsx-a11y": "6.1.0", + "eslint-plugin-react": "7.10.0", + "gulp": "3.9.1", + "gulp-babel": "7.0.1", "gulp-jsdoc-to-markdown": "1.2.2", - "gulp-rename": "1.2.2", - "gulp-sourcemaps": "1.6.0", - "gulp-util": "3.0.4", - "jest-cli": "12.0.2", - "json-loader": "0.5.2", - "merge-stream": "1.0.0", - "node-libs-browser": "1.0.0", + "gulp-rename": "1.3.0", + "gulp-sourcemaps": "2.6.4", + "gulp-util": "3.0.8", + "jest-cli": "23.3.0", + "json-loader": "0.5.7", + "merge-stream": "1.0.1", + "node-libs-browser": "2.1.0", "path": "0.12.7", "webpack": "1.13.0", "webpack-dev-server": "1.14.0", "webpack-split-by-path": "0.0.8" }, "dependencies": { - "amqplib": "0.4.0", - "axios": "0.11.0", - "bluebird": "3.3.5", - "humps": "1.1.0", - "lodash": "4.11.2", + "amqplib": "0.5.2", + "axios": "0.18.0", + "bluebird": "3.5.1", + "humps": "2.0.1", + "lodash": "4.17.10", "merge": "1.2.0", - "mqtt": "1.10.0", + "mqtt": "2.18.2", "stompjs": "git://github.com/gfoiani/stomp-websocket.git#2.4.0", - "underscore": "1.8.3", - "when": "3.7.5" + "underscore": "1.9.1", + "when": "3.7.8" } } diff --git a/src/protocols/amqpClient.js b/src/protocols/amqpClient.js index b05d469..e7ac559 100644 --- a/src/protocols/amqpClient.js +++ b/src/protocols/amqpClient.js @@ -156,7 +156,7 @@ class AmqpClient extends SpaceBunny { `${connectionParams.secret}@${connectionParams.host}:` + `${connectionParams.protocols.amqp.port}/${connectionParams.vhost.replace('/', '%2f')}`; } - amqp.connect(connectionString, connectionOpts).then((conn) => { + return amqp.connect(connectionString, connectionOpts).then((conn) => { conn.on('error', (err) => { this.emit('error', err); reject(err); diff --git a/src/protocols/amqpStreamClient.js b/src/protocols/amqpStreamClient.js index 87c07bd..761e319 100644 --- a/src/protocols/amqpStreamClient.js +++ b/src/protocols/amqpStreamClient.js @@ -54,6 +54,8 @@ class AmqpStreamClient extends AmqpClient { * * @private * @param {Object} streamHook - Object containit hook info + * { stream: {String}, callback: {func}} + * or * { deviceId: {String}, channel: {String}, callback: {func}} * @param {Object} opts - connection options * @return a promise containing current connection diff --git a/src/spacebunny.js b/src/spacebunny.js index 9d57bd8..fc8cc05 100644 --- a/src/spacebunny.js +++ b/src/spacebunny.js @@ -217,7 +217,8 @@ class SpaceBunny extends EventEmitter { */ tempQueue(prefix, suffix, currentTime) { const timestamp = currentTime || new Date().getTime(); - return `${timestamp}-${this._connectionParams.client}-` + + const deviceId = this._connectionParams.client || this._connectionParams.deviceId; + return `${timestamp}-${deviceId}-` + `${this.exchangeName(prefix, suffix)}.` + `${this._tempQueueSuffix}`; } diff --git a/yarn.lock b/yarn.lock index 330f403..33cbf8d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,11 +2,133 @@ # yarn lockfile v1 +"@babel/code-frame@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0-beta.44.tgz#2a02643368de80916162be70865c97774f3adbd9" + dependencies: + "@babel/highlight" "7.0.0-beta.44" + +"@babel/code-frame@^7.0.0-beta.35": + version "7.0.0-beta.51" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0-beta.51.tgz#bd71d9b192af978df915829d39d4094456439a0c" + dependencies: + "@babel/highlight" "7.0.0-beta.51" + +"@babel/generator@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.0.0-beta.44.tgz#c7e67b9b5284afcf69b309b50d7d37f3e5033d42" + dependencies: + "@babel/types" "7.0.0-beta.44" + jsesc "^2.5.1" + lodash "^4.2.0" + source-map "^0.5.0" + trim-right "^1.0.1" + +"@babel/helper-function-name@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.0.0-beta.44.tgz#e18552aaae2231100a6e485e03854bc3532d44dd" + dependencies: + "@babel/helper-get-function-arity" "7.0.0-beta.44" + "@babel/template" "7.0.0-beta.44" + "@babel/types" "7.0.0-beta.44" + +"@babel/helper-get-function-arity@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0-beta.44.tgz#d03ca6dd2b9f7b0b1e6b32c56c72836140db3a15" + dependencies: + "@babel/types" "7.0.0-beta.44" + +"@babel/helper-module-imports@^7.0.0-beta.49": + version "7.0.0-beta.51" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.0.0-beta.51.tgz#ce00428045fbb7d5ebc0ea7bf835789f15366ab2" + dependencies: + "@babel/types" "7.0.0-beta.51" + lodash "^4.17.5" + +"@babel/helper-split-export-declaration@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.0.0-beta.44.tgz#c0b351735e0fbcb3822c8ad8db4e583b05ebd9dc" + dependencies: + "@babel/types" "7.0.0-beta.44" + +"@babel/highlight@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0-beta.44.tgz#18c94ce543916a80553edcdcf681890b200747d5" + dependencies: + chalk "^2.0.0" + esutils "^2.0.2" + js-tokens "^3.0.0" + +"@babel/highlight@7.0.0-beta.51": + version "7.0.0-beta.51" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0-beta.51.tgz#e8844ae25a1595ccfd42b89623b4376ca06d225d" + dependencies: + chalk "^2.0.0" + esutils "^2.0.2" + js-tokens "^3.0.0" + +"@babel/template@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.0.0-beta.44.tgz#f8832f4fdcee5d59bf515e595fc5106c529b394f" + dependencies: + "@babel/code-frame" "7.0.0-beta.44" + "@babel/types" "7.0.0-beta.44" + babylon "7.0.0-beta.44" + lodash "^4.2.0" + +"@babel/traverse@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.0.0-beta.44.tgz#a970a2c45477ad18017e2e465a0606feee0d2966" + dependencies: + "@babel/code-frame" "7.0.0-beta.44" + "@babel/generator" "7.0.0-beta.44" + "@babel/helper-function-name" "7.0.0-beta.44" + "@babel/helper-split-export-declaration" "7.0.0-beta.44" + "@babel/types" "7.0.0-beta.44" + babylon "7.0.0-beta.44" + debug "^3.1.0" + globals "^11.1.0" + invariant "^2.2.0" + lodash "^4.2.0" + +"@babel/types@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.0.0-beta.44.tgz#6b1b164591f77dec0a0342aca995f2d046b3a757" + dependencies: + esutils "^2.0.2" + lodash "^4.2.0" + to-fast-properties "^2.0.0" + +"@babel/types@7.0.0-beta.51", "@babel/types@^7.0.0-beta.49": + version "7.0.0-beta.51" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.0.0-beta.51.tgz#d802b7b543b5836c778aa691797abf00f3d97ea9" + dependencies: + esutils "^2.0.2" + lodash "^4.17.5" + to-fast-properties "^2.0.0" + +"@gulp-sourcemaps/identity-map@1.X": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@gulp-sourcemaps/identity-map/-/identity-map-1.0.2.tgz#1e6fe5d8027b1f285dc0d31762f566bccd73d5a9" + dependencies: + acorn "^5.0.3" + css "^2.2.1" + normalize-path "^2.1.1" + source-map "^0.6.0" + through2 "^2.0.3" + +"@gulp-sourcemaps/map-sources@1.X": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@gulp-sourcemaps/map-sources/-/map-sources-1.0.0.tgz#890ae7c5d8c877f6d384860215ace9d7ec945bda" + dependencies: + normalize-path "^2.0.1" + through2 "^2.0.3" + Base64@~0.2.0: version "0.2.1" resolved "https://registry.yarnpkg.com/Base64/-/Base64-0.2.1.tgz#ba3a4230708e186705065e66babdd4c35cf60028" -abab@^1.0.3: +abab@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/abab/-/abab-1.0.4.tgz#5faad9c2c07f60dd76770f71cf025b62a63cfd4e" @@ -14,10 +136,6 @@ abbrev@1: version "1.1.1" resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" -abbrev@1.0.x: - version "1.0.9" - resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.0.9.tgz#91b4792588a7738c25f35dd6f63752a2f8776135" - accepts@~1.3.4, accepts@~1.3.5: version "1.3.5" resolved "https://registry.yarnpkg.com/accepts/-/accepts-1.3.5.tgz#eb777df6011723a3b14e8a72c0805c8e86746bd2" @@ -25,11 +143,11 @@ accepts@~1.3.4, accepts@~1.3.5: mime-types "~2.1.18" negotiator "0.6.1" -acorn-globals@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/acorn-globals/-/acorn-globals-3.1.0.tgz#fd8270f71fbb4996b004fa880ee5d46573a731bf" +acorn-globals@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/acorn-globals/-/acorn-globals-4.1.0.tgz#ab716025dbe17c54d3ef81d32ece2b2d99fe2538" dependencies: - acorn "^4.0.4" + acorn "^5.0.0" acorn-jsx@^3.0.0: version "3.0.1" @@ -37,24 +155,23 @@ acorn-jsx@^3.0.0: dependencies: acorn "^3.0.4" -acorn@^3.0.0, acorn@^3.0.4, acorn@^3.1.0, acorn@^3.3.0: - version "3.3.0" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" +acorn-jsx@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-4.1.1.tgz#e8e41e48ea2fe0c896740610ab6a4ffd8add225e" + dependencies: + acorn "^5.0.3" -acorn@^4.0.4: - version "4.0.13" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-4.0.13.tgz#105495ae5361d697bd195c825192e1ad7f253787" +acorn@5.X, acorn@^5.0.0, acorn@^5.0.3, acorn@^5.3.0, acorn@^5.6.0: + version "5.7.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.1.tgz#f095829297706a7c9776958c0afc8930a9b9d9d8" -ajv-keywords@^1.0.0: - version "1.5.1" - resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-1.5.1.tgz#314dd0a4b3368fad3dfcdc54ede6171b886daf3c" +acorn@^3.0.0, acorn@^3.0.4, acorn@^3.3.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" -ajv@^4.7.0: - version "4.11.8" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-4.11.8.tgz#82ffb02b29e662ae53bdc20af15947706739c536" - dependencies: - co "^4.6.0" - json-stable-stringify "^1.0.1" +ajv-keywords@^3.0.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.2.0.tgz#e86b819c602cf8821ad637413698f1dec021847a" ajv@^5.1.0: version "5.5.2" @@ -65,6 +182,15 @@ ajv@^5.1.0: fast-json-stable-stringify "^2.0.0" json-schema-traverse "^0.3.0" +ajv@^6.0.1, ajv@^6.5.0: + version "6.5.2" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.5.2.tgz#678495f9b82f7cca6be248dd92f59bff5e1f4360" + dependencies: + fast-deep-equal "^2.0.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.1" + align-text@^0.1.1, align-text@^0.1.3: version "0.1.4" resolved "https://registry.yarnpkg.com/align-text/-/align-text-0.1.4.tgz#0cd90a561093f35d0a99256c22b7069433fad117" @@ -77,14 +203,21 @@ amdefine@>=0.0.4: version "1.0.1" resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" -amqplib@0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/amqplib/-/amqplib-0.4.0.tgz#9efe7656dda85a7359f664a2726e8e85229e124c" +amqplib@0.5.2: + version "0.5.2" + resolved "https://registry.yarnpkg.com/amqplib/-/amqplib-0.5.2.tgz#d2d7313c7ffaa4d10bcf1e6252de4591b6cc7b63" dependencies: bitsyntax "~0.0.4" + bluebird "^3.4.6" buffer-more-ints "0.0.2" readable-stream "1.x >=1.1.9" - when "~3.6.2" + safe-buffer "^5.0.1" + +ansi-colors@^1.0.1: + version "1.1.0" + resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-1.1.0.tgz#6374b4dd5d4718ff3ce27a671a3b1cad077132a9" + dependencies: + ansi-wrap "^0.1.0" ansi-escape-sequences@^2.2.1, ansi-escape-sequences@^2.2.2: version "2.2.2" @@ -99,9 +232,9 @@ ansi-escape-sequences@^3.0.0: dependencies: array-back "^1.0.3" -ansi-escapes@^1.1.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-1.4.0.tgz#d3a8a83b319aa67793662b13e761c7911422306e" +ansi-escapes@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.1.0.tgz#f73207bb81207d75fd6c83f125af26eea378ca30" ansi-gray@^0.1.1: version "0.1.1" @@ -109,10 +242,6 @@ ansi-gray@^0.1.1: dependencies: ansi-wrap "0.1.0" -ansi-regex@^0.2.0, ansi-regex@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-0.2.1.tgz#0d8e946967a3d8143f93e24e298525fc1b2235f9" - ansi-regex@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" @@ -121,15 +250,17 @@ ansi-regex@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" -ansi-styles@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-1.1.0.tgz#eaecbf66cd706882760b2f4691582b8f55d7a7de" - -ansi-styles@^2.1.0, ansi-styles@^2.2.1: +ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" -ansi-wrap@0.1.0: +ansi-styles@^3.2.0, ansi-styles@^3.2.1: + version "3.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" + dependencies: + color-convert "^1.9.0" + +ansi-wrap@0.1.0, ansi-wrap@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf" @@ -140,6 +271,13 @@ anymatch@^1.3.0: micromatch "^2.1.5" normalize-path "^2.0.0" +anymatch@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-2.0.0.tgz#bcb24b4f37934d9aa7ac17b4adaf89e7c76ef2eb" + dependencies: + micromatch "^3.1.4" + normalize-path "^2.1.1" + app-usage-stats@^0.4.0: version "0.4.1" resolved "https://registry.yarnpkg.com/app-usage-stats/-/app-usage-stats-0.4.1.tgz#97eb9b89b5678fa2ddc9793b1298628cc218429f" @@ -151,6 +289,12 @@ app-usage-stats@^0.4.0: test-value "^2.1.0" usage-stats "^0.8.2" +append-transform@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/append-transform/-/append-transform-1.0.0.tgz#046a52ae582a228bd72f58acfbe2967c678759ab" + dependencies: + default-require-extensions "^2.0.0" + aproba@^1.0.3: version "1.2.0" resolved "https://registry.yarnpkg.com/aproba/-/aproba-1.2.0.tgz#6802e6264efd18c790a1b0d517f0f2627bf2c94a" @@ -172,6 +316,13 @@ argparse@^1.0.7: dependencies: sprintf-js "~1.0.2" +aria-query@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/aria-query/-/aria-query-3.0.0.tgz#65b3fcc1ca1155a8c9ae64d6eee297f15d5133cc" + dependencies: + ast-types-flow "0.0.7" + commander "^2.11.0" + arr-diff@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-2.0.0.tgz#8f3b827f955a8bd669697e4a4256ac3ceae356cf" @@ -208,14 +359,17 @@ array-equal@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/array-equal/-/array-equal-1.0.0.tgz#8c2a5ef2472fd9ea742b04c77a75093ba2757c93" -array-find-index@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/array-find-index/-/array-find-index-1.0.2.tgz#df010aa1287e164bbda6f9723b0a96a1ec4187a1" - array-flatten@1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/array-flatten/-/array-flatten-1.1.1.tgz#9a5f699051b1e7073328f2a008968b64ea2955d2" +array-includes@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/array-includes/-/array-includes-3.0.3.tgz#184b48f62d92d7452bb31b323165c7f8bd02266d" + dependencies: + define-properties "^1.1.2" + es-abstract "^1.7.0" + array-slice@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/array-slice/-/array-slice-1.1.0.tgz#e368ea15f89bc7069f7ffb89aec3a6c7d4ac22d4" @@ -249,7 +403,7 @@ array-union@^1.0.1: dependencies: array-uniq "^1.0.1" -array-uniq@^1.0.0, array-uniq@^1.0.1, array-uniq@^1.0.2: +array-uniq@^1.0.1, array-uniq@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" @@ -261,7 +415,7 @@ array-unique@^0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.3.2.tgz#a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428" -arrify@^1.0.0: +arrify@^1.0.0, arrify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" @@ -295,18 +449,36 @@ assign-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" +ast-types-flow@0.0.7, ast-types-flow@^0.0.7: + version "0.0.7" + resolved "https://registry.yarnpkg.com/ast-types-flow/-/ast-types-flow-0.0.7.tgz#f70b735c6bca1a5c9c22d982c3e39e7feba3bdad" + +astral-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-1.0.0.tgz#6c8c3fb827dd43ee3918f27b82782ab7658a6fd9" + async-each@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.1.tgz#19d386a1d9edc6e7c1c85d388aedbcc56d33602d" -async@1.x, async@^1.3.0, async@^1.4.0: - version "1.5.2" - resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" +async-limiter@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/async-limiter/-/async-limiter-1.0.0.tgz#78faed8c3d074ab81f22b4e985d79e8738f720f8" async@^0.9.0: version "0.9.2" resolved "https://registry.yarnpkg.com/async/-/async-0.9.2.tgz#aea74d5e61c1f899613bf64bda66d4c78f2fd17d" +async@^1.3.0, async@^1.4.0: + version "1.5.2" + resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" + +async@^2.1.4: + version "2.6.1" + resolved "https://registry.yarnpkg.com/async/-/async-2.6.1.tgz#b245a23ca71930044ec53fa46aa00a3e87c6a610" + dependencies: + lodash "^4.17.10" + async@~0.2.6: version "0.2.10" resolved "https://registry.yarnpkg.com/async/-/async-0.2.10.tgz#b6bbe0b0674b9d719708ca38de8c237cb526c3d1" @@ -327,39 +499,41 @@ aws4@^1.6.0: version "1.7.0" resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.7.0.tgz#d4d0e9b9dbfca77bf08eeb0a8a471550fe39e289" -axios@0.11.0: - version "0.11.0" - resolved "https://registry.yarnpkg.com/axios/-/axios-0.11.0.tgz#50adc59bd0f11bee89a383b24b2d407648e6d6e8" - dependencies: - follow-redirects "0.0.7" - -babel-cli@6.8.0: - version "6.8.0" - resolved "https://registry.yarnpkg.com/babel-cli/-/babel-cli-6.8.0.tgz#10f0f1260a24ed9470580b086e585f3b657c07e1" - dependencies: - babel-core "^6.8.0" - babel-polyfill "^6.8.0" - babel-register "^6.8.0" - babel-runtime "^6.0.0" - bin-version-check "^2.1.0" - chalk "1.1.1" - commander "^2.8.1" - convert-source-map "^1.1.0" - fs-readdir-recursive "^0.1.0" - glob "^5.0.5" - lodash "^3.2.0" - log-symbols "^1.0.2" - output-file-sync "^1.1.0" - path-exists "^1.0.0" - path-is-absolute "^1.0.0" - request "^2.65.0" +axios@0.18.0: + version "0.18.0" + resolved "https://registry.yarnpkg.com/axios/-/axios-0.18.0.tgz#32d53e4851efdc0a11993b6cd000789d70c05102" + dependencies: + follow-redirects "^1.3.0" + is-buffer "^1.1.5" + +axobject-query@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/axobject-query/-/axobject-query-2.0.1.tgz#05dfa705ada8ad9db993fa6896f22d395b0b0a07" + dependencies: + ast-types-flow "0.0.7" + +babel-cli@6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-cli/-/babel-cli-6.26.0.tgz#502ab54874d7db88ad00b887a06383ce03d002f1" + dependencies: + babel-core "^6.26.0" + babel-polyfill "^6.26.0" + babel-register "^6.26.0" + babel-runtime "^6.26.0" + commander "^2.11.0" + convert-source-map "^1.5.0" + fs-readdir-recursive "^1.0.0" + glob "^7.1.2" + lodash "^4.17.4" + output-file-sync "^1.1.2" + path-is-absolute "^1.0.1" slash "^1.0.0" - source-map "^0.5.0" - v8flags "^2.0.10" + source-map "^0.5.6" + v8flags "^2.1.1" optionalDependencies: - chokidar "^1.0.0" + chokidar "^1.6.1" -babel-code-frame@^6.26.0, babel-code-frame@^6.8.0: +babel-code-frame@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b" dependencies: @@ -367,33 +541,7 @@ babel-code-frame@^6.26.0, babel-code-frame@^6.8.0: esutils "^2.0.2" js-tokens "^3.0.2" -babel-core@6.8.0: - version "6.8.0" - resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.8.0.tgz#52fde0b4c05d9eb7f60ada3c75666238f14d1420" - dependencies: - babel-code-frame "^6.8.0" - babel-generator "^6.8.0" - babel-helpers "^6.8.0" - babel-messages "^6.8.0" - babel-register "^6.8.0" - babel-runtime "^6.0.0" - babel-template "^6.8.0" - babel-traverse "^6.8.0" - babel-types "^6.8.0" - babylon "^6.7.0" - convert-source-map "^1.1.0" - debug "^2.1.1" - json5 "^0.4.0" - lodash "^3.10.0" - minimatch "^2.0.3" - path-exists "^1.0.0" - path-is-absolute "^1.0.0" - private "^0.1.6" - shebang-regex "^1.0.0" - slash "^1.0.0" - source-map "^0.5.0" - -babel-core@^6.0.0, babel-core@^6.0.2, babel-core@^6.26.0, babel-core@^6.8.0: +babel-core@6.26.3, babel-core@^6.0.0, babel-core@^6.26.0: version "6.26.3" resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.3.tgz#b2e2f09e342d0f0c88e2f02e067794125e75c207" dependencies: @@ -417,17 +565,18 @@ babel-core@^6.0.0, babel-core@^6.0.2, babel-core@^6.26.0, babel-core@^6.8.0: slash "^1.0.0" source-map "^0.5.7" -babel-eslint@6.0.4: - version "6.0.4" - resolved "https://registry.yarnpkg.com/babel-eslint/-/babel-eslint-6.0.4.tgz#cf87dcd516241b2e01d85e80e08e849a232bdef7" +babel-eslint@8.2.5: + version "8.2.5" + resolved "https://registry.yarnpkg.com/babel-eslint/-/babel-eslint-8.2.5.tgz#dc2331c259d36782aa189da510c43dedd5adc7a3" dependencies: - babel-traverse "^6.0.20" - babel-types "^6.0.19" - babylon "^6.0.18" - lodash.assign "^4.0.0" - lodash.pickby "^4.0.0" + "@babel/code-frame" "7.0.0-beta.44" + "@babel/traverse" "7.0.0-beta.44" + "@babel/types" "7.0.0-beta.44" + babylon "7.0.0-beta.44" + eslint-scope "~3.7.1" + eslint-visitor-keys "^1.0.0" -babel-generator@^6.26.0, babel-generator@^6.8.0: +babel-generator@^6.18.0, babel-generator@^6.26.0: version "6.26.1" resolved "https://registry.yarnpkg.com/babel-generator/-/babel-generator-6.26.1.tgz#1844408d3b8f0d35a404ea7ac180f087a601bd90" dependencies: @@ -551,50 +700,62 @@ babel-helper-replace-supers@^6.24.1: babel-traverse "^6.24.1" babel-types "^6.24.1" -babel-helpers@^6.24.1, babel-helpers@^6.8.0: +babel-helpers@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-helpers/-/babel-helpers-6.24.1.tgz#3471de9caec388e5c850e597e58a26ddf37602b2" dependencies: babel-runtime "^6.22.0" babel-template "^6.24.1" -babel-jest@12.0.2: - version "12.0.2" - resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-12.0.2.tgz#8eca2bf52a6865a7384f5b3343c19bff986987ad" +babel-jest@23.2.0, babel-jest@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-23.2.0.tgz#14a9d6a3f4122dfea6069d37085adf26a53a4dba" dependencies: - babel-core "^6.0.0" - babel-preset-jest "^12.0.2" + babel-plugin-istanbul "^4.1.6" + babel-preset-jest "^23.2.0" -babel-loader@6.2.4: - version "6.2.4" - resolved "https://registry.yarnpkg.com/babel-loader/-/babel-loader-6.2.4.tgz#aa70aff8ddc223a5952e839a43a6c3a4c8bfa1e9" +babel-loader@7.1.4: + version "7.1.4" + resolved "https://registry.yarnpkg.com/babel-loader/-/babel-loader-7.1.4.tgz#e3463938bd4e6d55d1c174c5485d406a188ed015" dependencies: - loader-utils "^0.2.11" + find-cache-dir "^1.0.0" + loader-utils "^1.0.2" mkdirp "^0.5.1" - object-assign "^4.0.1" -babel-messages@^6.23.0, babel-messages@^6.8.0: +babel-messages@^6.23.0: version "6.23.0" resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-6.23.0.tgz#f3cdf4703858035b2a2951c6ec5edf6c62f2630e" dependencies: babel-runtime "^6.22.0" -babel-plugin-check-es2015-constants@^6.3.13: +babel-plugin-check-es2015-constants@^6.22.0: version "6.22.0" resolved "https://registry.yarnpkg.com/babel-plugin-check-es2015-constants/-/babel-plugin-check-es2015-constants-6.22.0.tgz#35157b101426fd2ffd3da3f75c7d1e91835bbf8a" dependencies: babel-runtime "^6.22.0" -babel-plugin-jest-hoist@^12.1.0: - version "12.1.0" - resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-12.1.0.tgz#4e0d0a2fd723c4f9ab01a1606daa15bf36bd7083" +babel-plugin-istanbul@^4.1.6: + version "4.1.6" + resolved "https://registry.yarnpkg.com/babel-plugin-istanbul/-/babel-plugin-istanbul-4.1.6.tgz#36c59b2192efce81c5b378321b74175add1c9a45" + dependencies: + babel-plugin-syntax-object-rest-spread "^6.13.0" + find-up "^2.1.0" + istanbul-lib-instrument "^1.10.1" + test-exclude "^4.2.1" + +babel-plugin-jest-hoist@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-23.2.0.tgz#e61fae05a1ca8801aadee57a6d66b8cefaf44167" -babel-plugin-lodash@3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/babel-plugin-lodash/-/babel-plugin-lodash-3.0.0.tgz#9f7a19711f2c4077003a246341aab9a613b2f273" +babel-plugin-lodash@3.3.4: + version "3.3.4" + resolved "https://registry.yarnpkg.com/babel-plugin-lodash/-/babel-plugin-lodash-3.3.4.tgz#4f6844358a1340baed182adbeffa8df9967bc196" dependencies: - glob "^7.0.3" - lodash "^4.11.1" + "@babel/helper-module-imports" "^7.0.0-beta.49" + "@babel/types" "^7.0.0-beta.49" + glob "^7.1.1" + lodash "^4.17.10" + require-package-name "^2.0.1" babel-plugin-syntax-async-functions@^6.8.0: version "6.13.0" @@ -636,7 +797,7 @@ babel-plugin-syntax-function-bind@^6.8.0: version "6.13.0" resolved "https://registry.yarnpkg.com/babel-plugin-syntax-function-bind/-/babel-plugin-syntax-function-bind-6.13.0.tgz#48c495f177bdf31a981e732f55adc0bdd2601f46" -babel-plugin-syntax-object-rest-spread@^6.8.0: +babel-plugin-syntax-object-rest-spread@^6.13.0, babel-plugin-syntax-object-rest-spread@^6.8.0: version "6.13.0" resolved "https://registry.yarnpkg.com/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz#fd6536f2bce13836ffa3a5458c4903a597bb3bf5" @@ -687,26 +848,26 @@ babel-plugin-transform-decorators@^6.24.1: babel-template "^6.24.1" babel-types "^6.24.1" -babel-plugin-transform-do-expressions@^6.3.13: +babel-plugin-transform-do-expressions@^6.22.0: version "6.22.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-do-expressions/-/babel-plugin-transform-do-expressions-6.22.0.tgz#28ccaf92812d949c2cd1281f690c8fdc468ae9bb" dependencies: babel-plugin-syntax-do-expressions "^6.8.0" babel-runtime "^6.22.0" -babel-plugin-transform-es2015-arrow-functions@^6.3.13: +babel-plugin-transform-es2015-arrow-functions@^6.22.0: version "6.22.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-arrow-functions/-/babel-plugin-transform-es2015-arrow-functions-6.22.0.tgz#452692cb711d5f79dc7f85e440ce41b9f244d221" dependencies: babel-runtime "^6.22.0" -babel-plugin-transform-es2015-block-scoped-functions@^6.3.13: +babel-plugin-transform-es2015-block-scoped-functions@^6.22.0: version "6.22.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-block-scoped-functions/-/babel-plugin-transform-es2015-block-scoped-functions-6.22.0.tgz#bbc51b49f964d70cb8d8e0b94e820246ce3a6141" dependencies: babel-runtime "^6.22.0" -babel-plugin-transform-es2015-block-scoping@^6.6.0: +babel-plugin-transform-es2015-block-scoping@^6.24.1: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-block-scoping/-/babel-plugin-transform-es2015-block-scoping-6.26.0.tgz#d70f5299c1308d05c12f463813b0a09e73b1895f" dependencies: @@ -716,7 +877,7 @@ babel-plugin-transform-es2015-block-scoping@^6.6.0: babel-types "^6.26.0" lodash "^4.17.4" -babel-plugin-transform-es2015-classes@^6.6.0: +babel-plugin-transform-es2015-classes@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-classes/-/babel-plugin-transform-es2015-classes-6.24.1.tgz#5a4c58a50c9c9461e564b4b2a3bfabc97a2584db" dependencies: @@ -730,33 +891,33 @@ babel-plugin-transform-es2015-classes@^6.6.0: babel-traverse "^6.24.1" babel-types "^6.24.1" -babel-plugin-transform-es2015-computed-properties@^6.3.13: +babel-plugin-transform-es2015-computed-properties@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-computed-properties/-/babel-plugin-transform-es2015-computed-properties-6.24.1.tgz#6fe2a8d16895d5634f4cd999b6d3480a308159b3" dependencies: babel-runtime "^6.22.0" babel-template "^6.24.1" -babel-plugin-transform-es2015-destructuring@^6.6.0: +babel-plugin-transform-es2015-destructuring@^6.22.0: version "6.23.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-destructuring/-/babel-plugin-transform-es2015-destructuring-6.23.0.tgz#997bb1f1ab967f682d2b0876fe358d60e765c56d" dependencies: babel-runtime "^6.22.0" -babel-plugin-transform-es2015-duplicate-keys@^6.6.0: +babel-plugin-transform-es2015-duplicate-keys@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-duplicate-keys/-/babel-plugin-transform-es2015-duplicate-keys-6.24.1.tgz#73eb3d310ca969e3ef9ec91c53741a6f1576423e" dependencies: babel-runtime "^6.22.0" babel-types "^6.24.1" -babel-plugin-transform-es2015-for-of@^6.6.0: +babel-plugin-transform-es2015-for-of@^6.22.0: version "6.23.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-for-of/-/babel-plugin-transform-es2015-for-of-6.23.0.tgz#f47c95b2b613df1d3ecc2fdb7573623c75248691" dependencies: babel-runtime "^6.22.0" -babel-plugin-transform-es2015-function-name@^6.3.13: +babel-plugin-transform-es2015-function-name@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-function-name/-/babel-plugin-transform-es2015-function-name-6.24.1.tgz#834c89853bc36b1af0f3a4c5dbaa94fd8eacaa8b" dependencies: @@ -764,13 +925,21 @@ babel-plugin-transform-es2015-function-name@^6.3.13: babel-runtime "^6.22.0" babel-types "^6.24.1" -babel-plugin-transform-es2015-literals@^6.3.13: +babel-plugin-transform-es2015-literals@^6.22.0: version "6.22.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-literals/-/babel-plugin-transform-es2015-literals-6.22.0.tgz#4f54a02d6cd66cf915280019a31d31925377ca2e" dependencies: babel-runtime "^6.22.0" -babel-plugin-transform-es2015-modules-commonjs@^6.6.0: +babel-plugin-transform-es2015-modules-amd@^6.24.1: + version "6.24.1" + resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-amd/-/babel-plugin-transform-es2015-modules-amd-6.24.1.tgz#3b3e54017239842d6d19c3011c4bd2f00a00d154" + dependencies: + babel-plugin-transform-es2015-modules-commonjs "^6.24.1" + babel-runtime "^6.22.0" + babel-template "^6.24.1" + +babel-plugin-transform-es2015-modules-commonjs@^6.24.1: version "6.26.2" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-commonjs/-/babel-plugin-transform-es2015-modules-commonjs-6.26.2.tgz#58a793863a9e7ca870bdc5a881117ffac27db6f3" dependencies: @@ -779,14 +948,30 @@ babel-plugin-transform-es2015-modules-commonjs@^6.6.0: babel-template "^6.26.0" babel-types "^6.26.0" -babel-plugin-transform-es2015-object-super@^6.3.13: +babel-plugin-transform-es2015-modules-systemjs@^6.24.1: + version "6.24.1" + resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-systemjs/-/babel-plugin-transform-es2015-modules-systemjs-6.24.1.tgz#ff89a142b9119a906195f5f106ecf305d9407d23" + dependencies: + babel-helper-hoist-variables "^6.24.1" + babel-runtime "^6.22.0" + babel-template "^6.24.1" + +babel-plugin-transform-es2015-modules-umd@^6.24.1: + version "6.24.1" + resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-umd/-/babel-plugin-transform-es2015-modules-umd-6.24.1.tgz#ac997e6285cd18ed6176adb607d602344ad38468" + dependencies: + babel-plugin-transform-es2015-modules-amd "^6.24.1" + babel-runtime "^6.22.0" + babel-template "^6.24.1" + +babel-plugin-transform-es2015-object-super@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-object-super/-/babel-plugin-transform-es2015-object-super-6.24.1.tgz#24cef69ae21cb83a7f8603dad021f572eb278f8d" dependencies: babel-helper-replace-supers "^6.24.1" babel-runtime "^6.22.0" -babel-plugin-transform-es2015-parameters@^6.6.0: +babel-plugin-transform-es2015-parameters@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-parameters/-/babel-plugin-transform-es2015-parameters-6.24.1.tgz#57ac351ab49caf14a97cd13b09f66fdf0a625f2b" dependencies: @@ -797,20 +982,20 @@ babel-plugin-transform-es2015-parameters@^6.6.0: babel-traverse "^6.24.1" babel-types "^6.24.1" -babel-plugin-transform-es2015-shorthand-properties@^6.3.13: +babel-plugin-transform-es2015-shorthand-properties@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-shorthand-properties/-/babel-plugin-transform-es2015-shorthand-properties-6.24.1.tgz#24f875d6721c87661bbd99a4622e51f14de38aa0" dependencies: babel-runtime "^6.22.0" babel-types "^6.24.1" -babel-plugin-transform-es2015-spread@^6.3.13: +babel-plugin-transform-es2015-spread@^6.22.0: version "6.22.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-spread/-/babel-plugin-transform-es2015-spread-6.22.0.tgz#d6d68a99f89aedc4536c81a542e8dd9f1746f8d1" dependencies: babel-runtime "^6.22.0" -babel-plugin-transform-es2015-sticky-regex@^6.3.13: +babel-plugin-transform-es2015-sticky-regex@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-sticky-regex/-/babel-plugin-transform-es2015-sticky-regex-6.24.1.tgz#00c1cdb1aca71112cdf0cf6126c2ed6b457ccdbc" dependencies: @@ -818,19 +1003,19 @@ babel-plugin-transform-es2015-sticky-regex@^6.3.13: babel-runtime "^6.22.0" babel-types "^6.24.1" -babel-plugin-transform-es2015-template-literals@^6.6.0: +babel-plugin-transform-es2015-template-literals@^6.22.0: version "6.22.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-template-literals/-/babel-plugin-transform-es2015-template-literals-6.22.0.tgz#a84b3450f7e9f8f1f6839d6d687da84bb1236d8d" dependencies: babel-runtime "^6.22.0" -babel-plugin-transform-es2015-typeof-symbol@^6.6.0: +babel-plugin-transform-es2015-typeof-symbol@^6.22.0: version "6.23.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-typeof-symbol/-/babel-plugin-transform-es2015-typeof-symbol-6.23.0.tgz#dec09f1cddff94b52ac73d505c84df59dcceb372" dependencies: babel-runtime "^6.22.0" -babel-plugin-transform-es2015-unicode-regex@^6.3.13: +babel-plugin-transform-es2015-unicode-regex@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-unicode-regex/-/babel-plugin-transform-es2015-unicode-regex-6.24.1.tgz#d38b12f42ea7323f729387f18a7c5ae1faeb35e9" dependencies: @@ -853,7 +1038,7 @@ babel-plugin-transform-export-extensions@^6.22.0: babel-plugin-syntax-export-extensions "^6.8.0" babel-runtime "^6.22.0" -babel-plugin-transform-function-bind@^6.3.13: +babel-plugin-transform-function-bind@^6.22.0: version "6.22.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-function-bind/-/babel-plugin-transform-function-bind-6.22.0.tgz#c6fb8e96ac296a310b8cf8ea401462407ddf6a97" dependencies: @@ -867,7 +1052,7 @@ babel-plugin-transform-object-rest-spread@^6.22.0: babel-plugin-syntax-object-rest-spread "^6.8.0" babel-runtime "^6.26.0" -babel-plugin-transform-regenerator@^6.6.0: +babel-plugin-transform-regenerator@^6.24.1: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-regenerator/-/babel-plugin-transform-regenerator-6.26.0.tgz#e0703696fbde27f0a3efcacf8b4dca2f7b3a8f2f" dependencies: @@ -880,7 +1065,7 @@ babel-plugin-transform-strict-mode@^6.24.1: babel-runtime "^6.22.0" babel-types "^6.24.1" -babel-polyfill@^6.13.0, babel-polyfill@^6.8.0: +babel-polyfill@^6.13.0, babel-polyfill@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-polyfill/-/babel-polyfill-6.26.0.tgz#379937abc67d7895970adc621f284cd966cf2153" dependencies: @@ -888,47 +1073,51 @@ babel-polyfill@^6.13.0, babel-polyfill@^6.8.0: core-js "^2.5.0" regenerator-runtime "^0.10.5" -babel-preset-es2015@6.6.0: - version "6.6.0" - resolved "https://registry.yarnpkg.com/babel-preset-es2015/-/babel-preset-es2015-6.6.0.tgz#88b33e58fec94c6ebde58dc65ece5d14e0ec2568" - dependencies: - babel-plugin-check-es2015-constants "^6.3.13" - babel-plugin-transform-es2015-arrow-functions "^6.3.13" - babel-plugin-transform-es2015-block-scoped-functions "^6.3.13" - babel-plugin-transform-es2015-block-scoping "^6.6.0" - babel-plugin-transform-es2015-classes "^6.6.0" - babel-plugin-transform-es2015-computed-properties "^6.3.13" - babel-plugin-transform-es2015-destructuring "^6.6.0" - babel-plugin-transform-es2015-duplicate-keys "^6.6.0" - babel-plugin-transform-es2015-for-of "^6.6.0" - babel-plugin-transform-es2015-function-name "^6.3.13" - babel-plugin-transform-es2015-literals "^6.3.13" - babel-plugin-transform-es2015-modules-commonjs "^6.6.0" - babel-plugin-transform-es2015-object-super "^6.3.13" - babel-plugin-transform-es2015-parameters "^6.6.0" - babel-plugin-transform-es2015-shorthand-properties "^6.3.13" - babel-plugin-transform-es2015-spread "^6.3.13" - babel-plugin-transform-es2015-sticky-regex "^6.3.13" - babel-plugin-transform-es2015-template-literals "^6.6.0" - babel-plugin-transform-es2015-typeof-symbol "^6.6.0" - babel-plugin-transform-es2015-unicode-regex "^6.3.13" - babel-plugin-transform-regenerator "^6.6.0" - -babel-preset-jest@^12.0.2: - version "12.1.0" - resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-12.1.0.tgz#0b401e6e8a1c4eabc55dbcb59bc46312eb1b6bf6" - dependencies: - babel-plugin-jest-hoist "^12.1.0" - -babel-preset-stage-0@6.5.0: - version "6.5.0" - resolved "https://registry.yarnpkg.com/babel-preset-stage-0/-/babel-preset-stage-0-6.5.0.tgz#8b8479b2077482b8f3dc8f8f5f0c9c79788cde22" +babel-preset-es2015@6.24.1: + version "6.24.1" + resolved "https://registry.yarnpkg.com/babel-preset-es2015/-/babel-preset-es2015-6.24.1.tgz#d44050d6bc2c9feea702aaf38d727a0210538939" + dependencies: + babel-plugin-check-es2015-constants "^6.22.0" + babel-plugin-transform-es2015-arrow-functions "^6.22.0" + babel-plugin-transform-es2015-block-scoped-functions "^6.22.0" + babel-plugin-transform-es2015-block-scoping "^6.24.1" + babel-plugin-transform-es2015-classes "^6.24.1" + babel-plugin-transform-es2015-computed-properties "^6.24.1" + babel-plugin-transform-es2015-destructuring "^6.22.0" + babel-plugin-transform-es2015-duplicate-keys "^6.24.1" + babel-plugin-transform-es2015-for-of "^6.22.0" + babel-plugin-transform-es2015-function-name "^6.24.1" + babel-plugin-transform-es2015-literals "^6.22.0" + babel-plugin-transform-es2015-modules-amd "^6.24.1" + babel-plugin-transform-es2015-modules-commonjs "^6.24.1" + babel-plugin-transform-es2015-modules-systemjs "^6.24.1" + babel-plugin-transform-es2015-modules-umd "^6.24.1" + babel-plugin-transform-es2015-object-super "^6.24.1" + babel-plugin-transform-es2015-parameters "^6.24.1" + babel-plugin-transform-es2015-shorthand-properties "^6.24.1" + babel-plugin-transform-es2015-spread "^6.22.0" + babel-plugin-transform-es2015-sticky-regex "^6.24.1" + babel-plugin-transform-es2015-template-literals "^6.22.0" + babel-plugin-transform-es2015-typeof-symbol "^6.22.0" + babel-plugin-transform-es2015-unicode-regex "^6.24.1" + babel-plugin-transform-regenerator "^6.24.1" + +babel-preset-jest@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-23.2.0.tgz#8ec7a03a138f001a1a8fb1e8113652bf1a55da46" + dependencies: + babel-plugin-jest-hoist "^23.2.0" + babel-plugin-syntax-object-rest-spread "^6.13.0" + +babel-preset-stage-0@6.24.1: + version "6.24.1" + resolved "https://registry.yarnpkg.com/babel-preset-stage-0/-/babel-preset-stage-0-6.24.1.tgz#5642d15042f91384d7e5af8bc88b1db95b039e6a" dependencies: - babel-plugin-transform-do-expressions "^6.3.13" - babel-plugin-transform-function-bind "^6.3.13" - babel-preset-stage-1 "^6.3.13" + babel-plugin-transform-do-expressions "^6.22.0" + babel-plugin-transform-function-bind "^6.22.0" + babel-preset-stage-1 "^6.24.1" -babel-preset-stage-1@^6.3.13: +babel-preset-stage-1@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-preset-stage-1/-/babel-preset-stage-1-6.24.1.tgz#7692cd7dcd6849907e6ae4a0a85589cfb9e2bfb0" dependencies: @@ -955,7 +1144,7 @@ babel-preset-stage-3@^6.24.1: babel-plugin-transform-exponentiation-operator "^6.24.1" babel-plugin-transform-object-rest-spread "^6.22.0" -babel-register@^6.26.0, babel-register@^6.8.0: +babel-register@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-register/-/babel-register-6.26.0.tgz#6ed021173e2fcb486d7acb45c6009a856f647071" dependencies: @@ -967,14 +1156,14 @@ babel-register@^6.26.0, babel-register@^6.8.0: mkdirp "^0.5.1" source-map-support "^0.4.15" -babel-runtime@^6.0.0, babel-runtime@^6.18.0, babel-runtime@^6.22.0, babel-runtime@^6.26.0: +babel-runtime@^6.18.0, babel-runtime@^6.22.0, babel-runtime@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe" dependencies: core-js "^2.4.0" regenerator-runtime "^0.11.0" -babel-template@^6.24.1, babel-template@^6.26.0, babel-template@^6.8.0: +babel-template@^6.16.0, babel-template@^6.24.1, babel-template@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-template/-/babel-template-6.26.0.tgz#de03e2d16396b069f46dd9fff8521fb1a0e35e02" dependencies: @@ -984,7 +1173,7 @@ babel-template@^6.24.1, babel-template@^6.26.0, babel-template@^6.8.0: babylon "^6.18.0" lodash "^4.17.4" -babel-traverse@^6.0.20, babel-traverse@^6.24.1, babel-traverse@^6.26.0, babel-traverse@^6.8.0: +babel-traverse@^6.0.0, babel-traverse@^6.18.0, babel-traverse@^6.24.1, babel-traverse@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-traverse/-/babel-traverse-6.26.0.tgz#46a9cbd7edcc62c8e5c064e2d2d8d0f4035766ee" dependencies: @@ -998,7 +1187,7 @@ babel-traverse@^6.0.20, babel-traverse@^6.24.1, babel-traverse@^6.26.0, babel-tr invariant "^2.2.2" lodash "^4.17.4" -babel-types@^6.0.19, babel-types@^6.19.0, babel-types@^6.24.1, babel-types@^6.26.0, babel-types@^6.8.0: +babel-types@^6.0.0, babel-types@^6.18.0, babel-types@^6.19.0, babel-types@^6.24.1, babel-types@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-types/-/babel-types-6.26.0.tgz#a3b073f94ab49eb6fa55cd65227a334380632497" dependencies: @@ -1007,11 +1196,15 @@ babel-types@^6.0.19, babel-types@^6.19.0, babel-types@^6.24.1, babel-types@^6.26 lodash "^4.17.4" to-fast-properties "^1.0.3" -babel@6.5.1: - version "6.5.1" - resolved "http://registry.npmjs.org/babel/-/babel-6.5.1.tgz#17369d7d6f2682d5deb741d65bfd5f746be123ab" +babel@6.23.0: + version "6.23.0" + resolved "https://registry.yarnpkg.com/babel/-/babel-6.23.0.tgz#d0d1e7d803e974765beea3232d4e153c0efb90f4" -babylon@^6.0.18, babylon@^6.18.0, babylon@^6.7.0: +babylon@7.0.0-beta.44: + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/babylon/-/babylon-7.0.0-beta.44.tgz#89159e15e6e30c5096e22d738d8c0af8a0e8ca1d" + +babylon@^6.18.0: version "6.18.0" resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.18.0.tgz#af2f3b88fa6f5c1e4c634d1a0f8eac4f55b395e3" @@ -1053,21 +1246,6 @@ big.js@^3.1.3: version "3.2.0" resolved "https://registry.yarnpkg.com/big.js/-/big.js-3.2.0.tgz#a5fc298b81b9e0dca2e458824784b65c52ba588e" -bin-version-check@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/bin-version-check/-/bin-version-check-2.1.0.tgz#e4e5df290b9069f7d111324031efc13fdd11a5b0" - dependencies: - bin-version "^1.0.0" - minimist "^1.1.0" - semver "^4.0.3" - semver-truncate "^1.0.0" - -bin-version@^1.0.0: - version "1.0.4" - resolved "https://registry.yarnpkg.com/bin-version/-/bin-version-1.0.4.tgz#9eb498ee6fd76f7ab9a7c160436f89579435d78e" - dependencies: - find-versions "^1.0.0" - binary-extensions@^1.0.0: version "1.11.0" resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.11.0.tgz#46aa1751fb6a2f93ee5e689bb1087d4b14c6c205" @@ -1078,16 +1256,16 @@ bitsyntax@~0.0.4: dependencies: buffer-more-ints "0.0.2" -bl@^1.0.0: +bl@^1.2.1: version "1.2.2" resolved "https://registry.yarnpkg.com/bl/-/bl-1.2.2.tgz#a160911717103c07410cef63ef51b397c025af9c" dependencies: readable-stream "^2.3.5" safe-buffer "^5.1.1" -bluebird@3.3.5: - version "3.3.5" - resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.3.5.tgz#5ee747f1c7bd967658b683936430aee753955a34" +bluebird@3.5.1, bluebird@^3.4.6: + version "3.5.1" + resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.5.1.tgz#d9551f9de98f1fcda1e683d17ee91a0602ee2eb9" bluebird@~3.4.6: version "3.4.7" @@ -1146,6 +1324,16 @@ brorand@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/brorand/-/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f" +browser-process-hrtime@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/browser-process-hrtime/-/browser-process-hrtime-0.1.2.tgz#425d68a58d3447f02a04aa894187fce8af8b7b8e" + +browser-resolve@^1.11.3: + version "1.11.3" + resolved "https://registry.yarnpkg.com/browser-resolve/-/browser-resolve-1.11.3.tgz#9b7cbb3d0f510e4cb86bdbd796124d28b5890af6" + dependencies: + resolve "1.1.7" + browserify-aes@^1.0.0, browserify-aes@^1.0.4: version "1.2.0" resolved "https://registry.yarnpkg.com/browserify-aes/-/browserify-aes-1.2.0.tgz#326734642f403dabc3003209853bb70ad428ef48" @@ -1192,18 +1380,18 @@ browserify-sign@^4.0.0: inherits "^2.0.1" parse-asn1 "^5.0.0" +browserify-zlib@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/browserify-zlib/-/browserify-zlib-0.2.0.tgz#2869459d9aa3be245fe8fe2ca1f46e2e7f54d73f" + dependencies: + pako "~1.0.5" + browserify-zlib@~0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/browserify-zlib/-/browserify-zlib-0.1.4.tgz#bb35f8a519f600e0fa6b8485241c979d0141fb2d" dependencies: pako "~0.2.0" -bser@1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/bser/-/bser-1.0.2.tgz#381116970b2a6deea5646dd15dd7278444b56169" - dependencies: - node-int64 "^0.4.0" - bser@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/bser/-/bser-2.0.0.tgz#9ac78d3ed5d915804fd87acb158bc797147a1719" @@ -1230,10 +1418,14 @@ buffer@^4.3.0, buffer@^4.9.0: ieee754 "^1.1.4" isarray "^1.0.0" -builtin-modules@^1.0.0, builtin-modules@^1.1.1: +builtin-modules@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/builtin-modules/-/builtin-modules-1.1.1.tgz#270f076c5a72c02f5b65a47df94c5fe3a278892f" +builtin-status-codes@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/builtin-status-codes/-/builtin-status-codes-3.0.0.tgz#85982878e21b98e1c66425e03d0174788f569ee8" + bytes@3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/bytes/-/bytes-3.0.0.tgz#d32815404d689699f85a4ea4fa8755dd13a96048" @@ -1262,6 +1454,13 @@ cache-point@~0.3.3: fs-then-native "^1.0.2" mkdirp "~0.5.1" +callback-stream@^1.0.2: + version "1.1.0" + resolved "https://registry.yarnpkg.com/callback-stream/-/callback-stream-1.1.0.tgz#4701a51266f06e06eaa71fc17233822d875f4908" + dependencies: + inherits "^2.0.1" + readable-stream "> 1.0.0 < 3.0.0" + caller-path@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/caller-path/-/caller-path-0.1.0.tgz#94085ef63581ecd3daa92444a8fe94e82577751f" @@ -1272,20 +1471,23 @@ callsites@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/callsites/-/callsites-0.2.0.tgz#afab96262910a7f33c19a5775825c69f34e350ca" -camelcase-keys@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/camelcase-keys/-/camelcase-keys-2.1.0.tgz#308beeaffdf28119051efa1d932213c91b8f92e7" - dependencies: - camelcase "^2.0.0" - map-obj "^1.0.0" +callsites@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-2.0.0.tgz#06eb84f00eea413da86affefacbffb36093b3c50" camelcase@^1.0.2: version "1.2.1" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-1.2.1.tgz#9bb5304d2e0b56698b2c758b08a3eaa9daa58a39" -camelcase@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-2.1.1.tgz#7c1d16d679a1bbe59ca02cacecfb011e201f5a1f" +camelcase@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-4.1.0.tgz#d545635be1e33c542649c69173e5de6acfae34dd" + +capture-exit@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/capture-exit/-/capture-exit-1.2.0.tgz#1c5fcc489fd0ab00d4f1ac7ae1072e3173fbab6f" + dependencies: + rsvp "^3.3.3" caseless@~0.12.0: version "0.12.0" @@ -1304,27 +1506,7 @@ center-align@^0.1.1: align-text "^0.1.3" lazy-cache "^1.0.3" -chalk@1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-1.1.1.tgz#509afb67066e7499f7eb3535c77445772ae2d019" - dependencies: - ansi-styles "^2.1.0" - escape-string-regexp "^1.0.2" - has-ansi "^2.0.0" - strip-ansi "^3.0.0" - supports-color "^2.0.0" - -chalk@^0.5.0: - version "0.5.1" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-0.5.1.tgz#663b3a648b68b55d04690d49167aa837858f2174" - dependencies: - ansi-styles "^1.1.0" - escape-string-regexp "^1.0.0" - has-ansi "^0.1.0" - strip-ansi "^0.3.0" - supports-color "^0.2.0" - -chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: +chalk@^1.0.0, chalk@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/chalk/-/chalk-1.1.3.tgz#a8115c55e4a702fe4d150abd3872822a7e09fc98" dependencies: @@ -1334,7 +1516,19 @@ chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" -chokidar@^1.0.0: +chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0: + version "2.4.1" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e" + dependencies: + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" + +chardet@^0.4.0: + version "0.4.2" + resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" + +chokidar@^1.0.0, chokidar@^1.6.1: version "1.7.0" resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-1.7.0.tgz#798e689778151c8076b4b360e5edd28cda2bb468" dependencies: @@ -1353,6 +1547,10 @@ chownr@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/chownr/-/chownr-1.0.1.tgz#e2a75042a9551908bebd25b8523d5f9769d79181" +ci-info@^1.0.0: + version "1.1.3" + resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-1.1.3.tgz#710193264bb05c77b8c90d02f5aaf22216a667b2" + cipher-base@^1.0.0, cipher-base@^1.0.1, cipher-base@^1.0.3: version "1.0.4" resolved "https://registry.yarnpkg.com/cipher-base/-/cipher-base-1.0.4.tgz#8760e4ecc272f4c363532f926d874aae2c1397de" @@ -1382,17 +1580,11 @@ cli-commands@0.1.0: command-line-commands "^1.0.4" command-line-usage "^3.0.5" -cli-cursor@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-1.0.2.tgz#64da3f7d56a54412e59794bd62dc35295e8f2987" - dependencies: - restore-cursor "^1.0.1" - -cli-table@0.0.x: - version "0.0.2" - resolved "https://registry.yarnpkg.com/cli-table/-/cli-table-0.0.2.tgz#982867e16435325c66c208a1e71b95336ea3093b" +cli-cursor@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5" dependencies: - colors "0.3.0" + restore-cursor "^2.0.0" cli-width@^2.0.0: version "2.2.0" @@ -1406,6 +1598,14 @@ cliui@^2.1.0: right-align "^0.1.1" wordwrap "0.0.2" +cliui@^4.0.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-4.1.0.tgz#348422dbe82d800b3022eef4f6ac10bf2e4d1b49" + dependencies: + string-width "^2.1.1" + strip-ansi "^4.0.0" + wrap-ansi "^2.0.0" + clone-stats@^0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-0.0.1.tgz#b88f94a82cf38b8791d58046ea4029ad88ca99d1" @@ -1418,6 +1618,10 @@ clone@^1.0.0, clone@^1.0.2: version "1.0.4" resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.4.tgz#da309cc263df15994c688ca902179ca3c7cd7c7e" +clorox@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/clorox/-/clorox-1.0.3.tgz#6fa63653f280c33d69f548fb14d239ddcfa1590d" + co@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" @@ -1456,14 +1660,20 @@ collection-visit@^1.0.0: map-visit "^1.0.0" object-visit "^1.0.0" +color-convert@^1.9.0: + version "1.9.2" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.2.tgz#49881b8fba67df12a96bdf3f56c0aab9e7913147" + dependencies: + color-name "1.1.1" + +color-name@1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.1.tgz#4b1415304cf50028ea81643643bd82ea05803689" + color-support@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" -colors@0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/colors/-/colors-0.3.0.tgz#c247d64d34db0ca4dc8e43f3ecd6da98d0af94e7" - column-layout@^2.1.1: version "2.1.4" resolved "https://registry.yarnpkg.com/column-layout/-/column-layout-2.1.4.tgz#ed2857092ccf8338026fe538379d9672d70b3641" @@ -1551,7 +1761,7 @@ command-line-usage@^3.0.3, command-line-usage@^3.0.5: table-layout "^0.3.0" typical "^2.6.0" -commander@^2.8.1: +commander@^2.11.0: version "2.16.0" resolved "https://registry.yarnpkg.com/commander/-/commander-2.16.0.tgz#f16390593996ceb4f3eeb020b31d78528f7f8a50" @@ -1566,6 +1776,14 @@ common-sequence@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/common-sequence/-/common-sequence-1.0.2.tgz#30e07f3f8f6f7f9b3dee854f20b2d39eee086de8" +commondir@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" + +compare-versions@^3.1.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/compare-versions/-/compare-versions-3.3.0.tgz#af93ea705a96943f622ab309578b9b90586f39c3" + component-emitter@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.2.1.tgz#137918d6d78283f7df7a6b7c5a63e140e69425e6" @@ -1592,7 +1810,7 @@ concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" -concat-stream@^1.4.6, concat-stream@^1.4.7: +concat-stream@^1.6.2: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" dependencies: @@ -1631,19 +1849,19 @@ constants-browserify@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/constants-browserify/-/constants-browserify-1.0.0.tgz#c20b96d8c617748aaf1c16021760cd27fcb8cb75" +contains-path@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/contains-path/-/contains-path-0.1.0.tgz#fe8cf184ff6670b6baef01a9d4861a5cbec4120a" + content-disposition@0.5.2: version "0.5.2" resolved "https://registry.yarnpkg.com/content-disposition/-/content-disposition-0.5.2.tgz#0cf68bb9ddf5f2be7961c3a85178cb85dba78cb4" -content-type-parser@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/content-type-parser/-/content-type-parser-1.0.2.tgz#caabe80623e63638b2502fd4c7f12ff4ce2352e7" - content-type@~1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/content-type/-/content-type-1.0.4.tgz#e138cc75e040c727b1966fe5e5f8c9aee256fe3b" -convert-source-map@^1.1.0, convert-source-map@^1.1.1, convert-source-map@^1.5.1: +convert-source-map@1.X, convert-source-map@^1.4.0, convert-source-map@^1.5.0, convert-source-map@^1.5.1: version "1.5.1" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.5.1.tgz#b8278097b9bc229365de5c62cf5fcaed8b5599e5" @@ -1667,15 +1885,6 @@ core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" -cover@^0.2.9: - version "0.2.9" - resolved "https://registry.yarnpkg.com/cover/-/cover-0.2.9.tgz#262029dfb31714d48043fed91ede658593955dd4" - dependencies: - cli-table "0.0.x" - underscore "1.2.x" - underscore.string "2.0.x" - which "1.0.x" - create-ecdh@^4.0.0: version "4.0.3" resolved "https://registry.yarnpkg.com/create-ecdh/-/create-ecdh-4.0.3.tgz#c9111b6f33045c4697f144787f9254cdc77c45ff" @@ -1704,6 +1913,24 @@ create-hmac@^1.1.0, create-hmac@^1.1.2, create-hmac@^1.1.4: safe-buffer "^5.0.1" sha.js "^2.4.8" +cross-spawn@^5.0.1: + version "5.1.0" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-5.1.0.tgz#e8bd0efee58fcff6f8f94510a0a554bbfa235449" + dependencies: + lru-cache "^4.0.1" + shebang-command "^1.2.0" + which "^1.2.9" + +cross-spawn@^6.0.5: + version "6.0.5" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" + dependencies: + nice-try "^1.0.4" + path-key "^2.0.1" + semver "^5.5.0" + shebang-command "^1.2.0" + which "^1.2.9" + crypto-browserify@^3.11.0: version "3.12.0" resolved "https://registry.yarnpkg.com/crypto-browserify/-/crypto-browserify-3.12.0.tgz#396cf9f3137f03e4b8e532c58f698254e00f80ec" @@ -1728,45 +1955,53 @@ crypto-browserify@~3.2.6: ripemd160 "0.2.0" sha.js "2.2.6" +css@2.X, css@^2.2.1: + version "2.2.3" + resolved "https://registry.yarnpkg.com/css/-/css-2.2.3.tgz#f861f4ba61e79bedc962aa548e5780fd95cbc6be" + dependencies: + inherits "^2.0.1" + source-map "^0.1.38" + source-map-resolve "^0.5.1" + urix "^0.1.0" + cssom@0.3.x, "cssom@>= 0.3.2 < 0.4.0": version "0.3.4" resolved "https://registry.yarnpkg.com/cssom/-/cssom-0.3.4.tgz#8cd52e8a3acfd68d3aed38ee0a640177d2f9d797" -"cssstyle@>= 0.2.37 < 0.3.0": - version "0.2.37" - resolved "https://registry.yarnpkg.com/cssstyle/-/cssstyle-0.2.37.tgz#541097234cb2513c83ceed3acddc27ff27987d54" +"cssstyle@>= 0.3.1 < 0.4.0": + version "0.3.1" + resolved "https://registry.yarnpkg.com/cssstyle/-/cssstyle-0.3.1.tgz#6da9b4cff1bc5d716e6e5fe8e04fcb1b50a49adf" dependencies: cssom "0.3.x" -currently-unhandled@^0.4.1: - version "0.4.1" - resolved "https://registry.yarnpkg.com/currently-unhandled/-/currently-unhandled-0.4.1.tgz#988df33feab191ef799a61369dd76c17adf957ea" - dependencies: - array-find-index "^1.0.1" - d@1: version "1.0.0" resolved "https://registry.yarnpkg.com/d/-/d-1.0.0.tgz#754bb5bfe55451da69a58b94d45f4c5b0462d58f" dependencies: es5-ext "^0.10.9" +damerau-levenshtein@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/damerau-levenshtein/-/damerau-levenshtein-1.0.4.tgz#03191c432cb6eea168bb77f3a55ffdccb8978514" + dashdash@^1.12.0: version "1.14.1" resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" dependencies: assert-plus "^1.0.0" +data-urls@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/data-urls/-/data-urls-1.0.0.tgz#24802de4e81c298ea8a9388bb0d8e461c774684f" + dependencies: + abab "^1.0.4" + whatwg-mimetype "^2.0.0" + whatwg-url "^6.4.0" + date-now@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/date-now/-/date-now-0.1.4.tgz#eaf439fd4d4848ad74e5cc7dbef200672b9e345b" -dateformat@^1.0.11: - version "1.0.12" - resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-1.0.12.tgz#9f124b67594c937ff706932e4a642cca8dbbfee9" - dependencies: - get-stdin "^4.0.1" - meow "^3.3.0" - dateformat@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-2.2.0.tgz#4065e2013cf9fb916ddfd82efb506ad4c6769062" @@ -1784,19 +2019,27 @@ ddata@~0.1.25: string-tools "^1.0.0" test-value "^2.0.0" -debug@2.6.9, debug@^2.1.1, debug@^2.1.2, debug@^2.2.0, debug@^2.3.3, debug@^2.6.6, debug@^2.6.8, debug@^2.6.9: +debug-fabulous@1.X: + version "1.1.0" + resolved "https://registry.yarnpkg.com/debug-fabulous/-/debug-fabulous-1.1.0.tgz#af8a08632465224ef4174a9f06308c3c2a1ebc8e" + dependencies: + debug "3.X" + memoizee "0.4.X" + object-assign "4.X" + +debug@2.6.9, debug@^2.1.2, debug@^2.2.0, debug@^2.3.3, debug@^2.6.6, debug@^2.6.8, debug@^2.6.9: version "2.6.9" resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" dependencies: ms "2.0.0" -debug@^3.1.0: +debug@3.X, debug@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" dependencies: ms "2.0.0" -decamelize@^1.0.0, decamelize@^1.1.2: +decamelize@^1.0.0, decamelize@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" @@ -1816,8 +2059,14 @@ deep-is@~0.1.3: version "0.1.3" resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" -defaults@^1.0.0: - version "1.0.3" +default-require-extensions@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/default-require-extensions/-/default-require-extensions-2.0.0.tgz#f5f8fbb18a7d6d50b21f641f649ebb522cfe24f7" + dependencies: + strip-bom "^3.0.0" + +defaults@^1.0.0: + version "1.0.3" resolved "https://registry.yarnpkg.com/defaults/-/defaults-1.0.3.tgz#c656051e9817d9ff08ed881477f3fe4019f3ef7d" dependencies: clone "^1.0.2" @@ -1826,6 +2075,13 @@ defer-promise@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/defer-promise/-/defer-promise-1.0.1.tgz#1ca6ffeddbcef1715dd7aae25c7616f9ae22932f" +define-properties@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.2.tgz#83a73f2fea569898fb737193c8f873caf6d45c94" + dependencies: + foreach "^2.0.5" + object-keys "^1.0.8" + define-property@^0.2.5: version "0.2.5" resolved "https://registry.yarnpkg.com/define-property/-/define-property-0.2.5.tgz#c35b1ef918ec3c990f9a5bc57be04aacec5c8116" @@ -1845,16 +2101,15 @@ define-property@^2.0.2: is-descriptor "^1.0.2" isobject "^3.0.1" -del@2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/del/-/del-2.0.2.tgz#6cdc68db00282b92d8e82a0ed9fff1d333193424" +del@3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/del/-/del-3.0.0.tgz#53ecf699ffcbcb39637691ab13baf160819766e5" dependencies: - globby "^3.0.0" + globby "^6.1.0" is-path-cwd "^1.0.0" is-path-in-cwd "^1.0.0" - object-assign "^4.0.1" - pify "^2.0.0" - pinkie-promise "^1.0.0" + p-map "^1.1.1" + pify "^3.0.0" rimraf "^2.2.8" del@^2.0.2: @@ -1914,9 +2169,13 @@ detect-libc@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-1.0.3.tgz#fa137c4bd698edf55cd5cd02ac559f91a4c4ba9b" -diff@^2.1.1: - version "2.2.3" - resolved "https://registry.yarnpkg.com/diff/-/diff-2.2.3.tgz#60eafd0d28ee906e4e8ff0a52c1229521033bf99" +detect-newline@2.X, detect-newline@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-2.1.0.tgz#f41f1c10be4b00e87b5f13da680759f2c5bfd3e2" + +diff@^3.2.0: + version "3.5.0" + resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12" diffie-hellman@^5.0.0: version "5.0.3" @@ -1947,31 +2206,36 @@ dmd@^1.4.1: string-tools "^1.0.0" walk-back "^2.0.1" -doctrine@1.2.x: - version "1.2.3" - resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-1.2.3.tgz#6aec6bbd62cf89dd498cae70c0ed9f49da873a6a" +doctrine@1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-1.5.0.tgz#379dce730f6166f76cefa4e6707a159b02c5a6fa" dependencies: esutils "^2.0.2" isarray "^1.0.0" -doctrine@^1.2.1: - version "1.5.0" - resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-1.5.0.tgz#379dce730f6166f76cefa4e6707a159b02c5a6fa" +doctrine@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" dependencies: esutils "^2.0.2" - isarray "^1.0.0" domain-browser@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/domain-browser/-/domain-browser-1.2.0.tgz#3d31f50191a6749dd1375a7f522e823d42e54eda" +domexception@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/domexception/-/domexception-1.0.1.tgz#937442644ca6a31261ef36e3ec677fe805582c90" + dependencies: + webidl-conversions "^4.0.2" + duplexer2@0.0.2: version "0.0.2" resolved "https://registry.yarnpkg.com/duplexer2/-/duplexer2-0.0.2.tgz#c614dcf67e2fb14995a91711e5a617e8a60a31db" dependencies: readable-stream "~1.1.9" -duplexify@^3.2.0: +duplexify@^3.5.1, duplexify@^3.6.0: version "3.6.0" resolved "https://registry.yarnpkg.com/duplexify/-/duplexify-3.6.0.tgz#592903f5d80b38d037220541264d69a198fb3410" dependencies: @@ -2002,6 +2266,10 @@ elliptic@^6.0.0: minimalistic-assert "^1.0.0" minimalistic-crypto-utils "^1.0.0" +emoji-regex@^6.5.1: + version "6.5.1" + resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-6.5.1.tgz#9baea929b155565c11ea41c6626eaa65cef992c2" + emojis-list@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/emojis-list/-/emojis-list-2.1.0.tgz#4daa4d9db00f9819880c79fa457ae5b09a1fd389" @@ -2010,7 +2278,7 @@ encodeurl@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59" -end-of-stream@^1.0.0, end-of-stream@^1.1.0: +end-of-stream@^1.0.0, end-of-stream@^1.1.0, end-of-stream@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz#ed29634d19baba463b6ce6b80a37213eab71ec43" dependencies: @@ -2030,7 +2298,7 @@ enhanced-resolve@~0.9.0: memory-fs "^0.2.0" tapable "^0.1.8" -errno@^0.1.3, errno@~0.1.7: +errno@^0.1.3: version "0.1.7" resolved "https://registry.yarnpkg.com/errno/-/errno-0.1.7.tgz#4684d71779ad39af177e3f007996f7c67c852618" dependencies: @@ -2042,7 +2310,25 @@ error-ex@^1.2.0: dependencies: is-arrayish "^0.2.1" -es5-ext@^0.10.14, es5-ext@^0.10.35, es5-ext@^0.10.9, es5-ext@~0.10.14: +es-abstract@^1.10.0, es-abstract@^1.5.1, es-abstract@^1.6.1, es-abstract@^1.7.0: + version "1.12.0" + resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.12.0.tgz#9dbbdd27c6856f0001421ca18782d786bf8a6165" + dependencies: + es-to-primitive "^1.1.1" + function-bind "^1.1.1" + has "^1.0.1" + is-callable "^1.1.3" + is-regex "^1.0.4" + +es-to-primitive@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.1.1.tgz#45355248a88979034b6792e19bb81f2b7975dd0d" + dependencies: + is-callable "^1.1.1" + is-date-object "^1.0.1" + is-symbol "^1.0.1" + +es5-ext@^0.10.14, es5-ext@^0.10.30, es5-ext@^0.10.35, es5-ext@^0.10.9, es5-ext@~0.10.14, es5-ext@~0.10.2: version "0.10.45" resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.45.tgz#0bfdf7b473da5919d5adf3bd25ceb754fccc3653" dependencies: @@ -2050,7 +2336,7 @@ es5-ext@^0.10.14, es5-ext@^0.10.35, es5-ext@^0.10.9, es5-ext@~0.10.14: es6-symbol "~3.1.1" next-tick "1" -es6-iterator@^2.0.1, es6-iterator@~2.0.1, es6-iterator@~2.0.3: +es6-iterator@^2.0.1, es6-iterator@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" dependencies: @@ -2058,35 +2344,14 @@ es6-iterator@^2.0.1, es6-iterator@~2.0.1, es6-iterator@~2.0.3: es5-ext "^0.10.35" es6-symbol "^3.1.1" -es6-map@^0.1.3: - version "0.1.5" - resolved "https://registry.yarnpkg.com/es6-map/-/es6-map-0.1.5.tgz#9136e0503dcc06a301690f0bb14ff4e364e949f0" - dependencies: - d "1" - es5-ext "~0.10.14" - es6-iterator "~2.0.1" - es6-set "~0.1.5" - es6-symbol "~3.1.1" - event-emitter "~0.3.5" - -es6-set@^0.1.4, es6-set@~0.1.5: - version "0.1.5" - resolved "https://registry.yarnpkg.com/es6-set/-/es6-set-0.1.5.tgz#d2b3ec5d4d800ced818db538d28974db0a73ccb1" - dependencies: - d "1" - es5-ext "~0.10.14" - es6-iterator "~2.0.1" - es6-symbol "3.1.1" - event-emitter "~0.3.5" - -es6-symbol@*, es6-symbol@3.1.1, es6-symbol@^3.1.1, es6-symbol@~3.1.1: +es6-symbol@^3.1.1, es6-symbol@~3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.1.tgz#bf00ef4fdab6ba1b46ecb7b629b4c7ed5715cc77" dependencies: d "1" es5-ext "~0.10.14" -es6-weak-map@^2.0.1: +es6-weak-map@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/es6-weak-map/-/es6-weak-map-2.0.2.tgz#5e3ab32251ffd1538a1f8e5ffa1357772f92d96f" dependencies: @@ -2099,22 +2364,11 @@ escape-html@~1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/escape-html/-/escape-html-1.0.3.tgz#0258eae4d3d0c0974de1c169188ef0051d1d1988" -escape-string-regexp@^1.0.0, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5, escape-string-regexp@~1.0.5: +escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5, escape-string-regexp@~1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" -escodegen@1.8.x: - version "1.8.1" - resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.8.1.tgz#5a5b53af4693110bebb0867aa3430dd3b70a1018" - dependencies: - esprima "^2.7.1" - estraverse "^1.9.1" - esutils "^2.0.2" - optionator "^0.8.1" - optionalDependencies: - source-map "~0.2.0" - -escodegen@^1.6.1: +escodegen@^1.9.0: version "1.10.0" resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.10.0.tgz#f647395de22519fbd0d928ffcf1d17e0dec2603e" dependencies: @@ -2125,109 +2379,154 @@ escodegen@^1.6.1: optionalDependencies: source-map "~0.6.1" -escope@^3.6.0: - version "3.6.0" - resolved "https://registry.yarnpkg.com/escope/-/escope-3.6.0.tgz#e01975e812781a163a6dadfdd80398dc64c889c3" +eslint-config-airbnb-base@^13.0.0: + version "13.0.0" + resolved "https://registry.yarnpkg.com/eslint-config-airbnb-base/-/eslint-config-airbnb-base-13.0.0.tgz#2ee6279c4891128e49d6445b24aa13c2d1a21450" dependencies: - es6-map "^0.1.3" - es6-weak-map "^2.0.1" - esrecurse "^4.1.0" - estraverse "^4.1.1" + eslint-restricted-globals "^0.1.1" + object.assign "^4.1.0" + object.entries "^1.0.4" -eslint-config-airbnb-base@^1.0.2: - version "1.0.4" - resolved "https://registry.yarnpkg.com/eslint-config-airbnb-base/-/eslint-config-airbnb-base-1.0.4.tgz#bc5420890bc6442cf15277c9a4a281fc1317f8a6" +eslint-config-airbnb@17.0.0: + version "17.0.0" + resolved "https://registry.yarnpkg.com/eslint-config-airbnb/-/eslint-config-airbnb-17.0.0.tgz#1bb8c4255483320bb68c3b614f71ae6058b0b2db" + dependencies: + eslint-config-airbnb-base "^13.0.0" + object.assign "^4.1.0" + object.entries "^1.0.4" -eslint-config-airbnb@8.0.0: - version "8.0.0" - resolved "https://registry.yarnpkg.com/eslint-config-airbnb/-/eslint-config-airbnb-8.0.0.tgz#2e539826262e6367525960d5a0d53d32b263af90" +eslint-import-resolver-node@^0.3.1: + version "0.3.2" + resolved "https://registry.yarnpkg.com/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.2.tgz#58f15fb839b8d0576ca980413476aab2472db66a" dependencies: - eslint-config-airbnb-base "^1.0.2" + debug "^2.6.9" + resolve "^1.5.0" -eslint-import-resolver-node@^0.2.0: - version "0.2.3" - resolved "https://registry.yarnpkg.com/eslint-import-resolver-node/-/eslint-import-resolver-node-0.2.3.tgz#5add8106e8c928db2cba232bcd9efa846e3da16c" +eslint-loader@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/eslint-loader/-/eslint-loader-2.0.0.tgz#d136619b5c684e36531ffc28c60a56e404608f5d" dependencies: - debug "^2.2.0" + loader-fs-cache "^1.0.0" + loader-utils "^1.0.2" object-assign "^4.0.1" - resolve "^1.1.6" + object-hash "^1.1.4" + rimraf "^2.6.1" -eslint-loader@1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/eslint-loader/-/eslint-loader-1.2.1.tgz#67b1663497585ea2678fcdd5171653ef7b110d20" +eslint-module-utils@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/eslint-module-utils/-/eslint-module-utils-2.2.0.tgz#b270362cd88b1a48ad308976ce7fa54e98411746" dependencies: - loader-utils "^0.2.7" - object-assign "^4.0.1" + debug "^2.6.8" + pkg-dir "^1.0.0" -eslint-plugin-import@1.6.1: - version "1.6.1" - resolved "https://registry.yarnpkg.com/eslint-plugin-import/-/eslint-plugin-import-1.6.1.tgz#856cd78d02a294ff7e45ed6f4cc917ae3736f29b" - dependencies: - builtin-modules "^1.1.1" - doctrine "1.2.x" - es6-map "^0.1.3" - es6-set "^0.1.4" - es6-symbol "*" - eslint-import-resolver-node "^0.2.0" - lodash.cond "^4.3.0" - lodash.endswith "^4.0.1" - lodash.find "^4.3.0" - object-assign "^4.0.1" - pkg-up "^1.0.0" +eslint-plugin-import@2.13.0: + version "2.13.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-import/-/eslint-plugin-import-2.13.0.tgz#df24f241175e312d91662dc91ca84064caec14ed" + dependencies: + contains-path "^0.1.0" + debug "^2.6.8" + doctrine "1.5.0" + eslint-import-resolver-node "^0.3.1" + eslint-module-utils "^2.2.0" + has "^1.0.1" + lodash "^4.17.4" + minimatch "^3.0.3" + read-pkg-up "^2.0.0" + resolve "^1.6.0" + +eslint-plugin-jsx-a11y@6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.1.0.tgz#569f6f2d29546cab82cedaa077ec829693b0c42d" + dependencies: + aria-query "^3.0.0" + array-includes "^3.0.3" + ast-types-flow "^0.0.7" + axobject-query "^2.0.1" + damerau-levenshtein "^1.0.4" + emoji-regex "^6.5.1" + has "^1.0.3" + jsx-ast-utils "^2.0.1" + +eslint-plugin-react@7.10.0: + version "7.10.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.10.0.tgz#af5c1fef31c4704db02098f9be18202993828b50" + dependencies: + doctrine "^2.1.0" + has "^1.0.3" + jsx-ast-utils "^2.0.1" + prop-types "^15.6.2" + +eslint-restricted-globals@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/eslint-restricted-globals/-/eslint-restricted-globals-0.1.1.tgz#35f0d5cbc64c2e3ed62e93b4b1a7af05ba7ed4d7" -eslint-plugin-jsx-a11y@1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-1.0.4.tgz#32799fd59088e4340c3cc954de860132a8d04d3c" +eslint-scope@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-4.0.0.tgz#50bf3071e9338bcdc43331794a0cb533f0136172" dependencies: - object-assign "^4.0.1" + esrecurse "^4.1.0" + estraverse "^4.1.1" -eslint-plugin-react@5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-5.0.1.tgz#5a58c5228cba74202e45a8a4d6351ffbb0ea75b9" +eslint-scope@~3.7.1: + version "3.7.1" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.1.tgz#3d63c3edfda02e06e01a452ad88caacc7cdcb6e8" + dependencies: + esrecurse "^4.1.0" + estraverse "^4.1.1" + +eslint-visitor-keys@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" -eslint@2.9.0: - version "2.9.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-2.9.0.tgz#5b3fdb7497bb042e2747e3d1fe95f404dca39a60" +eslint@5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-5.0.1.tgz#109b90ab7f7a736f54e0f341c8bb9d09777494c3" dependencies: - chalk "^1.1.3" - concat-stream "^1.4.6" - debug "^2.1.1" - doctrine "^1.2.1" - es6-map "^0.1.3" - escope "^3.6.0" - espree "3.1.4" - estraverse "^4.2.0" + ajv "^6.5.0" + babel-code-frame "^6.26.0" + chalk "^2.1.0" + cross-spawn "^6.0.5" + debug "^3.1.0" + doctrine "^2.1.0" + eslint-scope "^4.0.0" + eslint-visitor-keys "^1.0.0" + espree "^4.0.0" + esquery "^1.0.1" esutils "^2.0.2" - file-entry-cache "^1.1.1" - glob "^7.0.3" - globals "^9.2.0" - ignore "^3.1.2" + file-entry-cache "^2.0.0" + functional-red-black-tree "^1.0.1" + glob "^7.1.2" + globals "^11.5.0" + ignore "^3.3.3" imurmurhash "^0.1.4" - inquirer "^0.12.0" - is-my-json-valid "^2.10.0" - is-resolvable "^1.0.0" - js-yaml "^3.5.1" - json-stable-stringify "^1.0.0" - lodash "^4.0.0" - mkdirp "^0.5.0" - optionator "^0.8.1" - path-is-absolute "^1.0.0" - path-is-inside "^1.0.1" - pluralize "^1.2.1" - progress "^1.1.8" - require-uncached "^1.0.2" - shelljs "^0.6.0" - strip-json-comments "~1.0.1" - table "^3.7.8" - text-table "~0.2.0" - user-home "^2.0.0" - -espree@3.1.4: - version "3.1.4" - resolved "https://registry.yarnpkg.com/espree/-/espree-3.1.4.tgz#0726d7ac83af97a7c8498da9b363a3609d2a68a1" - dependencies: - acorn "^3.1.0" - acorn-jsx "^3.0.0" + inquirer "^5.2.0" + is-resolvable "^1.1.0" + js-yaml "^3.11.0" + json-stable-stringify-without-jsonify "^1.0.1" + levn "^0.3.0" + lodash "^4.17.5" + minimatch "^3.0.4" + mkdirp "^0.5.1" + natural-compare "^1.4.0" + optionator "^0.8.2" + path-is-inside "^1.0.2" + pluralize "^7.0.0" + progress "^2.0.0" + regexpp "^1.1.0" + require-uncached "^1.0.3" + semver "^5.5.0" + string.prototype.matchall "^2.0.0" + strip-ansi "^4.0.0" + strip-json-comments "^2.0.1" + table "^4.0.3" + text-table "^0.2.0" + +espree@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/espree/-/espree-4.0.0.tgz#253998f20a0f82db5d866385799d912a83a36634" + dependencies: + acorn "^5.6.0" + acorn-jsx "^4.1.1" espree@~3.1.7: version "3.1.7" @@ -2236,10 +2535,6 @@ espree@~3.1.7: acorn "^3.3.0" acorn-jsx "^3.0.0" -esprima@2.7.x, esprima@^2.7.1: - version "2.7.3" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-2.7.3.tgz#96e3b70d5779f6ad49cd032673d1c312767ba581" - esprima@^3.1.3: version "3.1.3" resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633" @@ -2248,17 +2543,19 @@ esprima@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.0.tgz#4499eddcd1110e0b218bacf2fa7f7f59f55ca804" +esquery@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" + dependencies: + estraverse "^4.0.0" + esrecurse@^4.1.0: version "4.2.1" resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.1.tgz#007a3b9fdbc2b3bb87e4879ea19c92fdbd3942cf" dependencies: estraverse "^4.1.0" -estraverse@^1.9.1: - version "1.9.3" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-1.9.3.tgz#af67f2dc922582415950926091a4005d29c9bb44" - -estraverse@^4.1.0, estraverse@^4.1.1, estraverse@^4.2.0: +estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1, estraverse@^4.2.0: version "4.2.0" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13" @@ -2270,7 +2567,7 @@ etag@~1.8.1: version "1.8.1" resolved "https://registry.yarnpkg.com/etag/-/etag-1.8.1.tgz#41ae2eeb65efa62268aebfea83ac7d79299b0887" -event-emitter@~0.3.5: +event-emitter@^0.3.5: version "0.3.5" resolved "https://registry.yarnpkg.com/event-emitter/-/event-emitter-0.3.5.tgz#df8c69eef1647923c7157b9ce83840610b02cc39" dependencies: @@ -2304,9 +2601,21 @@ exec-sh@^0.2.0: dependencies: merge "^1.2.0" -exit-hook@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/exit-hook/-/exit-hook-1.1.1.tgz#f05ca233b48c05d54fff07765df8507e95c02ff8" +execa@^0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/execa/-/execa-0.7.0.tgz#944becd34cc41ee32a63a9faf27ad5a65fc59777" + dependencies: + cross-spawn "^5.0.1" + get-stream "^3.0.0" + is-stream "^1.1.0" + npm-run-path "^2.0.0" + p-finally "^1.0.0" + signal-exit "^3.0.0" + strip-eof "^1.0.0" + +exit@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c" expand-brackets@^0.1.4: version "0.1.5" @@ -2338,6 +2647,17 @@ expand-tilde@^2.0.0, expand-tilde@^2.0.2: dependencies: homedir-polyfill "^1.0.1" +expect@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/expect/-/expect-23.3.0.tgz#ecb051adcbdc40ac4db576c16067f12fdb13cc61" + dependencies: + ansi-styles "^3.2.0" + jest-diff "^23.2.0" + jest-get-type "^22.1.0" + jest-matcher-utils "^23.2.0" + jest-message-util "^23.3.0" + jest-regex-util "^23.3.0" + express@^4.13.3: version "4.16.3" resolved "https://registry.yarnpkg.com/express/-/express-4.16.3.tgz#6af8a502350db3246ecc4becf6b5a34d22f7ed53" @@ -2390,6 +2710,14 @@ extend@^3.0.0, extend@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" +external-editor@^2.1.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.2.0.tgz#045511cfd8d133f3846673d1047c154e214ad3d5" + dependencies: + chardet "^0.4.0" + iconv-lite "^0.4.17" + tmp "^0.0.33" + extglob@^0.3.1: version "0.3.2" resolved "https://registry.yarnpkg.com/extglob/-/extglob-0.3.2.tgz#2e18ff3d2f49ab2765cec9023f011daa8d8349a1" @@ -2429,6 +2757,10 @@ fast-deep-equal@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.1.0.tgz#c053477817c86b51daa853c81e059b733d023614" +fast-deep-equal@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz#7b05218ddf9667bf7f370bf7fdb2cb15fdd0aa49" + fast-json-stable-stringify@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" @@ -2449,12 +2781,6 @@ faye-websocket@~0.11.0: dependencies: websocket-driver ">=0.5.1" -fb-watchman@^1.9.0: - version "1.9.2" - resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-1.9.2.tgz#a24cf47827f82d38fb59a69ad70b76e3b6ae7383" - dependencies: - bser "1.0.2" - fb-watchman@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-2.0.0.tgz#54e9abf7dfa2f26cd9b1636c588c1afc05de5d58" @@ -2467,16 +2793,15 @@ feature-detect-es6@^1.2.0, feature-detect-es6@^1.3.0, feature-detect-es6@^1.3.1: dependencies: array-back "^1.0.4" -figures@^1.3.5: - version "1.7.0" - resolved "https://registry.yarnpkg.com/figures/-/figures-1.7.0.tgz#cbe1e3affcf1cd44b80cadfed28dc793a9701d2e" +figures@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/figures/-/figures-2.0.0.tgz#3ab1a2d2a62c8bfb431a0c94cb797a2fce27c962" dependencies: escape-string-regexp "^1.0.5" - object-assign "^4.1.0" -file-entry-cache@^1.1.1: - version "1.3.1" - resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-1.3.1.tgz#44c61ea607ae4be9c1402f41f44270cbfe334ff8" +file-entry-cache@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" dependencies: flat-cache "^1.2.1" object-assign "^4.0.1" @@ -2499,6 +2824,13 @@ filename-regex@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/filename-regex/-/filename-regex-2.0.1.tgz#c1c4b9bee3e09725ddb106b75c1e301fe2f18b26" +fileset@^2.0.2: + version "2.0.3" + resolved "https://registry.yarnpkg.com/fileset/-/fileset-2.0.3.tgz#8e7548a96d3cc2327ee5e674168723a333bba2a0" + dependencies: + glob "^7.0.3" + minimatch "^3.0.3" + fill-range@^2.1.0: version "2.2.4" resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-2.2.4.tgz#eb1e773abb056dcd8df2bfdf6af59b8b3a936565" @@ -2536,6 +2868,22 @@ finalhandler@1.1.1: statuses "~1.4.0" unpipe "~1.0.0" +find-cache-dir@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/find-cache-dir/-/find-cache-dir-0.1.1.tgz#c8defae57c8a52a8a784f9e31c57c742e993a0b9" + dependencies: + commondir "^1.0.1" + mkdirp "^0.5.1" + pkg-dir "^1.0.0" + +find-cache-dir@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/find-cache-dir/-/find-cache-dir-1.0.0.tgz#9288e3e9e3cc3748717d39eade17cf71fc30ee6f" + dependencies: + commondir "^1.0.1" + make-dir "^1.0.0" + pkg-dir "^2.0.0" + find-index@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/find-index/-/find-index-0.1.1.tgz#675d358b2ca3892d795a1ab47232f8b6e2e0dde4" @@ -2554,14 +2902,11 @@ find-up@^1.0.0: path-exists "^2.0.0" pinkie-promise "^2.0.0" -find-versions@^1.0.0: - version "1.2.1" - resolved "https://registry.yarnpkg.com/find-versions/-/find-versions-1.2.1.tgz#cbde9f12e38575a0af1be1b9a2c5d5fd8f186b62" +find-up@^2.0.0, find-up@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-2.1.0.tgz#45d1b7e506c717ddd482775a2b77920a3c0c57a7" dependencies: - array-uniq "^1.0.0" - get-stdin "^4.0.1" - meow "^3.5.0" - semver-regex "^1.0.0" + locate-path "^2.0.0" findup-sync@^2.0.0: version "2.0.0" @@ -2599,14 +2944,7 @@ flat-cache@^1.2.1: graceful-fs "^4.1.2" write "^0.2.1" -follow-redirects@0.0.7: - version "0.0.7" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-0.0.7.tgz#34b90bab2a911aa347571da90f22bd36ecd8a919" - dependencies: - debug "^2.2.0" - stream-consume "^0.1.0" - -follow-redirects@^1.0.0: +follow-redirects@^1.0.0, follow-redirects@^1.3.0: version "1.5.0" resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.5.0.tgz#234f49cf770b7f35b40e790f636ceba0c3a0ab77" dependencies: @@ -2628,6 +2966,10 @@ for-own@^1.0.0: dependencies: for-in "^1.0.1" +foreach@^2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/foreach/-/foreach-2.0.5.tgz#0bee005018aeb260d0a3af3ae658dd0136ec1b99" + forever-agent@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" @@ -2660,9 +3002,9 @@ fs-minipass@^1.2.5: dependencies: minipass "^2.2.1" -fs-readdir-recursive@^0.1.0: - version "0.1.2" - resolved "https://registry.yarnpkg.com/fs-readdir-recursive/-/fs-readdir-recursive-0.1.2.tgz#315b4fb8c1ca5b8c47defef319d073dad3568059" +fs-readdir-recursive@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/fs-readdir-recursive/-/fs-readdir-recursive-1.1.0.tgz#e32fc030a2ccee44a6b5371308da54be0b397d27" fs-then-native@^1.0.2: version "1.0.2" @@ -2674,13 +3016,21 @@ fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" -fsevents@^1.0.0: +fsevents@^1.0.0, fsevents@^1.2.3: version "1.2.4" resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.4.tgz#f41dcb1af2582af3692da36fc55cbd8e1041c426" dependencies: nan "^2.9.2" node-pre-gyp "^0.10.0" +function-bind@^1.1.0, function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + +functional-red-black-tree@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" + gauge@~2.7.3: version "2.7.4" resolved "https://registry.yarnpkg.com/gauge/-/gauge-2.7.4.tgz#2c03405c7538c39d7eb37b317022e325fb018bf7" @@ -2700,19 +3050,13 @@ gaze@^0.5.1: dependencies: globule "~0.1.0" -generate-function@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/generate-function/-/generate-function-2.0.0.tgz#6858fe7c0969b7d4e9093337647ac79f60dfbe74" - -generate-object-property@^1.1.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/generate-object-property/-/generate-object-property-1.2.0.tgz#9c0e1c40308ce804f4783618b937fa88f99d50d0" - dependencies: - is-property "^1.0.0" +get-caller-file@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.2.tgz#f702e63127e7e231c160a80c1554acb70d5047e5" -get-stdin@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/get-stdin/-/get-stdin-4.0.1.tgz#b968c6b0a04384324902e8bf1a5df32579a450fe" +get-stream@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-3.0.0.tgz#8e943d1358dc37555054ecbe2edb05aa174ede14" get-value@^2.0.3, get-value@^2.0.6: version "2.0.6" @@ -2737,6 +3081,13 @@ glob-parent@^2.0.0: dependencies: is-glob "^2.0.0" +glob-parent@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-3.1.0.tgz#9e6af6299d8d3bd2bd40430832bd113df906c5ae" + dependencies: + is-glob "^3.1.0" + path-dirname "^1.0.0" + glob-stream@^3.1.5: version "3.1.18" resolved "https://registry.yarnpkg.com/glob-stream/-/glob-stream-3.1.18.tgz#9170a5f12b790306fdfe598f313f8f7954fd143b" @@ -2748,6 +3099,21 @@ glob-stream@^3.1.5: through2 "^0.6.1" unique-stream "^1.0.0" +glob-stream@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/glob-stream/-/glob-stream-6.1.0.tgz#7045c99413b3eb94888d83ab46d0b404cc7bdde4" + dependencies: + extend "^3.0.0" + glob "^7.1.1" + glob-parent "^3.1.0" + is-negated-glob "^1.0.0" + ordered-read-streams "^1.0.0" + pumpify "^1.3.5" + readable-stream "^2.1.5" + remove-trailing-separator "^1.0.1" + to-absolute-glob "^2.0.0" + unique-stream "^2.0.2" + glob-watcher@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/glob-watcher/-/glob-watcher-0.0.6.tgz#b95b4a8df74b39c83298b0c05c978b4d9a3b710b" @@ -2769,17 +3135,7 @@ glob@^4, glob@^4.3.1: minimatch "^2.0.1" once "^1.3.0" -glob@^5.0.15, glob@^5.0.3, glob@^5.0.5: - version "5.0.15" - resolved "https://registry.yarnpkg.com/glob/-/glob-5.0.15.tgz#1bc936b9e02f4a603fcc222ecf7633d30b8b93b1" - dependencies: - inflight "^1.0.4" - inherits "2" - minimatch "2 || 3" - once "^1.3.0" - path-is-absolute "^1.0.0" - -glob@^7.0.3, glob@^7.0.5, glob@^7.1.0: +glob@^7.0.3, glob@^7.0.5, glob@^7.1.0, glob@^7.1.1, glob@^7.1.2: version "7.1.2" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" dependencies: @@ -2816,27 +3172,30 @@ global-prefix@^1.0.1: is-windows "^1.0.1" which "^1.2.14" -globals@^9.18.0, globals@^9.2.0: +globals@^11.1.0, globals@^11.5.0: + version "11.7.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-11.7.0.tgz#a583faa43055b1aca771914bf68258e2fc125673" + +globals@^9.18.0: version "9.18.0" resolved "https://registry.yarnpkg.com/globals/-/globals-9.18.0.tgz#aa3896b3e69b487f17e31ed2143d69a8e30c2d8a" -globby@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/globby/-/globby-3.0.1.tgz#2094af8421e19152150d5893eb6416b312d9a22f" +globby@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/globby/-/globby-5.0.0.tgz#ebd84667ca0dbb330b99bcfc68eac2bc54370e0d" dependencies: array-union "^1.0.1" arrify "^1.0.0" - glob "^5.0.3" + glob "^7.0.3" object-assign "^4.0.1" pify "^2.0.0" - pinkie-promise "^1.0.0" + pinkie-promise "^2.0.0" -globby@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/globby/-/globby-5.0.0.tgz#ebd84667ca0dbb330b99bcfc68eac2bc54370e0d" +globby@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/globby/-/globby-6.1.0.tgz#f5a6d70e8395e21c858fb0489d64df02424d506c" dependencies: array-union "^1.0.1" - arrify "^1.0.0" glob "^7.0.3" object-assign "^4.0.1" pify "^2.0.0" @@ -2856,27 +3215,29 @@ glogg@^1.0.0: dependencies: sparkles "^1.0.0" +graceful-fs@4.X, graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.4, graceful-fs@^4.1.9: + version "4.1.11" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658" + graceful-fs@^3.0.0: version "3.0.11" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-3.0.11.tgz#7613c778a1afea62f25c630a086d7f3acbbdd818" dependencies: natives "^1.1.0" -graceful-fs@^4.1.2, graceful-fs@^4.1.3, graceful-fs@^4.1.4, graceful-fs@^4.1.9: - version "4.1.11" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658" - graceful-fs@~1.2.0: version "1.2.3" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-1.2.3.tgz#15a4806a57547cb2d2dbf27f42e89a8c3451b364" -gulp-babel@6.1.2: - version "6.1.2" - resolved "https://registry.yarnpkg.com/gulp-babel/-/gulp-babel-6.1.2.tgz#7c0176e4ba3f244c60588a0c4b320a45d1adefce" +growly@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/growly/-/growly-1.3.0.tgz#f10748cbe76af964b7c96c93c6bcc28af120c081" + +gulp-babel@7.0.1: + version "7.0.1" + resolved "https://registry.yarnpkg.com/gulp-babel/-/gulp-babel-7.0.1.tgz#b9c8e29fa376b36c57989db820fc1c1715bb47cb" dependencies: - babel-core "^6.0.2" - gulp-util "^3.0.0" - object-assign "^4.0.1" + plugin-error "^1.0.1" replace-ext "0.0.1" through2 "^2.0.0" vinyl-sourcemaps-apply "^0.2.0" @@ -2889,41 +3250,27 @@ gulp-jsdoc-to-markdown@1.2.2: jsdoc-to-markdown "^1.3.4" through2 "^2.0.1" -gulp-rename@1.2.2: - version "1.2.2" - resolved "https://registry.yarnpkg.com/gulp-rename/-/gulp-rename-1.2.2.tgz#3ad4428763f05e2764dec1c67d868db275687817" - -gulp-sourcemaps@1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/gulp-sourcemaps/-/gulp-sourcemaps-1.6.0.tgz#b86ff349d801ceb56e1d9e7dc7bbcb4b7dee600c" - dependencies: - convert-source-map "^1.1.1" - graceful-fs "^4.1.2" - strip-bom "^2.0.0" - through2 "^2.0.0" - vinyl "^1.0.0" - -gulp-util@3.0.4: - version "3.0.4" - resolved "https://registry.yarnpkg.com/gulp-util/-/gulp-util-3.0.4.tgz#ec73553090fdb23d88fa02812ad1b61225854881" - dependencies: - array-differ "^1.0.0" - array-uniq "^1.0.2" - beeper "^1.0.0" - chalk "^1.0.0" - dateformat "^1.0.11" - lodash._reescape "^3.0.0" - lodash._reevaluate "^3.0.0" - lodash._reinterpolate "^3.0.0" - lodash.template "^3.0.0" - minimist "^1.1.0" - multipipe "^0.1.2" - object-assign "^2.0.0" - replace-ext "0.0.1" - through2 "^0.6.3" - vinyl "^0.4.3" +gulp-rename@1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/gulp-rename/-/gulp-rename-1.3.0.tgz#2e789d8f563ab0c924eeb62967576f37ff4cb826" -gulp-util@^3.0.0, gulp-util@^3.0.7: +gulp-sourcemaps@2.6.4: + version "2.6.4" + resolved "https://registry.yarnpkg.com/gulp-sourcemaps/-/gulp-sourcemaps-2.6.4.tgz#cbb2008450b1bcce6cd23bf98337be751bf6e30a" + dependencies: + "@gulp-sourcemaps/identity-map" "1.X" + "@gulp-sourcemaps/map-sources" "1.X" + acorn "5.X" + convert-source-map "1.X" + css "2.X" + debug-fabulous "1.X" + detect-newline "2.X" + graceful-fs "4.X" + source-map "~0.6.0" + strip-bom-string "1.X" + through2 "2.X" + +gulp-util@3.0.8, gulp-util@^3.0.0, gulp-util@^3.0.7: version "3.0.8" resolved "https://registry.yarnpkg.com/gulp-util/-/gulp-util-3.0.8.tgz#0054e1e744502e27c04c187c3ecc505dd54bbb4f" dependencies: @@ -2946,19 +3293,19 @@ gulp-util@^3.0.0, gulp-util@^3.0.7: through2 "^2.0.0" vinyl "^0.5.0" -gulp@3.8.11: - version "3.8.11" - resolved "https://registry.yarnpkg.com/gulp/-/gulp-3.8.11.tgz#d557e0a7283eb4136491969b0497767972f1d28a" +gulp@3.9.1: + version "3.9.1" + resolved "https://registry.yarnpkg.com/gulp/-/gulp-3.9.1.tgz#571ce45928dd40af6514fc4011866016c13845b4" dependencies: archy "^1.0.0" - chalk "^0.5.0" + chalk "^1.0.0" deprecated "^0.0.1" gulp-util "^3.0.0" - interpret "^0.3.2" - liftoff "^2.0.1" + interpret "^1.0.0" + liftoff "^2.1.0" minimist "^1.1.0" orchestrator "^0.3.0" - pretty-hrtime "^0.2.0" + pretty-hrtime "^1.0.0" semver "^4.1.0" tildify "^1.0.0" v8flags "^2.0.2" @@ -3006,7 +3353,7 @@ handlebars@^3.0.0, handlebars@^3.0.3: optionalDependencies: uglify-js "~2.3" -handlebars@^4.0.1: +handlebars@^4.0.3: version "4.0.11" resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.0.11.tgz#630a35dfe0294bc281edae6ffc5d329fc7982dcc" dependencies: @@ -3027,12 +3374,6 @@ har-validator@~5.0.3: ajv "^5.1.0" har-schema "^2.0.0" -has-ansi@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-0.1.0.tgz#84f265aae8c0e6a88a12d7022894b7568894c62e" - dependencies: - ansi-regex "^0.2.0" - has-ansi@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91" @@ -3043,12 +3384,20 @@ has-flag@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-1.0.0.tgz#9d9e793165ce017a00f00418c43f942a7b1d11fa" +has-flag@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" + has-gulplog@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/has-gulplog/-/has-gulplog-0.1.0.tgz#6414c82913697da51590397dafb12f22967811ce" dependencies: sparkles "^1.0.0" +has-symbols@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.0.tgz#ba1a8f1af2a0fc39650f5c850367704122063b44" + has-unicode@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/has-unicode/-/has-unicode-2.0.1.tgz#e0e6fe6a28cf51138855e086d1691e771de2a8b9" @@ -3080,6 +3429,12 @@ has-values@^1.0.0: is-number "^3.0.0" kind-of "^4.0.0" +has@^1.0.1, has@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" + dependencies: + function-bind "^1.1.1" + hash-base@^3.0.0: version "3.0.4" resolved "https://registry.yarnpkg.com/hash-base/-/hash-base-3.0.4.tgz#5fc8686847ecd73499403319a6b0a3f3f6ae4918" @@ -3094,13 +3449,13 @@ hash.js@^1.0.0, hash.js@^1.0.3: inherits "^2.0.3" minimalistic-assert "^1.0.0" -help-me@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/help-me/-/help-me-0.1.0.tgz#0fb3a40537ad5265b6b49413022c60d35b49539a" +help-me@^1.0.1: + version "1.1.0" + resolved "https://registry.yarnpkg.com/help-me/-/help-me-1.1.0.tgz#8f2d508d0600b4a456da2f086556e7e5c056a3c6" dependencies: - concat-stream "^1.4.7" - pump "^1.0.0" - readable-stream "^1.0.33" + callback-stream "^1.0.2" + glob-stream "^6.1.0" + through2 "^2.0.1" xtend "^4.0.0" hmac-drbg@^1.0.0: @@ -3132,7 +3487,7 @@ hosted-git-info@^2.1.4: version "2.6.1" resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.6.1.tgz#6e4cee78b01bb849dcf93527708c69fdbee410df" -html-encoding-sniffer@^1.0.1: +html-encoding-sniffer@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/html-encoding-sniffer/-/html-encoding-sniffer-1.0.2.tgz#e70d84b94da53aa375e11fe3a351be6642ca46f8" dependencies: @@ -3187,19 +3542,19 @@ https-browserify@0.0.0: version "0.0.0" resolved "https://registry.yarnpkg.com/https-browserify/-/https-browserify-0.0.0.tgz#b3ffdfe734b2a3d4a9efd58e8654c91fce86eafd" -https-browserify@0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/https-browserify/-/https-browserify-0.0.1.tgz#3f91365cabe60b77ed0ebba24b454e3e09d95a82" +https-browserify@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/https-browserify/-/https-browserify-1.0.0.tgz#ec06c10e0a34c0f2faf199f7fd7fc78fffd03c73" -humps@1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/humps/-/humps-1.1.0.tgz#99a05cc80b13ae754a3d1e1a92182f271ef1d98f" +humps@2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/humps/-/humps-2.0.1.tgz#dd02ea6081bd0568dc5d073184463957ba9ef9aa" iconv-lite@0.4.19: version "0.4.19" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.19.tgz#f7468f60135f5e5dad3399c0a81be9a1603a082b" -iconv-lite@^0.4.4: +iconv-lite@^0.4.17, iconv-lite@^0.4.4: version "0.4.23" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.23.tgz#297871f63be507adcfbfca715d0cd0eed84e9a63" dependencies: @@ -3215,20 +3570,21 @@ ignore-walk@^3.0.1: dependencies: minimatch "^3.0.4" -ignore@^3.1.2: +ignore@^3.3.3: version "3.3.10" resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" +import-local@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/import-local/-/import-local-1.0.0.tgz#5e4ffdc03f4fe6c009c6729beb29631c2f8227bc" + dependencies: + pkg-dir "^2.0.0" + resolve-cwd "^2.0.0" + imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" -indent-string@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-2.1.0.tgz#8e2d48348742121b4a8218b7a137e9a52049dc80" - dependencies: - repeating "^2.0.0" - indexof@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/indexof/-/indexof-0.0.1.tgz#82dc336d232b9062179d05ab3293a66059fd435d" @@ -3256,38 +3612,42 @@ ini@^1.3.4, ini@~1.3.0: version "1.3.5" resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.5.tgz#eee25f56db1c9ec6085e0c22778083f596abf927" -inquirer@^0.12.0: - version "0.12.0" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-0.12.0.tgz#1ef2bfd63504df0bc75785fff8c2c41df12f077e" +inquirer@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-5.2.0.tgz#db350c2b73daca77ff1243962e9f22f099685726" dependencies: - ansi-escapes "^1.1.0" - ansi-regex "^2.0.0" - chalk "^1.0.0" - cli-cursor "^1.0.1" + ansi-escapes "^3.0.0" + chalk "^2.0.0" + cli-cursor "^2.1.0" cli-width "^2.0.0" - figures "^1.3.5" + external-editor "^2.1.0" + figures "^2.0.0" lodash "^4.3.0" - readline2 "^1.0.1" - run-async "^0.1.0" - rx-lite "^3.1.2" - string-width "^1.0.1" - strip-ansi "^3.0.0" + mute-stream "0.0.7" + run-async "^2.2.0" + rxjs "^5.5.2" + string-width "^2.1.0" + strip-ansi "^4.0.0" through "^2.3.6" -interpret@^0.3.2: - version "0.3.10" - resolved "https://registry.yarnpkg.com/interpret/-/interpret-0.3.10.tgz#088c25de731c6c5b112a90f0071cfaf459e5a7bb" - interpret@^0.6.4: version "0.6.6" resolved "https://registry.yarnpkg.com/interpret/-/interpret-0.6.6.tgz#fecd7a18e7ce5ca6abfb953e1f86213a49f1625b" -invariant@^2.2.2: +interpret@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.1.0.tgz#7ed1b1410c6a0e0f78cf95d3b8440c63f78b8614" + +invariant@^2.2.0, invariant@^2.2.2: version "2.2.4" resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.4.tgz#610f3c92c9359ce1db616e538008d23ff35158e6" dependencies: loose-envify "^1.0.0" +invert-kv@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" + ipaddr.js@1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.6.0.tgz#e3fa357b773da619f26e95f049d055c72796f86b" @@ -3331,6 +3691,16 @@ is-builtin-module@^1.0.0: dependencies: builtin-modules "^1.0.0" +is-callable@^1.1.1, is-callable@^1.1.3: + version "1.1.4" + resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.4.tgz#1e1adf219e1eeb684d691f9d6a05ff0d30a24d75" + +is-ci@^1.0.10: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-ci/-/is-ci-1.1.0.tgz#247e4162e7860cebbdaf30b774d6b0ac7dcfe7a5" + dependencies: + ci-info "^1.0.0" + is-data-descriptor@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" @@ -3343,6 +3713,10 @@ is-data-descriptor@^1.0.0: dependencies: kind-of "^6.0.0" +is-date-object@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.1.tgz#9aa20eb6aeebbff77fbd33e74ca01b33581d3a16" + is-descriptor@^0.1.0: version "0.1.6" resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-0.1.6.tgz#366d8240dde487ca51823b1ab9f07a10a78251ca" @@ -3403,6 +3777,10 @@ is-fullwidth-code-point@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" +is-generator-fn@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-generator-fn/-/is-generator-fn-1.0.0.tgz#969d49e1bb3329f6bb7f09089be26578b2ddd46a" + is-glob@^2.0.0, is-glob@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-2.0.1.tgz#d096f926a3ded5600f3fdfd91198cb0888c2d863" @@ -3415,19 +3793,9 @@ is-glob@^3.1.0: dependencies: is-extglob "^2.1.0" -is-my-ip-valid@^1.0.0: +is-negated-glob@^1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/is-my-ip-valid/-/is-my-ip-valid-1.0.0.tgz#7b351b8e8edd4d3995d4d066680e664d94696824" - -is-my-json-valid@^2.10.0: - version "2.17.2" - resolved "https://registry.yarnpkg.com/is-my-json-valid/-/is-my-json-valid-2.17.2.tgz#6b2103a288e94ef3de5cf15d29dd85fc4b78d65c" - dependencies: - generate-function "^2.0.0" - generate-object-property "^1.1.0" - is-my-ip-valid "^1.0.0" - jsonpointer "^4.0.0" - xtend "^4.0.0" + resolved "https://registry.yarnpkg.com/is-negated-glob/-/is-negated-glob-1.0.0.tgz#6910bca5da8c95e784b5751b976cf5a10fee36d2" is-number@^2.1.0: version "2.1.0" @@ -3475,9 +3843,15 @@ is-primitive@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-primitive/-/is-primitive-2.0.0.tgz#207bab91638499c07b2adf240a41a87210034575" -is-property@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-property/-/is-property-1.0.2.tgz#57fe1c4e48474edd65b09911f26b1cd4095dda84" +is-promise@^2.1, is-promise@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" + +is-regex@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.0.4.tgz#5517489b547091b0930e095654ced25ee97e9491" + dependencies: + has "^1.0.1" is-relative@^1.0.0: version "1.0.0" @@ -3485,10 +3859,18 @@ is-relative@^1.0.0: dependencies: is-unc-path "^1.0.0" -is-resolvable@^1.0.0: +is-resolvable@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.1.0.tgz#fb18f87ce1feb925169c9a407c19318a3206ed88" +is-stream@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" + +is-symbol@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.1.tgz#3cc59f00025194b6ab2e38dbae6689256b660572" + is-typedarray@^1.0.0, is-typedarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" @@ -3533,104 +3915,356 @@ isstream@~0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" -istanbul@^0.4.2: - version "0.4.5" - resolved "https://registry.yarnpkg.com/istanbul/-/istanbul-0.4.5.tgz#65c7d73d4c4da84d4f3ac310b918fb0b8033733b" - dependencies: - abbrev "1.0.x" - async "1.x" - escodegen "1.8.x" - esprima "2.7.x" - glob "^5.0.15" - handlebars "^4.0.1" - js-yaml "3.x" - mkdirp "0.5.x" - nopt "3.x" - once "1.x" - resolve "1.1.x" - supports-color "^3.1.0" - which "^1.1.1" - wordwrap "^1.0.0" - -jest-cli@12.0.2: - version "12.0.2" - resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-12.0.2.tgz#59552d146c1c0a0fbe729b9b2d351b7a13308f8d" - dependencies: - chalk "^1.1.1" - cover "^0.2.9" - diff "^2.1.1" - graceful-fs "^4.1.3" - istanbul "^0.4.2" - jest-environment-jsdom "^12.0.2" - jest-environment-node "^12.0.2" - jest-haste-map "^12.0.2" - jest-jasmine1 "^12.0.2" - jest-jasmine2 "^12.0.2" - jest-mock "^12.0.2" - jest-util "^12.0.2" - json-stable-stringify "^1.0.0" - lodash.template "^4.2.4" +istanbul-api@^1.3.1: + version "1.3.1" + resolved "https://registry.yarnpkg.com/istanbul-api/-/istanbul-api-1.3.1.tgz#4c3b05d18c0016d1022e079b98dc82c40f488954" + dependencies: + async "^2.1.4" + compare-versions "^3.1.0" + fileset "^2.0.2" + istanbul-lib-coverage "^1.2.0" + istanbul-lib-hook "^1.2.0" + istanbul-lib-instrument "^1.10.1" + istanbul-lib-report "^1.1.4" + istanbul-lib-source-maps "^1.2.4" + istanbul-reports "^1.3.0" + js-yaml "^3.7.0" mkdirp "^0.5.1" - optimist "^0.6.1" - resolve "^1.1.6" - sane "^1.2.0" - which "^1.1.1" - worker-farm "^1.3.1" + once "^1.4.0" -jest-environment-jsdom@^12.0.2: - version "12.1.0" - resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-12.1.0.tgz#d630a61a900efb2a899dfb0d9233a9ae6edba51e" - dependencies: - jest-util "^12.1.0" - jsdom "^9.0.0" +istanbul-lib-coverage@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-1.2.0.tgz#f7d8f2e42b97e37fe796114cb0f9d68b5e3a4341" -jest-environment-node@^12.0.2: - version "12.1.0" - resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-12.1.0.tgz#f81890f895f5e9fc3dd7650248a35f2502c24333" +istanbul-lib-hook@^1.2.0: + version "1.2.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-hook/-/istanbul-lib-hook-1.2.1.tgz#f614ec45287b2a8fc4f07f5660af787575601805" dependencies: - jest-util "^12.1.0" + append-transform "^1.0.0" -jest-haste-map@^12.0.2: - version "12.1.0" - resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-12.1.0.tgz#e26fef9b80a4391145331f64b3f962ecffb2122f" +istanbul-lib-instrument@^1.10.1: + version "1.10.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-1.10.1.tgz#724b4b6caceba8692d3f1f9d0727e279c401af7b" dependencies: - fb-watchman "^1.9.0" - graceful-fs "^4.1.3" - worker-farm "^1.3.1" + babel-generator "^6.18.0" + babel-template "^6.16.0" + babel-traverse "^6.18.0" + babel-types "^6.18.0" + babylon "^6.18.0" + istanbul-lib-coverage "^1.2.0" + semver "^5.3.0" -jest-jasmine1@^12.0.2: - version "12.1.0" - resolved "https://registry.yarnpkg.com/jest-jasmine1/-/jest-jasmine1-12.1.0.tgz#0409044d0384ec765e8a2bc38fd78db5f6c55bff" +istanbul-lib-report@^1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/istanbul-lib-report/-/istanbul-lib-report-1.1.4.tgz#e886cdf505c4ebbd8e099e4396a90d0a28e2acb5" dependencies: - graceful-fs "^4.1.3" - jest-util "^12.1.0" + istanbul-lib-coverage "^1.2.0" + mkdirp "^0.5.1" + path-parse "^1.0.5" + supports-color "^3.1.2" -jest-jasmine2@^12.0.2: - version "12.1.0" - resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-12.1.0.tgz#229c1ecc36d04d71d538bc0133c71d87077112eb" +istanbul-lib-source-maps@^1.2.4: + version "1.2.5" + resolved "https://registry.yarnpkg.com/istanbul-lib-source-maps/-/istanbul-lib-source-maps-1.2.5.tgz#ffe6be4e7ab86d3603e4290d54990b14506fc9b1" dependencies: - graceful-fs "^4.1.3" - jest-util "^12.1.0" + debug "^3.1.0" + istanbul-lib-coverage "^1.2.0" + mkdirp "^0.5.1" + rimraf "^2.6.1" + source-map "^0.5.3" -jest-mock@^12.0.2, jest-mock@^12.1.0: - version "12.1.0" - resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-12.1.0.tgz#472b896294f7b91e23dcddbcb6cfa3e6e4b28049" +istanbul-reports@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/istanbul-reports/-/istanbul-reports-1.3.0.tgz#2f322e81e1d9520767597dca3c20a0cce89a3554" + dependencies: + handlebars "^4.0.3" + +jest-changed-files@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-23.2.0.tgz#a145a6e4b66d0129fc7c99cee134dc937a643d9c" + dependencies: + throat "^4.0.0" + +jest-cli@23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-23.3.0.tgz#307e9be7733443b789a8279d694054d051a9e5e2" + dependencies: + ansi-escapes "^3.0.0" + chalk "^2.0.1" + exit "^0.1.2" + glob "^7.1.2" + graceful-fs "^4.1.11" + import-local "^1.0.0" + is-ci "^1.0.10" + istanbul-api "^1.3.1" + istanbul-lib-coverage "^1.2.0" + istanbul-lib-instrument "^1.10.1" + istanbul-lib-source-maps "^1.2.4" + jest-changed-files "^23.2.0" + jest-config "^23.3.0" + jest-environment-jsdom "^23.3.0" + jest-get-type "^22.1.0" + jest-haste-map "^23.2.0" + jest-message-util "^23.3.0" + jest-regex-util "^23.3.0" + jest-resolve-dependencies "^23.3.0" + jest-runner "^23.3.0" + jest-runtime "^23.3.0" + jest-snapshot "^23.3.0" + jest-util "^23.3.0" + jest-validate "^23.3.0" + jest-watcher "^23.2.0" + jest-worker "^23.2.0" + micromatch "^3.1.10" + node-notifier "^5.2.1" + prompts "^0.1.9" + realpath-native "^1.0.0" + rimraf "^2.5.4" + slash "^1.0.0" + string-length "^2.0.0" + strip-ansi "^4.0.0" + which "^1.2.12" + yargs "^11.0.0" -jest-util@^12.0.2, jest-util@^12.1.0: - version "12.1.0" - resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-12.1.0.tgz#3d3673e81f17e0ec967e9ddc785160a51ab9ec12" +jest-config@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-23.3.0.tgz#bb4d53b70f9500fafddf718d226abb53b13b8323" + dependencies: + babel-core "^6.0.0" + babel-jest "^23.2.0" + chalk "^2.0.1" + glob "^7.1.1" + jest-environment-jsdom "^23.3.0" + jest-environment-node "^23.3.0" + jest-get-type "^22.1.0" + jest-jasmine2 "^23.3.0" + jest-regex-util "^23.3.0" + jest-resolve "^23.2.0" + jest-util "^23.3.0" + jest-validate "^23.3.0" + pretty-format "^23.2.0" + +jest-diff@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-23.2.0.tgz#9f2cf4b51e12c791550200abc16b47130af1062a" + dependencies: + chalk "^2.0.1" + diff "^3.2.0" + jest-get-type "^22.1.0" + pretty-format "^23.2.0" + +jest-docblock@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-23.2.0.tgz#f085e1f18548d99fdd69b20207e6fd55d91383a7" + dependencies: + detect-newline "^2.1.0" + +jest-each@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-23.2.0.tgz#a400f81c857083f50c4f53399b109f12023fb19d" + dependencies: + chalk "^2.0.1" + pretty-format "^23.2.0" + +jest-environment-jsdom@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-23.3.0.tgz#190457f91c9e615454c4186056065db6ed7a4e2a" + dependencies: + jest-mock "^23.2.0" + jest-util "^23.3.0" + jsdom "^11.5.1" + +jest-environment-node@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-23.3.0.tgz#1e8df21c847aa5d03b76573f0dc16fcde5034c32" + dependencies: + jest-mock "^23.2.0" + jest-util "^23.3.0" + +jest-get-type@^22.1.0: + version "22.4.3" + resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-22.4.3.tgz#e3a8504d8479342dd4420236b322869f18900ce4" + +jest-haste-map@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-23.2.0.tgz#d10cbac007c695948c8ef1821a2b2ed2d4f2d4d8" + dependencies: + fb-watchman "^2.0.0" + graceful-fs "^4.1.11" + jest-docblock "^23.2.0" + jest-serializer "^23.0.1" + jest-worker "^23.2.0" + micromatch "^3.1.10" + sane "^2.0.0" + +jest-jasmine2@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-23.3.0.tgz#a8706baac23c8a130d5aa8ef5464a9d49096d1b5" + dependencies: + chalk "^2.0.1" + co "^4.6.0" + expect "^23.3.0" + is-generator-fn "^1.0.0" + jest-diff "^23.2.0" + jest-each "^23.2.0" + jest-matcher-utils "^23.2.0" + jest-message-util "^23.3.0" + jest-snapshot "^23.3.0" + jest-util "^23.3.0" + pretty-format "^23.2.0" + +jest-leak-detector@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-23.2.0.tgz#c289d961dc638f14357d4ef96e0431ecc1aa377d" + dependencies: + pretty-format "^23.2.0" + +jest-matcher-utils@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-23.2.0.tgz#4d4981f23213e939e3cedf23dc34c747b5ae1913" + dependencies: + chalk "^2.0.1" + jest-get-type "^22.1.0" + pretty-format "^23.2.0" + +jest-message-util@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-23.3.0.tgz#bc07b11cec6971fb5dd9de2dfb60ebc22150c160" + dependencies: + "@babel/code-frame" "^7.0.0-beta.35" + chalk "^2.0.1" + micromatch "^3.1.10" + slash "^1.0.0" + stack-utils "^1.0.1" + +jest-mock@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-23.2.0.tgz#ad1c60f29e8719d47c26e1138098b6d18b261134" + +jest-regex-util@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-23.3.0.tgz#5f86729547c2785c4002ceaa8f849fe8ca471bc5" + +jest-resolve-dependencies@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-23.3.0.tgz#8444d3b0b1288b80864d8801ff50b44a4d695d1d" + dependencies: + jest-regex-util "^23.3.0" + jest-snapshot "^23.3.0" + +jest-resolve@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-23.2.0.tgz#a0790ad5a3b99002ab4dbfcbf8d9e2d6a69b3d99" + dependencies: + browser-resolve "^1.11.3" + chalk "^2.0.1" + realpath-native "^1.0.0" + +jest-runner@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-23.3.0.tgz#04c7e458a617501a4875db0d7ffbe0e3cbd43bfb" + dependencies: + exit "^0.1.2" + graceful-fs "^4.1.11" + jest-config "^23.3.0" + jest-docblock "^23.2.0" + jest-haste-map "^23.2.0" + jest-jasmine2 "^23.3.0" + jest-leak-detector "^23.2.0" + jest-message-util "^23.3.0" + jest-runtime "^23.3.0" + jest-util "^23.3.0" + jest-worker "^23.2.0" + source-map-support "^0.5.6" + throat "^4.0.0" + +jest-runtime@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-23.3.0.tgz#4865aab4ceff82f9cec6335fd7ae1422cc1de7df" dependencies: - chalk "^1.1.1" - diff "^2.1.1" - graceful-fs "^4.1.3" - jest-mock "^12.1.0" + babel-core "^6.0.0" + babel-plugin-istanbul "^4.1.6" + chalk "^2.0.1" + convert-source-map "^1.4.0" + exit "^0.1.2" + fast-json-stable-stringify "^2.0.0" + graceful-fs "^4.1.11" + jest-config "^23.3.0" + jest-haste-map "^23.2.0" + jest-message-util "^23.3.0" + jest-regex-util "^23.3.0" + jest-resolve "^23.2.0" + jest-snapshot "^23.3.0" + jest-util "^23.3.0" + jest-validate "^23.3.0" + micromatch "^3.1.10" + realpath-native "^1.0.0" + slash "^1.0.0" + strip-bom "3.0.0" + write-file-atomic "^2.1.0" + yargs "^11.0.0" + +jest-serializer@^23.0.1: + version "23.0.1" + resolved "https://registry.yarnpkg.com/jest-serializer/-/jest-serializer-23.0.1.tgz#a3776aeb311e90fe83fab9e533e85102bd164165" + +jest-snapshot@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-23.3.0.tgz#fc4e9f81e45432d10507e27f50bce60f44d81424" + dependencies: + babel-traverse "^6.0.0" + babel-types "^6.0.0" + chalk "^2.0.1" + jest-diff "^23.2.0" + jest-matcher-utils "^23.2.0" + jest-message-util "^23.3.0" + jest-resolve "^23.2.0" + mkdirp "^0.5.1" + natural-compare "^1.4.0" + pretty-format "^23.2.0" + semver "^5.5.0" + +jest-util@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-23.3.0.tgz#79f35bb0c30100ef611d963ee6b88f8ed873a81d" + dependencies: + callsites "^2.0.0" + chalk "^2.0.1" + graceful-fs "^4.1.11" + is-ci "^1.0.10" + jest-message-util "^23.3.0" mkdirp "^0.5.1" + slash "^1.0.0" + source-map "^0.6.0" + +jest-validate@^23.3.0: + version "23.3.0" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-23.3.0.tgz#d49bea6aad98c30acd2cbb542434798a0cc13f76" + dependencies: + chalk "^2.0.1" + jest-get-type "^22.1.0" + leven "^2.1.0" + pretty-format "^23.2.0" + +jest-watcher@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-23.2.0.tgz#678e852896e919e9d9a0eb4b8baf1ae279620ea9" + dependencies: + ansi-escapes "^3.0.0" + chalk "^2.0.1" + string-length "^2.0.0" + +jest-worker@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-23.2.0.tgz#faf706a8da36fae60eb26957257fa7b5d8ea02b9" + dependencies: + merge-stream "^1.0.1" js-tokens@^3.0.0, js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" -js-yaml@3.x, js-yaml@^3.5.1: +js-yaml@^3.11.0, js-yaml@^3.7.0: version "3.12.0" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.12.0.tgz#eaed656ec8344f10f527c6bfa1b6e2244de167d1" dependencies: @@ -3717,51 +4351,70 @@ jsdoc2md-stats@^1.0.3: app-usage-stats "^0.4.0" feature-detect-es6 "^1.3.1" -jsdom@^9.0.0: - version "9.12.0" - resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-9.12.0.tgz#e8c546fffcb06c00d4833ca84410fed7f8a097d4" +jsdom@^11.5.1: + version "11.11.0" + resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-11.11.0.tgz#df486efad41aee96c59ad7a190e2449c7eb1110e" dependencies: - abab "^1.0.3" - acorn "^4.0.4" - acorn-globals "^3.1.0" + abab "^1.0.4" + acorn "^5.3.0" + acorn-globals "^4.1.0" array-equal "^1.0.0" - content-type-parser "^1.0.1" cssom ">= 0.3.2 < 0.4.0" - cssstyle ">= 0.2.37 < 0.3.0" - escodegen "^1.6.1" - html-encoding-sniffer "^1.0.1" - nwmatcher ">= 1.3.9 < 2.0.0" - parse5 "^1.5.1" - request "^2.79.0" - sax "^1.2.1" - symbol-tree "^3.2.1" - tough-cookie "^2.3.2" - webidl-conversions "^4.0.0" - whatwg-encoding "^1.0.1" - whatwg-url "^4.3.0" - xml-name-validator "^2.0.1" + cssstyle ">= 0.3.1 < 0.4.0" + data-urls "^1.0.0" + domexception "^1.0.0" + escodegen "^1.9.0" + html-encoding-sniffer "^1.0.2" + left-pad "^1.2.0" + nwsapi "^2.0.0" + parse5 "4.0.0" + pn "^1.1.0" + request "^2.83.0" + request-promise-native "^1.0.5" + sax "^1.2.4" + symbol-tree "^3.2.2" + tough-cookie "^2.3.3" + w3c-hr-time "^1.0.1" + webidl-conversions "^4.0.2" + whatwg-encoding "^1.0.3" + whatwg-mimetype "^2.1.0" + whatwg-url "^6.4.1" + ws "^4.0.0" + xml-name-validator "^3.0.0" jsesc@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-1.3.0.tgz#46c3fec8c1892b12b0833db9bc7622176dbab34b" +jsesc@^2.5.1: + version "2.5.1" + resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.1.tgz#e421a2a8e20d6b0819df28908f782526b96dd1fe" + jsesc@~0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d" -json-loader@0.5.2: - version "0.5.2" - resolved "https://registry.yarnpkg.com/json-loader/-/json-loader-0.5.2.tgz#ed79019c4f3778422eccd62427eb526612c6ef40" +json-loader@0.5.7: + version "0.5.7" + resolved "https://registry.yarnpkg.com/json-loader/-/json-loader-0.5.7.tgz#dca14a70235ff82f0ac9a3abeb60d337a365185d" json-schema-traverse@^0.3.0: version "0.3.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz#349a6d44c53a51de89b40805c5d5e59b417d3340" +json-schema-traverse@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" + json-schema@0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" -json-stable-stringify@^1.0.0, json-stable-stringify@^1.0.1: +json-stable-stringify-without-jsonify@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" + +json-stable-stringify@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz#9a759d39c5f2ff503fd5300646ed445f88c4f9af" dependencies: @@ -3775,10 +4428,6 @@ json3@^3.3.2: version "3.3.2" resolved "https://registry.yarnpkg.com/json3/-/json3-3.3.2.tgz#3c0434743df93e2f5c42aee7b19bcb483575f4e1" -json5@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/json5/-/json5-0.4.0.tgz#054352e4c4c80c86c0923877d449de176a732c8d" - json5@^0.5.0, json5@^0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/json5/-/json5-0.5.1.tgz#1eade7acc012034ad84e2396767ead9fa5495821" @@ -3787,10 +4436,6 @@ jsonify@~0.0.0: version "0.0.0" resolved "https://registry.yarnpkg.com/jsonify/-/jsonify-0.0.0.tgz#2c74b6ee41d93ca51b7b5aaee8f503631d252a73" -jsonpointer@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/jsonpointer/-/jsonpointer-4.0.1.tgz#4fd92cb34e0e9db3c89c8622ecf51f9b978c6cb9" - jsprim@^1.2.2: version "1.4.1" resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" @@ -3800,6 +4445,12 @@ jsprim@^1.2.2: json-schema "0.2.3" verror "1.10.0" +jsx-ast-utils@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/jsx-ast-utils/-/jsx-ast-utils-2.0.1.tgz#e801b1b39985e20fffc87b40e3748080e2dcac7f" + dependencies: + array-includes "^3.0.3" + kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.2.0: version "3.2.2" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64" @@ -3830,18 +4481,32 @@ lazy-cache@^1.0.3: version "1.0.4" resolved "https://registry.yarnpkg.com/lazy-cache/-/lazy-cache-1.0.4.tgz#a1d78fc3a50474cb80845d3b3b6e1da49a446e8e" +lcid@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/lcid/-/lcid-1.0.0.tgz#308accafa0bc483a3867b4b6f2b9506251d1b835" + dependencies: + invert-kv "^1.0.0" + +left-pad@^1.2.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/left-pad/-/left-pad-1.3.0.tgz#5b8a3a7765dfe001261dde915589e782f8c94d1e" + leven@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/leven/-/leven-1.0.2.tgz#9144b6eebca5f1d0680169f1a6770dcea60b75c3" -levn@~0.3.0: +leven@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/leven/-/leven-2.1.0.tgz#c2e7a9f772094dee9d34202ae8acce4687875580" + +levn@^0.3.0, levn@~0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" dependencies: prelude-ls "~1.1.2" type-check "~0.3.2" -liftoff@^2.0.1: +liftoff@^2.1.0: version "2.5.0" resolved "https://registry.yarnpkg.com/liftoff/-/liftoff-2.5.0.tgz#2009291bb31cea861bbf10a7c15a28caf75c31ec" dependencies: @@ -3864,7 +4529,23 @@ load-json-file@^1.0.0: pinkie-promise "^2.0.0" strip-bom "^2.0.0" -loader-utils@^0.2.11, loader-utils@^0.2.7: +load-json-file@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-2.0.0.tgz#7947e42149af80d696cbf797bcaabcfe1fe29ca8" + dependencies: + graceful-fs "^4.1.2" + parse-json "^2.2.0" + pify "^2.0.0" + strip-bom "^3.0.0" + +loader-fs-cache@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/loader-fs-cache/-/loader-fs-cache-1.0.1.tgz#56e0bf08bd9708b26a765b68509840c8dec9fdbc" + dependencies: + find-cache-dir "^0.1.1" + mkdirp "0.5.1" + +loader-utils@^0.2.11: version "0.2.17" resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-0.2.17.tgz#f86e6374d43205a6e6c60e9196f17c0299bfb348" dependencies: @@ -3873,6 +4554,21 @@ loader-utils@^0.2.11, loader-utils@^0.2.7: json5 "^0.5.0" object-assign "^4.0.1" +loader-utils@^1.0.2: + version "1.1.0" + resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-1.1.0.tgz#c98aef488bcceda2ffb5e2de646d6a754429f5cd" + dependencies: + big.js "^3.1.3" + emojis-list "^2.0.0" + json5 "^0.5.0" + +locate-path@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-2.0.0.tgz#2b568b265eec944c6d9c0de9c3dbbbca0354cd8e" + dependencies: + p-locate "^2.0.0" + path-exists "^3.0.0" + lodash._basecopy@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/lodash._basecopy/-/lodash._basecopy-3.0.1.tgz#8da0e6a876cf344c0ad8a54882111dd3c5c7ca36" @@ -3901,7 +4597,7 @@ lodash._reevaluate@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/lodash._reevaluate/-/lodash._reevaluate-3.0.0.tgz#58bc74c40664953ae0b124d806996daca431e2ed" -lodash._reinterpolate@^3.0.0, lodash._reinterpolate@~3.0.0: +lodash._reinterpolate@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/lodash._reinterpolate/-/lodash._reinterpolate-3.0.0.tgz#0ccf2d89166af03b3663c796538b75ac6e114d9d" @@ -3909,28 +4605,12 @@ lodash._root@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/lodash._root/-/lodash._root-3.0.1.tgz#fba1c4524c19ee9a5f8136b4609f017cf4ded692" -lodash.assign@^4.0.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/lodash.assign/-/lodash.assign-4.2.0.tgz#0d99f3ccd7a6d261d19bdaeb9245005d285808e7" - -lodash.cond@^4.3.0: - version "4.5.2" - resolved "https://registry.yarnpkg.com/lodash.cond/-/lodash.cond-4.5.2.tgz#f471a1da486be60f6ab955d17115523dd1d255d5" - -lodash.endswith@^4.0.1: - version "4.2.1" - resolved "https://registry.yarnpkg.com/lodash.endswith/-/lodash.endswith-4.2.1.tgz#fed59ac1738ed3e236edd7064ec456448b37bc09" - lodash.escape@^3.0.0: version "3.2.0" resolved "https://registry.yarnpkg.com/lodash.escape/-/lodash.escape-3.2.0.tgz#995ee0dc18c1b48cc92effae71a10aab5b487698" dependencies: lodash._root "^3.0.0" -lodash.find@^4.3.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/lodash.find/-/lodash.find-4.6.0.tgz#cb0704d47ab71789ffa0de8b97dd926fb88b13b1" - lodash.isarguments@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/lodash.isarguments/-/lodash.isarguments-3.1.0.tgz#2f573d85c6a24289ff00663b491c1d338ff3458a" @@ -3951,14 +4631,14 @@ lodash.pick@^4.4.0: version "4.4.0" resolved "https://registry.yarnpkg.com/lodash.pick/-/lodash.pick-4.4.0.tgz#52f05610fff9ded422611441ed1fc123a03001b3" -lodash.pickby@^4.0.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/lodash.pickby/-/lodash.pickby-4.6.0.tgz#7dea21d8c18d7703a27c704c15d3b84a67e33aff" - lodash.restparam@^3.0.0: version "3.6.1" resolved "https://registry.yarnpkg.com/lodash.restparam/-/lodash.restparam-3.6.1.tgz#936a4e309ef330a7645ed4145986c85ae5b20805" +lodash.sortby@^4.7.0: + version "4.7.0" + resolved "https://registry.yarnpkg.com/lodash.sortby/-/lodash.sortby-4.7.0.tgz#edd14c824e2cc9c1e0b0a1b42bb5210516a42438" + lodash.template@^3.0.0: version "3.6.2" resolved "https://registry.yarnpkg.com/lodash.template/-/lodash.template-3.6.2.tgz#f8cdecc6169a255be9098ae8b0c53d378931d14f" @@ -3973,13 +4653,6 @@ lodash.template@^3.0.0: lodash.restparam "^3.0.0" lodash.templatesettings "^3.0.0" -lodash.template@^4.2.4: - version "4.4.0" - resolved "https://registry.yarnpkg.com/lodash.template/-/lodash.template-4.4.0.tgz#e73a0385c8355591746e020b99679c690e68fba0" - dependencies: - lodash._reinterpolate "~3.0.0" - lodash.templatesettings "^4.0.0" - lodash.templatesettings@^3.0.0: version "3.1.1" resolved "https://registry.yarnpkg.com/lodash.templatesettings/-/lodash.templatesettings-3.1.1.tgz#fb307844753b66b9f1afa54e262c745307dba8e5" @@ -3987,21 +4660,7 @@ lodash.templatesettings@^3.0.0: lodash._reinterpolate "^3.0.0" lodash.escape "^3.0.0" -lodash.templatesettings@^4.0.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/lodash.templatesettings/-/lodash.templatesettings-4.1.0.tgz#2b4d4e95ba440d915ff08bc899e4553666713316" - dependencies: - lodash._reinterpolate "~3.0.0" - -lodash@4.11.2: - version "4.11.2" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.11.2.tgz#d6b4338b110a58e21dae5cebcfdbbfd2bc4cdb3b" - -lodash@^3.10.0, lodash@^3.2.0: - version "3.10.1" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6" - -lodash@^4.0.0, lodash@^4.11.1, lodash@^4.17.4, lodash@^4.3.0: +lodash@4.17.10, lodash@^4.13.1, lodash@^4.17.10, lodash@^4.17.4, lodash@^4.17.5, lodash@^4.2.0, lodash@^4.3.0: version "4.17.10" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.10.tgz#1b7793cf7259ea38fb3661d4d38b3260af8ae4e7" @@ -4009,33 +4668,39 @@ lodash@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/lodash/-/lodash-1.0.2.tgz#8f57560c83b59fc270bd3d561b690043430e2551" -log-symbols@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-1.0.2.tgz#376ff7b58ea3086a0f09facc74617eca501e1a18" - dependencies: - chalk "^1.0.0" - longest@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/longest/-/longest-1.0.1.tgz#30a0b2da38f73770e8294a0d22e6625ed77d0097" -loose-envify@^1.0.0: +loose-envify@^1.0.0, loose-envify@^1.3.1: version "1.3.1" resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.3.1.tgz#d1a8ad33fa9ce0e713d65fdd0ac8b748d478c848" dependencies: js-tokens "^3.0.0" -loud-rejection@^1.0.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/loud-rejection/-/loud-rejection-1.6.0.tgz#5b46f80147edee578870f086d04821cf998e551f" - dependencies: - currently-unhandled "^0.4.1" - signal-exit "^3.0.0" - lru-cache@2: version "2.7.3" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-2.7.3.tgz#6d4524e8b955f95d4f5b58851ce21dd72fb4e952" +lru-cache@^4.0.1: + version "4.1.3" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.3.tgz#a1175cf3496dfc8436c156c334b4955992bce69c" + dependencies: + pseudomap "^1.0.2" + yallist "^2.1.2" + +lru-queue@0.1: + version "0.1.0" + resolved "https://registry.yarnpkg.com/lru-queue/-/lru-queue-0.1.0.tgz#2738bd9f0d3cf4f84490c5736c48699ac632cda3" + dependencies: + es5-ext "~0.10.2" + +make-dir@^1.0.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-1.3.0.tgz#79c1033b80515bd6d24ec9933e860ca75ee27f0c" + dependencies: + pify "^3.0.0" + make-iterator@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/make-iterator/-/make-iterator-1.0.1.tgz#29b33f312aa8f547c4a5e490f56afcec99133ad6" @@ -4052,10 +4717,6 @@ map-cache@^0.2.0, map-cache@^0.2.2: version "0.2.2" resolved "https://registry.yarnpkg.com/map-cache/-/map-cache-0.2.2.tgz#c32abd0bd6525d9b051645bb4f26ac5dc98a0dbf" -map-obj@^1.0.0, map-obj@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-1.0.1.tgz#d933ceb9205d82bdcf4886f6742bdc2b4dea146d" - map-visit@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/map-visit/-/map-visit-1.0.0.tgz#ecdca8f13144e660f1b5bd41f12f3479d98dfb8f" @@ -4081,6 +4742,25 @@ media-typer@0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/media-typer/-/media-typer-0.3.0.tgz#8710d7af0aa626f8fffa1ce00168545263255748" +mem@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/mem/-/mem-1.1.0.tgz#5edd52b485ca1d900fe64895505399a0dfa45f76" + dependencies: + mimic-fn "^1.0.0" + +memoizee@0.4.X: + version "0.4.12" + resolved "https://registry.yarnpkg.com/memoizee/-/memoizee-0.4.12.tgz#780e99a219c50c549be6d0fc61765080975c58fb" + dependencies: + d "1" + es5-ext "^0.10.30" + es6-weak-map "^2.0.2" + event-emitter "^0.3.5" + is-promise "^2.1" + lru-queue "0.1" + next-tick "1" + timers-ext "^0.1.2" + memory-fs@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/memory-fs/-/memory-fs-0.2.0.tgz#f2bb25368bc121e391c2520de92969caee0a0290" @@ -4099,28 +4779,13 @@ memory-fs@~0.4.1: errno "^0.1.3" readable-stream "^2.0.1" -meow@^3.3.0, meow@^3.5.0: - version "3.7.0" - resolved "https://registry.yarnpkg.com/meow/-/meow-3.7.0.tgz#72cb668b425228290abbfa856892587308a801fb" - dependencies: - camelcase-keys "^2.0.0" - decamelize "^1.1.2" - loud-rejection "^1.0.0" - map-obj "^1.0.1" - minimist "^1.1.3" - normalize-package-data "^2.3.4" - object-assign "^4.0.1" - read-pkg-up "^1.0.1" - redent "^1.0.0" - trim-newlines "^1.0.0" - merge-descriptors@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/merge-descriptors/-/merge-descriptors-1.0.1.tgz#b00aaa556dd8b44568150ec9d1b953f3f90cbb61" -merge-stream@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-1.0.0.tgz#9cfd156fef35421e2b5403ce11dc6eb1962b026e" +merge-stream@1.0.1, merge-stream@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-1.0.1.tgz#4041202d508a342ba00174008df0c251b8c135e1" dependencies: readable-stream "^2.0.1" @@ -4150,7 +4815,7 @@ micromatch@^2.1.5: parse-glob "^3.0.4" regex-cache "^0.4.2" -micromatch@^3.0.4: +micromatch@^3.0.4, micromatch@^3.1.10, micromatch@^3.1.4, micromatch@^3.1.8: version "3.1.10" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23" dependencies: @@ -4197,6 +4862,10 @@ mime@^1.5.0: version "1.6.0" resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" +mimic-fn@^1.0.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" + minimalistic-assert@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" @@ -4205,18 +4874,18 @@ minimalistic-crypto-utils@^1.0.0, minimalistic-crypto-utils@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz#f6c00c1c0b082246e5c4d99dfb8c7c083b2b582a" -"minimatch@2 || 3", minimatch@^3.0.2, minimatch@^3.0.4: - version "3.0.4" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" - dependencies: - brace-expansion "^1.1.7" - -minimatch@^2.0.1, minimatch@^2.0.3: +minimatch@^2.0.1: version "2.0.10" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-2.0.10.tgz#8d087c39c6b38c001b97fca7ce6d0e1e80afbac7" dependencies: brace-expansion "^1.0.0" +minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: + version "3.0.4" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" + dependencies: + brace-expansion "^1.1.7" + minimatch@~0.2.11: version "0.2.14" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-0.2.14.tgz#c74e780574f63c6f9a090e90efbe6ef53a6a756a" @@ -4228,7 +4897,7 @@ minimist@0.0.8: version "0.0.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" -minimist@^1.1.0, minimist@^1.1.1, minimist@^1.1.3, minimist@^1.2.0: +minimist@^1.1.0, minimist@^1.1.1, minimist@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" @@ -4260,46 +4929,38 @@ mkdirp2@^1.0.3: version "1.0.4" resolved "https://registry.yarnpkg.com/mkdirp2/-/mkdirp2-1.0.4.tgz#56de1f8f5c93cf2199906362eba0f9f262ee4437" -mkdirp@0.5.x, mkdirp@^0.5.0, mkdirp@^0.5.1, mkdirp@~0.5.0, mkdirp@~0.5.1: +mkdirp@0.5.1, mkdirp@^0.5.0, mkdirp@^0.5.1, mkdirp@~0.5.0, mkdirp@~0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" dependencies: minimist "0.0.8" -mqtt-connection@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/mqtt-connection/-/mqtt-connection-2.1.1.tgz#7b2e985a74e196619430bebd35da162c34c4e56a" - dependencies: - inherits "^2.0.1" - mqtt-packet "^3.0.0" - reduplexer "^1.1.0" - through2 "^0.6.3" - -mqtt-packet@^3.0.0, mqtt-packet@^3.2.0: - version "3.5.0" - resolved "https://registry.yarnpkg.com/mqtt-packet/-/mqtt-packet-3.5.0.tgz#8b2953410b89e17981ee2ce63a33e73785109d9f" +mqtt-packet@^5.6.0: + version "5.6.0" + resolved "https://registry.yarnpkg.com/mqtt-packet/-/mqtt-packet-5.6.0.tgz#923fb704d0ce0bd6ac81c7e1cc09469b1512d2fd" dependencies: - bl "^1.0.0" - inherits "^2.0.1" + bl "^1.2.1" + inherits "^2.0.3" + process-nextick-args "^2.0.0" + safe-buffer "^5.1.0" -mqtt@1.10.0: - version "1.10.0" - resolved "https://registry.yarnpkg.com/mqtt/-/mqtt-1.10.0.tgz#0e82ea9bb3cde6b385cae0c2c728a6921d338c7c" +mqtt@2.18.2: + version "2.18.2" + resolved "https://registry.yarnpkg.com/mqtt/-/mqtt-2.18.2.tgz#5c01b412d23db399aa5230e7d4e71a3fcef3e64a" dependencies: commist "^1.0.0" - concat-stream "^1.4.7" - end-of-stream "^1.1.0" - help-me "^0.1.0" - inherits "^2.0.1" - minimist "^1.1.0" - mqtt-connection "^2.0.0" - mqtt-packet "^3.2.0" - pump "^1.0.1" - readable-stream "~1.0.2" - reinterval "^1.0.1" - split2 "^2.0.1" - websocket-stream "^3.0.1" - xtend "^4.0.0" + concat-stream "^1.6.2" + end-of-stream "^1.4.1" + help-me "^1.0.1" + inherits "^2.0.3" + minimist "^1.2.0" + mqtt-packet "^5.6.0" + pump "^3.0.0" + readable-stream "^2.3.6" + reinterval "^1.1.0" + split2 "^2.1.1" + websocket-stream "^5.1.2" + xtend "^4.0.1" ms@2.0.0: version "2.0.0" @@ -4311,9 +4972,9 @@ multipipe@^0.1.2: dependencies: duplexer2 "0.0.2" -mute-stream@0.0.5: - version "0.0.5" - resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.5.tgz#8fbfabb0a98a253d3184331f9e8deb7372fac6c0" +mute-stream@0.0.7: + version "0.0.7" + resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" nan@^2.3.3, nan@^2.9.2: version "2.10.0" @@ -4339,6 +5000,10 @@ natives@^1.1.0: version "1.1.4" resolved "https://registry.yarnpkg.com/natives/-/natives-1.1.4.tgz#2f0f224fc9a7dd53407c7667c84cf8dbe773de58" +natural-compare@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" + needle@^2.2.0: version "2.2.1" resolved "https://registry.yarnpkg.com/needle/-/needle-2.2.1.tgz#b5e325bd3aae8c2678902fa296f729455d1d3a7d" @@ -4355,36 +5020,40 @@ next-tick@1: version "1.0.0" resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" +nice-try@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.4.tgz#d93962f6c52f2c1558c0fbda6d512819f1efe1c4" + node-int64@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/node-int64/-/node-int64-0.4.0.tgz#87a9065cdb355d3182d8f94ce11188b825c68a3b" -node-libs-browser@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/node-libs-browser/-/node-libs-browser-1.0.0.tgz#ff8ad6c2cfa78043bdd0091ec07f0aaa581620fc" +node-libs-browser@2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/node-libs-browser/-/node-libs-browser-2.1.0.tgz#5f94263d404f6e44767d726901fff05478d600df" dependencies: assert "^1.1.1" - browserify-zlib "~0.1.4" + browserify-zlib "^0.2.0" buffer "^4.3.0" console-browserify "^1.1.0" constants-browserify "^1.0.0" crypto-browserify "^3.11.0" domain-browser "^1.1.1" events "^1.0.0" - http-browserify "^1.3.2" - https-browserify "0.0.1" - os-browserify "~0.2.0" + https-browserify "^1.0.0" + os-browserify "^0.3.0" path-browserify "0.0.0" - process "~0.11.0" + process "^0.11.10" punycode "^1.2.4" - querystring-es3 "~0.2.0" - readable-stream "^2.0.5" + querystring-es3 "^0.2.0" + readable-stream "^2.3.3" stream-browserify "^2.0.1" - string_decoder "~0.10.25" - timers-browserify "^1.0.1" + stream-http "^2.7.2" + string_decoder "^1.0.0" + timers-browserify "^2.0.4" tty-browserify "0.0.0" - url "~0.11.0" - util "~0.10.3" + url "^0.11.0" + util "^0.10.3" vm-browserify "0.0.4" "node-libs-browser@>= 0.4.0 <=0.6.0": @@ -4415,6 +5084,15 @@ node-libs-browser@1.0.0: util "~0.10.3" vm-browserify "0.0.4" +node-notifier@^5.2.1: + version "5.2.1" + resolved "https://registry.yarnpkg.com/node-notifier/-/node-notifier-5.2.1.tgz#fa313dd08f5517db0e2502e5758d664ac69f9dea" + dependencies: + growly "^1.3.0" + semver "^5.4.1" + shellwords "^0.1.1" + which "^1.3.0" + node-pre-gyp@^0.10.0: version "0.10.2" resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.10.2.tgz#e8945c20ef6795a20aac2b44f036eb13cf5146e3" @@ -4430,12 +5108,6 @@ node-pre-gyp@^0.10.0: semver "^5.3.0" tar "^4" -nopt@3.x: - version "3.0.6" - resolved "https://registry.yarnpkg.com/nopt/-/nopt-3.0.6.tgz#c6465dbf08abcd4db359317f79ac68a646b28ff9" - dependencies: - abbrev "1" - nopt@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/nopt/-/nopt-4.0.1.tgz#d0d4685afd5415193c8c7505602d0d17cd64474d" @@ -4443,7 +5115,7 @@ nopt@^4.0.1: abbrev "1" osenv "^0.1.4" -normalize-package-data@^2.3.2, normalize-package-data@^2.3.4: +normalize-package-data@^2.3.2: version "2.4.0" resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.4.0.tgz#12f95a307d58352075a04907b84ac8be98ac012f" dependencies: @@ -4452,7 +5124,7 @@ normalize-package-data@^2.3.2, normalize-package-data@^2.3.4: semver "2 || 3 || 4 || 5" validate-npm-package-license "^3.0.1" -normalize-path@^2.0.0, normalize-path@^2.0.1: +normalize-path@^2.0.0, normalize-path@^2.0.1, normalize-path@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9" dependencies: @@ -4469,6 +5141,12 @@ npm-packlist@^1.1.6: ignore-walk "^3.0.1" npm-bundled "^1.0.1" +npm-run-path@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" + dependencies: + path-key "^2.0.0" + npmlog@^4.0.2: version "4.1.2" resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" @@ -4482,26 +5160,22 @@ number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" -"nwmatcher@>= 1.3.9 < 2.0.0": - version "1.4.4" - resolved "https://registry.yarnpkg.com/nwmatcher/-/nwmatcher-1.4.4.tgz#2285631f34a95f0d0395cd900c96ed39b58f346e" +nwsapi@^2.0.0: + version "2.0.4" + resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.0.4.tgz#dc79040a5f77b97716dc79565fc7fc3ef7d50570" oauth-sign@~0.8.2: version "0.8.2" resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43" -object-assign@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-2.1.1.tgz#43c36e5d569ff8e4816c4efa8be02d26967c18aa" +object-assign@4.X, object-assign@^4.0.1, object-assign@^4.1.0, object-assign@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" object-assign@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-3.0.0.tgz#9bedd5ca0897949bca47e7ff408062d549f587f2" -object-assign@^4.0.1, object-assign@^4.1.0: - version "4.1.1" - resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" - object-copy@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/object-copy/-/object-copy-0.1.0.tgz#7e7d858b781bd7c991a41ba975ed3812754e998c" @@ -4514,6 +5188,14 @@ object-get@^2.0.0, object-get@^2.0.2, object-get@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/object-get/-/object-get-2.1.0.tgz#722bbdb60039efa47cad3c6dc2ce51a85c02c5ae" +object-hash@^1.1.4: + version "1.3.0" + resolved "https://registry.yarnpkg.com/object-hash/-/object-hash-1.3.0.tgz#76d9ba6ff113cf8efc0d996102851fe6723963e2" + +object-keys@^1.0.11, object-keys@^1.0.8: + version "1.0.12" + resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.0.12.tgz#09c53855377575310cca62f55bb334abff7b3ed2" + object-to-spawn-args@^1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/object-to-spawn-args/-/object-to-spawn-args-1.1.1.tgz#77da8827f073d011c9e1b173f895781470246785" @@ -4541,6 +5223,15 @@ object-visit@^1.0.0: dependencies: isobject "^3.0.0" +object.assign@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.0.tgz#968bf1100d7956bb3ca086f006f846b3bc4008da" + dependencies: + define-properties "^1.1.2" + function-bind "^1.1.1" + has-symbols "^1.0.0" + object-keys "^1.0.11" + object.defaults@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/object.defaults/-/object.defaults-1.1.0.tgz#3a7f868334b407dea06da16d88d5cd29e435fecf" @@ -4550,6 +5241,22 @@ object.defaults@^1.1.0: for-own "^1.0.0" isobject "^3.0.0" +object.entries@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/object.entries/-/object.entries-1.0.4.tgz#1bf9a4dd2288f5b33f3a993d257661f05d161a5f" + dependencies: + define-properties "^1.1.2" + es-abstract "^1.6.1" + function-bind "^1.1.0" + has "^1.0.1" + +object.getownpropertydescriptors@^2.0.3: + version "2.0.3" + resolved "https://registry.yarnpkg.com/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.0.3.tgz#8758c846f5b407adab0f236e0986f14b051caa16" + dependencies: + define-properties "^1.1.2" + es-abstract "^1.5.1" + object.map@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object.map/-/object.map-1.0.1.tgz#cf83e59dc8fcc0ad5f4250e1f78b3b81bd801d37" @@ -4580,7 +5287,7 @@ on-headers@~1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/on-headers/-/on-headers-1.0.1.tgz#928f5d0f470d49342651ea6794b0857c100693f7" -once@1.x, once@^1.3.0, once@^1.3.1, once@^1.4.0: +once@^1.3.0, once@^1.3.1, once@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" dependencies: @@ -4592,9 +5299,11 @@ once@~1.3.0: dependencies: wrappy "1" -onetime@^1.0.0: - version "1.1.0" - resolved "http://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz#a1f7838f8314c516f05ecefcbc4ccfe04b4ed789" +onetime@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz#067428230fd67443b2794b22bba528b6867962d4" + dependencies: + mimic-fn "^1.0.0" optimist@^0.6.1, optimist@~0.6.0: version "0.6.1" @@ -4609,7 +5318,7 @@ optimist@~0.3.5: dependencies: wordwrap "~0.0.2" -optionator@^0.8.1: +optionator@^0.8.1, optionator@^0.8.2: version "0.8.2" resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64" dependencies: @@ -4620,10 +5329,6 @@ optionator@^0.8.1: type-check "~0.3.2" wordwrap "~1.0.0" -options@>=0.0.5: - version "0.0.6" - resolved "https://registry.yarnpkg.com/options/-/options-0.0.6.tgz#ec22d312806bb53e731773e7cdaefcf1c643128f" - orchestrator@^0.3.0: version "0.3.8" resolved "https://registry.yarnpkg.com/orchestrator/-/orchestrator-0.3.8.tgz#14e7e9e2764f7315fbac184e506c7aa6df94ad7e" @@ -4636,25 +5341,39 @@ ordered-read-streams@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/ordered-read-streams/-/ordered-read-streams-0.1.0.tgz#fd565a9af8eb4473ba69b6ed8a34352cb552f126" +ordered-read-streams@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/ordered-read-streams/-/ordered-read-streams-1.0.1.tgz#77c0cb37c41525d64166d990ffad7ec6a0e1363e" + dependencies: + readable-stream "^2.0.1" + original@>=0.0.5: version "1.0.1" resolved "https://registry.yarnpkg.com/original/-/original-1.0.1.tgz#b0a53ff42ba997a8c9cd1fb5daaeb42b9d693190" dependencies: url-parse "~1.4.0" +os-browserify@^0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/os-browserify/-/os-browserify-0.3.0.tgz#854373c7f5c2315914fc9bfc6bd8238fdda1ec27" + os-browserify@~0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/os-browserify/-/os-browserify-0.1.2.tgz#49ca0293e0b19590a5f5de10c7f265a617d8fe54" -os-browserify@~0.2.0: - version "0.2.1" - resolved "https://registry.yarnpkg.com/os-browserify/-/os-browserify-0.2.1.tgz#63fc4ccee5d2d7763d26bbf8601078e6c2e0044f" - os-homedir@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz#ffbc4988336e0e833de0c168c7ef152121aa7fb3" -os-tmpdir@^1.0.0, os-tmpdir@^1.0.1: +os-locale@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-2.1.0.tgz#42bc2900a6b5b8bd17376c8e882b65afccf24bf2" + dependencies: + execa "^0.7.0" + lcid "^1.0.0" + mem "^1.1.0" + +os-tmpdir@^1.0.0, os-tmpdir@^1.0.1, os-tmpdir@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" @@ -4665,7 +5384,7 @@ osenv@^0.1.4: os-homedir "^1.0.0" os-tmpdir "^1.0.0" -output-file-sync@^1.1.0: +output-file-sync@^1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/output-file-sync/-/output-file-sync-1.1.2.tgz#d0a33eefe61a205facb90092e826598d5245ce76" dependencies: @@ -4673,10 +5392,38 @@ output-file-sync@^1.1.0: mkdirp "^0.5.1" object-assign "^4.1.0" +p-finally@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" + +p-limit@^1.1.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.3.0.tgz#b86bd5f0c25690911c7590fcbfc2010d54b3ccb8" + dependencies: + p-try "^1.0.0" + +p-locate@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-2.0.0.tgz#20a0103b222a70c8fd39cc2e580680f3dde5ec43" + dependencies: + p-limit "^1.1.0" + +p-map@^1.1.1: + version "1.2.0" + resolved "https://registry.yarnpkg.com/p-map/-/p-map-1.2.0.tgz#e4e94f311eabbc8633a1e79908165fca26241b6b" + +p-try@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/p-try/-/p-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3" + pako@~0.2.0: version "0.2.9" resolved "https://registry.yarnpkg.com/pako/-/pako-0.2.9.tgz#f3f7522f4ef782348da8161bad9ecfd51bf83a75" +pako@~1.0.5: + version "1.0.6" + resolved "https://registry.yarnpkg.com/pako/-/pako-1.0.6.tgz#0101211baa70c4bca4a0f63f2206e97b7dfaf258" + parse-asn1@^5.0.0: version "5.1.1" resolved "https://registry.yarnpkg.com/parse-asn1/-/parse-asn1-5.1.1.tgz#f6bf293818332bd0dab54efb16087724745e6ca8" @@ -4714,9 +5461,9 @@ parse-passwd@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/parse-passwd/-/parse-passwd-1.0.0.tgz#6d5b934a456993b23d37f40a382d6f1666a8e5c6" -parse5@^1.5.1: - version "1.5.1" - resolved "https://registry.yarnpkg.com/parse5/-/parse5-1.5.1.tgz#9b7f3b0de32be78dc2401b17573ccaf0f6f59d94" +parse5@4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/parse5/-/parse5-4.0.0.tgz#6d78656e3da8d78b4ec0b906f7c08ef1dfe3f608" parseurl@~1.3.2: version "1.3.2" @@ -4730,9 +5477,9 @@ path-browserify@0.0.0: version "0.0.0" resolved "https://registry.yarnpkg.com/path-browserify/-/path-browserify-0.0.0.tgz#a0b870729aae214005b7d5032ec2cbbb0fb4451a" -path-exists@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-1.0.0.tgz#d5a8998eb71ef37a74c34eb0d9eba6e878eea081" +path-dirname@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/path-dirname/-/path-dirname-1.0.2.tgz#cc33d24d525e099a5388c0336c6e32b9160609e0" path-exists@^2.0.0: version "2.1.0" @@ -4740,14 +5487,22 @@ path-exists@^2.0.0: dependencies: pinkie-promise "^2.0.0" +path-exists@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" + path-is-absolute@^1.0.0, path-is-absolute@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" -path-is-inside@^1.0.1: +path-is-inside@^1.0.1, path-is-inside@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" +path-key@^2.0.0, path-key@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" + path-parse@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.5.tgz#3c1adf871ea9cd6c9431b6ea2bd74a0ff055c4c1" @@ -4774,6 +5529,12 @@ path-type@^1.0.0: pify "^2.0.0" pinkie-promise "^2.0.0" +path-type@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-2.0.0.tgz#f012ccb8415b7096fc2daa1054c3d72389594c73" + dependencies: + pify "^2.0.0" + path@0.12.7: version "0.12.7" resolved "https://registry.yarnpkg.com/path/-/path-0.12.7.tgz#d4dc2a506c4ce2197eb481ebfcd5b36c0140b10f" @@ -4803,11 +5564,9 @@ pify@^2.0.0: version "2.3.0" resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" -pinkie-promise@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/pinkie-promise/-/pinkie-promise-1.0.0.tgz#d1da67f5482563bb7cf57f286ae2822ecfbf3670" - dependencies: - pinkie "^1.0.0" +pify@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/pify/-/pify-3.0.0.tgz#e5a4acd2c101fdf3d9a4d07f0dbc4db49dd28176" pinkie-promise@^2.0.0: version "2.0.1" @@ -4815,23 +5574,38 @@ pinkie-promise@^2.0.0: dependencies: pinkie "^2.0.0" -pinkie@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-1.0.0.tgz#5a47f28ba1015d0201bda7bf0f358e47bec8c7e4" - pinkie@^2.0.0: version "2.0.4" resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" -pkg-up@^1.0.0: +pkg-dir@^1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/pkg-up/-/pkg-up-1.0.0.tgz#3e08fb461525c4421624a33b9f7e6d0af5b05a26" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-1.0.0.tgz#7a4b508a8d5bb2d629d447056ff4e9c9314cf3d4" dependencies: find-up "^1.0.0" -pluralize@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-1.2.1.tgz#d1a21483fd22bb41e58a12fa3421823140897c45" +pkg-dir@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-2.0.0.tgz#f6d5d1109e19d63edf428e0bd57e12777615334b" + dependencies: + find-up "^2.1.0" + +plugin-error@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/plugin-error/-/plugin-error-1.0.1.tgz#77016bd8919d0ac377fdcdd0322328953ca5781c" + dependencies: + ansi-colors "^1.0.1" + arr-diff "^4.0.0" + arr-union "^3.1.0" + extend-shallow "^3.0.2" + +pluralize@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777" + +pn@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/pn/-/pn-1.1.0.tgz#e2f4cef0e219f463c179ab37463e4e1ecdccbafb" posix-character-classes@^0.1.0: version "0.1.1" @@ -4845,25 +5619,32 @@ preserve@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/preserve/-/preserve-0.2.0.tgz#815ed1f6ebc65926f865b310c0713bcb3315ce4b" -pretty-hrtime@^0.2.0: - version "0.2.2" - resolved "https://registry.yarnpkg.com/pretty-hrtime/-/pretty-hrtime-0.2.2.tgz#d4fd88351e3a4741f8173af7d6a4b846f9895c00" +pretty-format@^23.2.0: + version "23.2.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-23.2.0.tgz#3b0aaa63c018a53583373c1cb3a5d96cc5e83017" + dependencies: + ansi-regex "^3.0.0" + ansi-styles "^3.2.0" + +pretty-hrtime@^1.0.0: + version "1.0.3" + resolved "https://registry.yarnpkg.com/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz#b7e3ea42435a4c9b2759d99e0f201eb195802ee1" private@^0.1.6, private@^0.1.8: version "0.1.8" resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz#2381edb3689f7a53d653190060fcf822d2f368ff" -process-nextick-args@~2.0.0: +process-nextick-args@^2.0.0, process-nextick-args@~2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.0.tgz#a37d732f4271b4ab1ad070d35508e8290788ffaa" -process@^0.11.0, process@^0.11.1, process@~0.11.0: +process@^0.11.0, process@^0.11.1, process@^0.11.10, process@~0.11.0: version "0.11.10" resolved "https://registry.yarnpkg.com/process/-/process-0.11.10.tgz#7332300e840161bda3e69a1d1d91a7d4bc16f182" -progress@^1.1.8: - version "1.1.8" - resolved "https://registry.yarnpkg.com/progress/-/progress-1.1.8.tgz#e260c78f6161cdd9b0e56cc3e0a85de17c7a57be" +progress@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.0.tgz#8a1be366bf8fc23db2bd23f10c6fe920b4389d1f" promise.prototype.finally@^1.0.1: version "1.0.1" @@ -4875,6 +5656,20 @@ promise.prototype.finally@^1.0.1: dependencies: asap "~2.0.3" +prompts@^0.1.9: + version "0.1.10" + resolved "https://registry.yarnpkg.com/prompts/-/prompts-0.1.10.tgz#832cbf6116ecb121d6884e84643bb2cf92b3ed2c" + dependencies: + clorox "^1.0.3" + sisteransi "^0.1.1" + +prop-types@^15.6.2: + version "15.6.2" + resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.6.2.tgz#05d5ca77b4453e985d60fc7ff8c859094a497102" + dependencies: + loose-envify "^1.3.1" + object-assign "^4.1.1" + proxy-addr@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.3.tgz#355f262505a621646b3130a728eb647e22055341" @@ -4886,6 +5681,10 @@ prr@~1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/prr/-/prr-1.0.1.tgz#d3fc114ba06995a45ec6893f484ceb1d78f5f476" +pseudomap@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" + psl@^1.1.24: version "1.1.28" resolved "https://registry.yarnpkg.com/psl/-/psl-1.1.28.tgz#4fb6ceb08a1e2214d4fd4de0ca22dae13740bc7b" @@ -4900,13 +5699,28 @@ public-encrypt@^4.0.0: parse-asn1 "^5.0.0" randombytes "^2.0.1" -pump@^1.0.0, pump@^1.0.1: - version "1.0.3" - resolved "https://registry.yarnpkg.com/pump/-/pump-1.0.3.tgz#5dfe8311c33bbf6fc18261f9f34702c47c08a954" +pump@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/pump/-/pump-2.0.1.tgz#12399add6e4cf7526d973cbc8b5ce2e2908b3909" dependencies: end-of-stream "^1.1.0" once "^1.3.1" +pump@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/pump/-/pump-3.0.0.tgz#b4a2116815bde2f4e1ea602354e8c75565107a64" + dependencies: + end-of-stream "^1.1.0" + once "^1.3.1" + +pumpify@^1.3.5: + version "1.5.1" + resolved "https://registry.yarnpkg.com/pumpify/-/pumpify-1.5.1.tgz#36513be246ab27570b1a374a5ce278bfd74370ce" + dependencies: + duplexify "^3.6.0" + inherits "^2.0.3" + pump "^2.0.0" + punycode@1.3.2: version "1.3.2" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.3.2.tgz#9653a036fb7c1ee42342f2325cceefea3926c48d" @@ -4915,6 +5729,10 @@ punycode@^1.2.4, punycode@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" +punycode@^2.1.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" + qs@6.5.1: version "6.5.1" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" @@ -4923,7 +5741,7 @@ qs@~6.5.1: version "6.5.2" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" -querystring-es3@~0.2.0: +querystring-es3@^0.2.0, querystring-es3@~0.2.0: version "0.2.1" resolved "https://registry.yarnpkg.com/querystring-es3/-/querystring-es3-0.2.1.tgz#9ec61f79049875707d69414596fd907a4d711e73" @@ -4985,15 +5803,30 @@ read-pkg-up@^1.0.1: find-up "^1.0.0" read-pkg "^1.0.0" +read-pkg-up@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-2.0.0.tgz#6b72a8048984e0c41e79510fd5e9fa99b3b549be" + dependencies: + find-up "^2.0.0" + read-pkg "^2.0.0" + read-pkg@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-1.1.0.tgz#f5ffaa5ecd29cb31c0474bca7d756b6bb29e3f28" dependencies: - load-json-file "^1.0.0" + load-json-file "^1.0.0" + normalize-package-data "^2.3.2" + path-type "^1.0.0" + +read-pkg@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-2.0.0.tgz#8ef1c0623c6a6db0dc6713c4bfac46332b2368f8" + dependencies: + load-json-file "^2.0.0" normalize-package-data "^2.3.2" - path-type "^1.0.0" + path-type "^2.0.0" -"readable-stream@1.x >=1.1.9", readable-stream@^1.0.27-1, readable-stream@^1.0.33, readable-stream@^1.1.13, readable-stream@~1.1.9: +"readable-stream@1.x >=1.1.9", readable-stream@^1.0.27-1, readable-stream@^1.1.13, readable-stream@~1.1.9: version "1.1.14" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.1.14.tgz#7cf4c54ef648e3813084c636dd2079e166c081d9" dependencies: @@ -5002,16 +5835,7 @@ read-pkg@^1.0.0: isarray "0.0.1" string_decoder "~0.10.x" -"readable-stream@>=1.0.33-1 <1.1.0-0", readable-stream@~1.0.2, readable-stream@~1.0.26-2: - version "1.0.34" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.0.34.tgz#125820e34bc842d2f2aaafafe4c2916ee32c157c" - dependencies: - core-util-is "~1.0.0" - inherits "~2.0.1" - isarray "0.0.1" - string_decoder "~0.10.x" - -readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.0.6, readable-stream@^2.1.5, readable-stream@^2.2.2, readable-stream@^2.3.5: +"readable-stream@> 1.0.0 < 3.0.0", readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.6, readable-stream@^2.1.5, readable-stream@^2.2.2, readable-stream@^2.3.3, readable-stream@^2.3.5, readable-stream@^2.3.6: version "2.3.6" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf" dependencies: @@ -5023,6 +5847,15 @@ readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable string_decoder "~1.1.1" util-deprecate "~1.0.1" +"readable-stream@>=1.0.33-1 <1.1.0-0": + version "1.0.34" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.0.34.tgz#125820e34bc842d2f2aaafafe4c2916ee32c157c" + dependencies: + core-util-is "~1.0.0" + inherits "~2.0.1" + isarray "0.0.1" + string_decoder "~0.10.x" + readdirp@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-2.1.0.tgz#4ed0ad060df3073300c48440373f72d1cc642d78" @@ -5032,13 +5865,11 @@ readdirp@^2.0.0: readable-stream "^2.0.2" set-immediate-shim "^1.0.1" -readline2@^1.0.1: +realpath-native@^1.0.0: version "1.0.1" - resolved "https://registry.yarnpkg.com/readline2/-/readline2-1.0.1.tgz#41059608ffc154757b715d9989d199ffbf372e35" + resolved "https://registry.yarnpkg.com/realpath-native/-/realpath-native-1.0.1.tgz#07f40a0cce8f8261e2e8b7ebebf5c95965d7b633" dependencies: - code-point-at "^1.0.0" - is-fullwidth-code-point "^1.0.0" - mute-stream "0.0.5" + util.promisify "^1.0.0" rechoir@^0.6.2: version "0.6.2" @@ -5046,13 +5877,6 @@ rechoir@^0.6.2: dependencies: resolve "^1.1.6" -redent@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/redent/-/redent-1.0.0.tgz#cf916ab1fd5f1f16dfb20822dd6ec7f730c2afde" - dependencies: - indent-string "^2.1.0" - strip-indent "^1.0.1" - reduce-extract@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/reduce-extract/-/reduce-extract-1.0.0.tgz#67f2385beda65061b5f5f4312662e8b080ca1525" @@ -5073,13 +5897,6 @@ reduce-without@^1.0.0, reduce-without@^1.0.1: dependencies: test-value "^2.0.0" -reduplexer@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/reduplexer/-/reduplexer-1.1.0.tgz#7dfed18a679e749c1d7ad36de01acb515f08e140" - dependencies: - inherits "^2.0.1" - readable-stream "~1.0.26-2" - regenerate@^1.2.1: version "1.4.0" resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.0.tgz#4a856ec4b56e4077c557589cae85e7a4c8869a11" @@ -5113,6 +5930,16 @@ regex-not@^1.0.0, regex-not@^1.0.2: extend-shallow "^3.0.2" safe-regex "^1.1.0" +regexp.prototype.flags@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/regexp.prototype.flags/-/regexp.prototype.flags-1.2.0.tgz#6b30724e306a27833eeb171b66ac8890ba37e41c" + dependencies: + define-properties "^1.1.2" + +regexpp@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-1.1.0.tgz#0e3516dd0b7904f413d2d4193dce4618c3a689ab" + regexpu-core@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-2.0.0.tgz#49d038837b8dcf8bfa5b9a42139938e6ea2ae240" @@ -5131,7 +5958,7 @@ regjsparser@^0.1.4: dependencies: jsesc "~0.5.0" -reinterval@^1.0.1: +reinterval@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/reinterval/-/reinterval-1.1.0.tgz#3361ecfa3ca6c18283380dd0bb9546f390f5ece7" @@ -5167,7 +5994,21 @@ req-then@0.5.1: lodash.pick "^4.4.0" typical "^2.6.0" -request@^2.65.0, request@^2.79.0: +request-promise-core@1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/request-promise-core/-/request-promise-core-1.1.1.tgz#3eee00b2c5aa83239cfb04c5700da36f81cd08b6" + dependencies: + lodash "^4.13.1" + +request-promise-native@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/request-promise-native/-/request-promise-native-1.0.5.tgz#5281770f68e0c9719e5163fd3fab482215f4fda5" + dependencies: + request-promise-core "1.1.1" + stealthy-require "^1.1.0" + tough-cookie ">=2.3.3" + +request@^2.83.0: version "2.87.0" resolved "https://registry.yarnpkg.com/request/-/request-2.87.0.tgz#32f00235cd08d482b4d0d68db93a829c0ed5756e" dependencies: @@ -5192,7 +6033,19 @@ request@^2.65.0, request@^2.79.0: tunnel-agent "^0.6.0" uuid "^3.1.0" -require-uncached@^1.0.2: +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" + +require-main-filename@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" + +require-package-name@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/require-package-name/-/require-package-name-2.0.1.tgz#c11e97276b65b8e2923f75dabf5fb2ef0c3841b9" + +require-uncached@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/require-uncached/-/require-uncached-1.0.3.tgz#4e0d56d6c9662fd31e43011c4b95aa49955421d3" dependencies: @@ -5209,6 +6062,12 @@ requizzle@~0.2.1: dependencies: underscore "~1.6.0" +resolve-cwd@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/resolve-cwd/-/resolve-cwd-2.0.0.tgz#00a9f7387556e27038eae232caa372a6a59b665a" + dependencies: + resolve-from "^3.0.0" + resolve-dir@^1.0.0, resolve-dir@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/resolve-dir/-/resolve-dir-1.0.1.tgz#79a40644c362be82f26effe739c9bb5382046f43" @@ -5220,26 +6079,30 @@ resolve-from@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-1.0.1.tgz#26cbfe935d1aeeeabb29bc3fe5aeb01e93d44226" +resolve-from@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-3.0.0.tgz#b22c7af7d9d6881bc8b6e653335eebcb0a188748" + resolve-url@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" -resolve@1.1.x: +resolve@1.1.7: version "1.1.7" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.1.7.tgz#203114d82ad2c5ed9e8e0411b3932875e889e97b" -resolve@^1.1.6, resolve@^1.1.7: +resolve@^1.1.6, resolve@^1.1.7, resolve@^1.5.0, resolve@^1.6.0: version "1.8.1" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.8.1.tgz#82f1ec19a423ac1fbd080b0bab06ba36e84a7a26" dependencies: path-parse "^1.0.5" -restore-cursor@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-1.0.1.tgz#34661f46886327fed2991479152252df92daa541" +restore-cursor@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" dependencies: - exit-hook "^1.0.0" - onetime "^1.0.0" + onetime "^2.0.0" + signal-exit "^3.0.2" ret@~0.1.10: version "0.1.15" @@ -5251,7 +6114,7 @@ right-align@^0.1.1: dependencies: align-text "^0.1.1" -rimraf@^2.2.8, rimraf@^2.6.1: +rimraf@^2.2.8, rimraf@^2.5.4, rimraf@^2.6.1: version "2.6.2" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.2.tgz#2ed8150d24a16ea8651e6d6ef0f47c4158ce7a36" dependencies: @@ -5268,15 +6131,21 @@ ripemd160@^2.0.0, ripemd160@^2.0.1: hash-base "^3.0.0" inherits "^2.0.1" -run-async@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/run-async/-/run-async-0.1.0.tgz#c8ad4a5e110661e402a7d21b530e009f25f8e389" +rsvp@^3.3.3: + version "3.6.2" + resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-3.6.2.tgz#2e96491599a96cde1b515d5674a8f7a91452926a" + +run-async@^2.2.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" dependencies: - once "^1.3.0" + is-promise "^2.1.0" -rx-lite@^3.1.2: - version "3.1.2" - resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-3.1.2.tgz#19ce502ca572665f3b647b10939f97fd1615f102" +rxjs@^5.5.2: + version "5.5.11" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-5.5.11.tgz#f733027ca43e3bec6b994473be4ab98ad43ced87" + dependencies: + symbol-observable "1.0.1" safe-buffer@5.1.1: version "5.1.1" @@ -5296,37 +6165,30 @@ safe-regex@^1.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" -sane@^1.2.0: - version "1.7.0" - resolved "https://registry.yarnpkg.com/sane/-/sane-1.7.0.tgz#b3579bccb45c94cf20355cc81124990dfd346e30" +sane@^2.0.0: + version "2.5.2" + resolved "https://registry.yarnpkg.com/sane/-/sane-2.5.2.tgz#b4dc1861c21b427e929507a3e751e2a2cb8ab3fa" dependencies: - anymatch "^1.3.0" + anymatch "^2.0.0" + capture-exit "^1.2.0" exec-sh "^0.2.0" fb-watchman "^2.0.0" - minimatch "^3.0.2" + micromatch "^3.1.4" minimist "^1.1.1" walker "~1.0.5" - watch "~0.10.0" + watch "~0.18.0" + optionalDependencies: + fsevents "^1.2.3" -sax@^1.2.1, sax@^1.2.4: +sax@^1.2.4: version "1.2.4" resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9" -semver-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/semver-regex/-/semver-regex-1.0.0.tgz#92a4969065f9c70c694753d55248fc68f8f652c9" - -semver-truncate@^1.0.0: - version "1.1.2" - resolved "https://registry.yarnpkg.com/semver-truncate/-/semver-truncate-1.1.2.tgz#57f41de69707a62709a7e0104ba2117109ea47e8" - dependencies: - semver "^5.3.0" - -"semver@2 || 3 || 4 || 5", semver@^5.3.0: +"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.4.1, semver@^5.5.0: version "5.5.0" resolved "https://registry.yarnpkg.com/semver/-/semver-5.5.0.tgz#dc4bbc7a6ca9d916dee5d43516f0092b58f7b8ab" -semver@^4.0.3, semver@^4.1.0: +semver@^4.1.0: version "4.3.6" resolved "https://registry.yarnpkg.com/semver/-/semver-4.3.6.tgz#300bc6e0e86374f7ba61068b5b1ecd57fc6532da" @@ -5373,7 +6235,7 @@ serve-static@1.13.2: parseurl "~1.3.2" send "0.16.2" -set-blocking@~2.0.0: +set-blocking@^2.0.0, set-blocking@~2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" @@ -5399,6 +6261,10 @@ set-value@^2.0.0: is-plain-object "^2.0.3" split-string "^3.0.1" +setimmediate@^1.0.4: + version "1.0.5" + resolved "https://registry.yarnpkg.com/setimmediate/-/setimmediate-1.0.5.tgz#290cbb232e306942d7d7ea9b83732ab7856f8285" + setprototypeof@1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/setprototypeof/-/setprototypeof-1.0.3.tgz#66567e37043eeb4f04d91bd658c0cbefb55b8e04" @@ -5418,29 +6284,41 @@ sha.js@^2.4.0, sha.js@^2.4.8: inherits "^2.0.1" safe-buffer "^5.0.1" +shebang-command@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" + dependencies: + shebang-regex "^1.0.0" + shebang-regex@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" -shelljs@^0.6.0: - version "0.6.1" - resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.6.1.tgz#ec6211bed1920442088fe0f70b2837232ed2c8a8" +shellwords@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/shellwords/-/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b" sigmund@~1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/sigmund/-/sigmund-1.0.1.tgz#3ff21f198cad2175f9f3b781853fd94d0d19b590" -signal-exit@^3.0.0: +signal-exit@^3.0.0, signal-exit@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" +sisteransi@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-0.1.1.tgz#5431447d5f7d1675aac667ccd0b865a4994cb3ce" + slash@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/slash/-/slash-1.0.0.tgz#c41f2f6c39fc16d1cd17ad4b5d896114ae470d55" -slice-ansi@0.0.4: - version "0.0.4" - resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-0.0.4.tgz#edbf8903f66f7ce2f8eafd6ceed65e264c831b35" +slice-ansi@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-1.0.0.tgz#044f1a49d8842ff307aad6b505ed178bd950134d" + dependencies: + is-fullwidth-code-point "^2.0.0" snapdragon-node@^2.0.1: version "2.1.1" @@ -5499,7 +6377,7 @@ source-list-map@~0.1.7: version "0.1.8" resolved "https://registry.yarnpkg.com/source-list-map/-/source-list-map-0.1.8.tgz#c550b2ab5427f6b3f21f5afead88c4f5587b2106" -source-map-resolve@^0.5.0: +source-map-resolve@^0.5.0, source-map-resolve@^0.5.1: version "0.5.2" resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.2.tgz#72e2cc34095543e43b2c62b2c4c10d4a9054f259" dependencies: @@ -5515,11 +6393,18 @@ source-map-support@^0.4.15: dependencies: source-map "^0.5.6" +source-map-support@^0.5.6: + version "0.5.6" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.6.tgz#4435cee46b1aab62b8e8610ce60f788091c51c13" + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + source-map-url@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3" -source-map@^0.1.40, source-map@~0.1.7: +source-map@^0.1.38, source-map@^0.1.40, source-map@~0.1.7: version "0.1.43" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.1.43.tgz#c24bc146ca517c1471f5dacbe2571b2b7f9e3346" dependencies: @@ -5531,17 +6416,11 @@ source-map@^0.4.4, source-map@~0.4.1: dependencies: amdefine ">=0.0.4" -source-map@^0.5.0, source-map@^0.5.1, source-map@^0.5.6, source-map@^0.5.7, source-map@~0.5.1: +source-map@^0.5.0, source-map@^0.5.1, source-map@^0.5.3, source-map@^0.5.6, source-map@^0.5.7, source-map@~0.5.1: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" -source-map@~0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.2.0.tgz#dab73fbcfc2ba819b4de03bd6f6eaa48164b3f9d" - dependencies: - amdefine ">=0.0.4" - -source-map@~0.6.1: +source-map@^0.6.0, source-map@~0.6.0, source-map@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" @@ -5577,7 +6456,7 @@ split-string@^3.0.1, split-string@^3.0.2: dependencies: extend-shallow "^3.0.0" -split2@^2.0.1: +split2@^2.1.1: version "2.2.0" resolved "https://registry.yarnpkg.com/split2/-/split2-2.2.0.tgz#186b2575bcf83e85b7d18465756238ee4ee42493" dependencies: @@ -5602,6 +6481,10 @@ sshpk@^1.7.0: jsbn "~0.1.0" tweetnacl "~0.14.0" +stack-utils@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/stack-utils/-/stack-utils-1.0.1.tgz#d4f33ab54e8e38778b0ca5cfd3b3afb12db68620" + static-extend@^0.1.1: version "0.1.2" resolved "https://registry.yarnpkg.com/static-extend/-/static-extend-0.1.2.tgz#60809c39cbff55337226fd5e0b520f341f1fb5c6" @@ -5617,6 +6500,10 @@ statuses@~1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.4.0.tgz#bb73d446da2796106efcc1b601a253d6c46bd087" +stealthy-require@^1.1.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/stealthy-require/-/stealthy-require-1.1.1.tgz#35b09875b4ff49f26a777e509b3090a3226bf24b" + "stompjs@git://github.com/gfoiani/stomp-websocket.git#2.4.0": version "2.4.0" resolved "git://github.com/gfoiani/stomp-websocket.git#f7fe1d8fcdd9649f53c174f5e1a9470b23b36dfd" @@ -5647,7 +6534,7 @@ stream-connect@^1.0.1, stream-connect@^1.0.2: dependencies: array-back "^1.0.2" -stream-consume@^0.1.0, stream-consume@~0.1.0: +stream-consume@~0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/stream-consume/-/stream-consume-0.1.1.tgz#d3bdb598c2bd0ae82b8cac7ac50b1107a7996c48" @@ -5658,6 +6545,16 @@ stream-handlebars@~0.1.6: handlebars "^3.0.0" object-tools "^1.2.1" +stream-http@^2.7.2: + version "2.8.3" + resolved "https://registry.yarnpkg.com/stream-http/-/stream-http-2.8.3.tgz#b2d242469288a5a27ec4fe8933acf623de6514fc" + dependencies: + builtin-status-codes "^3.0.0" + inherits "^2.0.1" + readable-stream "^2.3.6" + to-arraybuffer "^1.0.0" + xtend "^4.0.0" + stream-shift@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.0.tgz#d5c752825e5367e786f78e18e445ea223a155952" @@ -5670,6 +6567,13 @@ stream-via@~0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/stream-via/-/stream-via-0.1.1.tgz#0cee5df9c959fb1d3f4eda4819f289d5f9205afc" +string-length@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/string-length/-/string-length-2.0.0.tgz#d40dbb686a3ace960c1cffca562bf2c45f8363ed" + dependencies: + astral-regex "^1.0.0" + strip-ansi "^4.0.0" + string-tools@^0.1.4: version "0.1.8" resolved "https://registry.yarnpkg.com/string-tools/-/string-tools-0.1.8.tgz#70884e86a26ee5103a078bef67033d558d36e337" @@ -5686,28 +6590,32 @@ string-width@^1.0.1: is-fullwidth-code-point "^1.0.0" strip-ansi "^3.0.0" -"string-width@^1.0.2 || 2", string-width@^2.0.0: +"string-width@^1.0.2 || 2", string-width@^2.0.0, string-width@^2.1.0, string-width@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" dependencies: is-fullwidth-code-point "^2.0.0" strip-ansi "^4.0.0" -string_decoder@~0.10.25, string_decoder@~0.10.x: - version "0.10.31" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" +string.prototype.matchall@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/string.prototype.matchall/-/string.prototype.matchall-2.0.0.tgz#2af8fe3d2d6dc53ca2a59bd376b089c3c152b3c8" + dependencies: + define-properties "^1.1.2" + es-abstract "^1.10.0" + function-bind "^1.1.1" + has-symbols "^1.0.0" + regexp.prototype.flags "^1.2.0" -string_decoder@~1.1.1: +string_decoder@^1.0.0, string_decoder@~1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" dependencies: safe-buffer "~5.1.0" -strip-ansi@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-0.3.0.tgz#25f48ea22ca79187f3174a4db8759347bb126220" - dependencies: - ansi-regex "^0.2.1" +string_decoder@~0.10.25, string_decoder@~0.10.x: + version "0.10.31" + resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" @@ -5721,6 +6629,14 @@ strip-ansi@^4.0.0: dependencies: ansi-regex "^3.0.0" +strip-bom-string@1.X: + version "1.0.0" + resolved "https://registry.yarnpkg.com/strip-bom-string/-/strip-bom-string-1.0.0.tgz#e5211e9224369fbb81d633a2f00044dc8cedad92" + +strip-bom@3.0.0, strip-bom@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-3.0.0.tgz#2334c18e9c759f7bdd56fdef7e9ae3d588e68ed3" + strip-bom@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-1.0.0.tgz#85b8862f3844b5a6d5ec8467a93598173a36f794" @@ -5734,35 +6650,35 @@ strip-bom@^2.0.0: dependencies: is-utf8 "^0.2.0" -strip-indent@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/strip-indent/-/strip-indent-1.0.1.tgz#0c7962a6adefa7bbd4ac366460a638552ae1a0a2" - dependencies: - get-stdin "^4.0.1" - -strip-json-comments@~1.0.1: - version "1.0.4" - resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-1.0.4.tgz#1e15fbcac97d3ee99bf2d73b4c656b082bbafb91" +strip-eof@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/strip-eof/-/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" -strip-json-comments@~2.0.1: +strip-json-comments@^2.0.1, strip-json-comments@~2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" -supports-color@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-0.2.0.tgz#d92de2694eb3f67323973d7ae3d8b55b4c22190a" - supports-color@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" -supports-color@^3.1.0, supports-color@^3.1.1: +supports-color@^3.1.0, supports-color@^3.1.1, supports-color@^3.1.2: version "3.2.3" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-3.2.3.tgz#65ac0504b3954171d8a64946b2ae3cbb8a5f54f6" dependencies: has-flag "^1.0.0" -symbol-tree@^3.2.1: +supports-color@^5.3.0: + version "5.4.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.4.0.tgz#1c6b337402c2137605efe19f10fec390f6faab54" + dependencies: + has-flag "^3.0.0" + +symbol-observable@1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/symbol-observable/-/symbol-observable-1.0.1.tgz#8340fc4702c3122df5d22288f88283f513d3fdd4" + +symbol-tree@^3.2.2: version "3.2.2" resolved "https://registry.yarnpkg.com/symbol-tree/-/symbol-tree-3.2.2.tgz#ae27db38f660a7ae2e1c3b7d1bc290819b8519e6" @@ -5777,16 +6693,16 @@ table-layout@^0.3.0: typical "^2.6.0" wordwrapjs "^2.0.0-0" -table@^3.7.8: - version "3.8.3" - resolved "https://registry.yarnpkg.com/table/-/table-3.8.3.tgz#2bbc542f0fda9861a755d3947fefd8b3f513855f" +table@^4.0.3: + version "4.0.3" + resolved "https://registry.yarnpkg.com/table/-/table-4.0.3.tgz#00b5e2b602f1794b9acaf9ca908a76386a7813bc" dependencies: - ajv "^4.7.0" - ajv-keywords "^1.0.0" - chalk "^1.1.1" - lodash "^4.0.0" - slice-ansi "0.0.4" - string-width "^2.0.0" + ajv "^6.0.1" + ajv-keywords "^3.0.0" + chalk "^2.1.0" + lodash "^4.17.4" + slice-ansi "1.0.0" + string-width "^2.1.1" taffydb@2.6.2: version "2.6.2" @@ -5812,6 +6728,16 @@ temp-path@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/temp-path/-/temp-path-1.0.0.tgz#24b1543973ab442896d9ad367dd9cbdbfafe918b" +test-exclude@^4.2.1: + version "4.2.1" + resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-4.2.1.tgz#dfa222f03480bca69207ca728b37d74b45f724fa" + dependencies: + arrify "^1.0.1" + micromatch "^3.1.8" + object-assign "^4.1.0" + read-pkg-up "^1.0.1" + require-main-filename "^1.0.1" + test-value@^1.0.1, test-value@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/test-value/-/test-value-1.1.0.tgz#a09136f72ec043d27c893707c2b159bfad7de93f" @@ -5826,7 +6752,7 @@ test-value@^2.0.0, test-value@^2.1.0: array-back "^1.0.3" typical "^2.6.0" -text-table@~0.2.0: +text-table@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" @@ -5836,20 +6762,31 @@ then-fs@^2.0.0: dependencies: promise ">=3.2 <8" -through2@^0.6.1, through2@^0.6.3: - version "0.6.5" - resolved "https://registry.yarnpkg.com/through2/-/through2-0.6.5.tgz#41ab9c67b29d57209071410e1d7a7a968cd3ad48" +throat@^4.0.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/throat/-/throat-4.1.0.tgz#89037cbc92c56ab18926e6ba4cbb200e15672a6a" + +through2-filter@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/through2-filter/-/through2-filter-2.0.0.tgz#60bc55a0dacb76085db1f9dae99ab43f83d622ec" dependencies: - readable-stream ">=1.0.33-1 <1.1.0-0" - xtend ">=4.0.0 <4.1.0-0" + through2 "~2.0.0" + xtend "~4.0.0" -through2@^2.0.0, through2@^2.0.1, through2@^2.0.2: +through2@2.X, through2@^2.0.0, through2@^2.0.1, through2@^2.0.2, through2@^2.0.3, through2@~2.0.0: version "2.0.3" resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.3.tgz#0004569b37c7c74ba39c43f3ced78d1ad94140be" dependencies: readable-stream "^2.1.5" xtend "~4.0.1" +through2@^0.6.1: + version "0.6.5" + resolved "https://registry.yarnpkg.com/through2/-/through2-0.6.5.tgz#41ab9c67b29d57209071410e1d7a7a968cd3ad48" + dependencies: + readable-stream ">=1.0.33-1 <1.1.0-0" + xtend ">=4.0.0 <4.1.0-0" + through@^2.3.6: version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" @@ -5874,14 +6811,48 @@ timers-browserify@^1.0.1: dependencies: process "~0.11.0" +timers-browserify@^2.0.4: + version "2.0.10" + resolved "https://registry.yarnpkg.com/timers-browserify/-/timers-browserify-2.0.10.tgz#1d28e3d2aadf1d5a5996c4e9f95601cd053480ae" + dependencies: + setimmediate "^1.0.4" + +timers-ext@^0.1.2: + version "0.1.5" + resolved "https://registry.yarnpkg.com/timers-ext/-/timers-ext-0.1.5.tgz#77147dd4e76b660c2abb8785db96574cbbd12922" + dependencies: + es5-ext "~0.10.14" + next-tick "1" + +tmp@^0.0.33: + version "0.0.33" + resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" + dependencies: + os-tmpdir "~1.0.2" + tmpl@1.0.x: version "1.0.4" resolved "https://registry.yarnpkg.com/tmpl/-/tmpl-1.0.4.tgz#23640dd7b42d00433911140820e5cf440e521dd1" +to-absolute-glob@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/to-absolute-glob/-/to-absolute-glob-2.0.2.tgz#1865f43d9e74b0822db9f145b78cff7d0f7c849b" + dependencies: + is-absolute "^1.0.0" + is-negated-glob "^1.0.0" + +to-arraybuffer@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/to-arraybuffer/-/to-arraybuffer-1.0.1.tgz#7d229b1fcc637e466ca081180836a7aabff83f43" + to-fast-properties@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-1.0.3.tgz#b83571fa4d8c25b82e231b06e3a3055de4ca1a47" +to-fast-properties@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" + to-object-path@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/to-object-path/-/to-object-path-0.3.0.tgz#297588b7b0e7e0ac08e04e672f85c1f4999e17af" @@ -5904,7 +6875,7 @@ to-regex@^3.0.1, to-regex@^3.0.2: regex-not "^1.0.2" safe-regex "^1.1.0" -tough-cookie@^2.3.2: +tough-cookie@>=2.3.3, tough-cookie@^2.3.3: version "2.4.3" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.4.3.tgz#53f36da3f47783b0925afa06ff9f3b165280f781" dependencies: @@ -5917,13 +6888,11 @@ tough-cookie@~2.3.3: dependencies: punycode "^1.4.1" -tr46@~0.0.3: - version "0.0.3" - resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" - -trim-newlines@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-1.0.0.tgz#5887966bb582a4503a41eb524f7d35011815a613" +tr46@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/tr46/-/tr46-1.0.1.tgz#a8b13fd6bfd2489519674ccde55ba3693b706d09" + dependencies: + punycode "^2.1.0" trim-right@^1.0.1: version "1.0.1" @@ -6000,9 +6969,9 @@ uglify-to-browserify@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz#6e0924d6bda6b5afe349e39a6d632850a0f882b7" -ultron@1.0.x: - version "1.0.2" - resolved "https://registry.yarnpkg.com/ultron/-/ultron-1.0.2.tgz#ace116ab557cd197386a4e88f4685378c8b2e4fa" +ultron@~1.1.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/ultron/-/ultron-1.1.1.tgz#9fe1536a10a664a65266a1e3ccf85fd36302bc9c" unc-path-regex@^0.1.2: version "0.1.2" @@ -6014,19 +6983,15 @@ underscore-contrib@~0.3.0: dependencies: underscore "1.6.0" -underscore.string@2.0.x: - version "2.0.0" - resolved "https://registry.yarnpkg.com/underscore.string/-/underscore.string-2.0.0.tgz#7470858a54a0bb3560d037da56dcc67b5181e11a" - -underscore@1.2.x: - version "1.2.4" - resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.2.4.tgz#e8da6241aa06f64df2473bb2590b8c17c84c3c7e" - underscore@1.6.0, underscore@~1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.6.0.tgz#8b38b10cacdef63337b8b24e4ff86d45aea529a8" -underscore@1.8.3, underscore@~1.8.3: +underscore@1.9.1: + version "1.9.1" + resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.9.1.tgz#06dce34a0e68a7babc29b365b8e74b8925203961" + +underscore@~1.8.3: version "1.8.3" resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.8.3.tgz#4f3fb53b106e6097fcf9cb4109f2a5e9bdfa5022" @@ -6043,6 +7008,13 @@ unique-stream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/unique-stream/-/unique-stream-1.0.0.tgz#d59a4a75427447d9aa6c91e70263f8d26a4b104b" +unique-stream@^2.0.2: + version "2.2.1" + resolved "https://registry.yarnpkg.com/unique-stream/-/unique-stream-2.2.1.tgz#5aa003cfbe94c5ff866c4e7d668bb1c4dbadb369" + dependencies: + json-stable-stringify "^1.0.0" + through2-filter "^2.0.0" + unpipe@1.0.0, unpipe@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/unpipe/-/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec" @@ -6054,6 +7026,12 @@ unset-value@^1.0.0: has-value "^0.3.1" isobject "^3.0.0" +uri-js@^4.2.1: + version "4.2.2" + resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.2.2.tgz#94c540e1ff772956e2299507c010aea6c8838eb0" + dependencies: + punycode "^2.1.0" + urix@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72" @@ -6065,16 +7043,16 @@ url-parse@^1.1.8, url-parse@~1.4.0: querystringify "^2.0.0" requires-port "^1.0.0" -url@~0.10.1: - version "0.10.3" - resolved "https://registry.yarnpkg.com/url/-/url-0.10.3.tgz#021e4d9c7705f21bbf37d03ceb58767402774c64" +url@^0.11.0: + version "0.11.0" + resolved "https://registry.yarnpkg.com/url/-/url-0.11.0.tgz#3838e97cfc60521eb73c525a8e55bfdd9e2e28f1" dependencies: punycode "1.3.2" querystring "0.2.0" -url@~0.11.0: - version "0.11.0" - resolved "https://registry.yarnpkg.com/url/-/url-0.11.0.tgz#3838e97cfc60521eb73c525a8e55bfdd9e2e28f1" +url@~0.10.1: + version "0.10.3" + resolved "https://registry.yarnpkg.com/url/-/url-0.10.3.tgz#021e4d9c7705f21bbf37d03ceb58767402774c64" dependencies: punycode "1.3.2" querystring "0.2.0" @@ -6103,16 +7081,17 @@ user-home@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/user-home/-/user-home-1.1.1.tgz#2b5be23a32b63a7c9deb8d0f28d485724a3df190" -user-home@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/user-home/-/user-home-2.0.0.tgz#9c70bfd8169bc1dcbf48604e0f04b8b49cde9e9f" - dependencies: - os-homedir "^1.0.0" - util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" +util.promisify@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/util.promisify/-/util.promisify-1.0.0.tgz#440f7165a459c9a16dc145eb8e72f35687097030" + dependencies: + define-properties "^1.1.2" + object.getownpropertydescriptors "^2.0.3" + util@0.10.3: version "0.10.3" resolved "https://registry.yarnpkg.com/util/-/util-0.10.3.tgz#7afb1afe50805246489e3db7fe0ed379336ac0f9" @@ -6133,7 +7112,7 @@ uuid@^3.0.1, uuid@^3.1.0: version "3.3.2" resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz#1b4af4955eb3077c501c23872fc6513811587131" -v8flags@^2.0.10, v8flags@^2.0.2: +v8flags@^2.0.2, v8flags@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-2.1.1.tgz#aab1a1fa30d45f88dd321148875ac02c0b55e5b4" dependencies: @@ -6177,7 +7156,7 @@ vinyl-sourcemaps-apply@^0.2.0: dependencies: source-map "^0.5.1" -vinyl@^0.4.0, vinyl@^0.4.3: +vinyl@^0.4.0: version "0.4.6" resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-0.4.6.tgz#2f356c87a550a255461f36bbeb2a5ba8bf784847" dependencies: @@ -6192,20 +7171,18 @@ vinyl@^0.5.0: clone-stats "^0.0.1" replace-ext "0.0.1" -vinyl@^1.0.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-1.2.0.tgz#5c88036cf565e5df05558bfc911f8656df218884" - dependencies: - clone "^1.0.0" - clone-stats "^0.0.1" - replace-ext "0.0.1" - vm-browserify@0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/vm-browserify/-/vm-browserify-0.0.4.tgz#5d7ea45bbef9e4a6ff65f95438e0a87c357d5a73" dependencies: indexof "0.0.1" +w3c-hr-time@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/w3c-hr-time/-/w3c-hr-time-1.0.1.tgz#82ac2bff63d950ea9e3189a58a65625fedf19045" + dependencies: + browser-process-hrtime "^0.1.2" + walk-back@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/walk-back/-/walk-back-2.0.1.tgz#554e2a9d874fac47a8cb006bf44c2f0c4998a0a4" @@ -6216,9 +7193,12 @@ walker@~1.0.5: dependencies: makeerror "1.0.x" -watch@~0.10.0: - version "0.10.0" - resolved "https://registry.yarnpkg.com/watch/-/watch-0.10.0.tgz#77798b2da0f9910d595f1ace5b0c2258521f21dc" +watch@~0.18.0: + version "0.18.0" + resolved "https://registry.yarnpkg.com/watch/-/watch-0.18.0.tgz#28095476c6df7c90c963138990c0a5423eb4b986" + dependencies: + exec-sh "^0.2.0" + minimist "^1.2.0" watchpack@^0.2.1: version "0.2.9" @@ -6228,11 +7208,7 @@ watchpack@^0.2.1: chokidar "^1.0.0" graceful-fs "^4.1.2" -webidl-conversions@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" - -webidl-conversions@^4.0.0: +webidl-conversions@^4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-4.0.2.tgz#a855980b1f0b6b359ba1d5d9fb39ae941faa63ad" @@ -6305,14 +7281,15 @@ websocket-extensions@>=0.1.1: version "0.1.3" resolved "https://registry.yarnpkg.com/websocket-extensions/-/websocket-extensions-0.1.3.tgz#5d2ff22977003ec687a4b87073dfbbac146ccf29" -websocket-stream@^3.0.1: - version "3.3.3" - resolved "https://registry.yarnpkg.com/websocket-stream/-/websocket-stream-3.3.3.tgz#361da5404a337e60cfbc29b4a46368762679df0b" +websocket-stream@^5.1.2: + version "5.1.2" + resolved "https://registry.yarnpkg.com/websocket-stream/-/websocket-stream-5.1.2.tgz#1c31c627bcdf34f1a9bdacc9daa15bfa4816d9ad" dependencies: - duplexify "^3.2.0" + duplexify "^3.5.1" inherits "^2.0.1" - through2 "^2.0.0" - ws "^1.0.1" + readable-stream "^2.3.3" + safe-buffer "^5.1.1" + ws "^3.2.0" xtend "^4.0.0" websocket@latest: @@ -6324,32 +7301,33 @@ websocket@latest: typedarray-to-buffer "^3.1.2" yaeti "^0.0.6" -whatwg-encoding@^1.0.1: +whatwg-encoding@^1.0.1, whatwg-encoding@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/whatwg-encoding/-/whatwg-encoding-1.0.3.tgz#57c235bc8657e914d24e1a397d3c82daee0a6ba3" dependencies: iconv-lite "0.4.19" -whatwg-url@^4.3.0: - version "4.8.0" - resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-4.8.0.tgz#d2981aa9148c1e00a41c5a6131166ab4683bbcc0" - dependencies: - tr46 "~0.0.3" - webidl-conversions "^3.0.0" +whatwg-mimetype@^2.0.0, whatwg-mimetype@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/whatwg-mimetype/-/whatwg-mimetype-2.1.0.tgz#f0f21d76cbba72362eb609dbed2a30cd17fcc7d4" -when@3.7.5: - version "3.7.5" - resolved "https://registry.yarnpkg.com/when/-/when-3.7.5.tgz#199ff1142989624957bff61ac1a2e715af3f610a" +whatwg-url@^6.4.0, whatwg-url@^6.4.1: + version "6.5.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-6.5.0.tgz#f2df02bff176fd65070df74ad5ccbb5a199965a8" + dependencies: + lodash.sortby "^4.7.0" + tr46 "^1.0.1" + webidl-conversions "^4.0.2" -when@~3.6.2: - version "3.6.4" - resolved "https://registry.yarnpkg.com/when/-/when-3.6.4.tgz#473b517ec159e2b85005497a13983f095412e34e" +when@3.7.8: + version "3.7.8" + resolved "https://registry.yarnpkg.com/when/-/when-3.7.8.tgz#c7130b6a7ea04693e842cdc9e7a1f2aa39a39f82" -which@1.0.x: - version "1.0.9" - resolved "https://registry.yarnpkg.com/which/-/which-1.0.9.tgz#460c1da0f810103d0321a9b633af9e575e64486f" +which-module@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.0.tgz#d9ef07dce77b9902b8a3a8fa4b31c3e3f7e6e87a" -which@^1.1.1, which@^1.2.14: +which@^1.2.12, which@^1.2.14, which@^1.2.9, which@^1.3.0: version "1.3.1" resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" dependencies: @@ -6369,14 +7347,14 @@ wordwrap@0.0.2: version "0.0.2" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.2.tgz#b79669bb42ecb409f83d583cad52ca17eaa1643f" -wordwrap@^1.0.0, wordwrap@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" - wordwrap@~0.0.2: version "0.0.3" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107" +wordwrap@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" + wordwrapjs@^1.2.0: version "1.2.1" resolved "https://registry.yarnpkg.com/wordwrapjs/-/wordwrapjs-1.2.1.tgz#754a5ea0664cfbff50540dc32d67bda3289fc34b" @@ -6393,45 +7371,93 @@ wordwrapjs@^2.0.0-0: reduce-flatten "^1.0.1" typical "^2.6.0" -worker-farm@^1.3.1: - version "1.6.0" - resolved "https://registry.yarnpkg.com/worker-farm/-/worker-farm-1.6.0.tgz#aecc405976fab5a95526180846f0dba288f3a4a0" +wrap-ansi@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" dependencies: - errno "~0.1.7" + string-width "^1.0.1" + strip-ansi "^3.0.1" wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" +write-file-atomic@^2.1.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-2.3.0.tgz#1ff61575c2e2a4e8e510d6fa4e243cce183999ab" + dependencies: + graceful-fs "^4.1.11" + imurmurhash "^0.1.4" + signal-exit "^3.0.2" + write@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/write/-/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" dependencies: mkdirp "^0.5.1" -ws@^1.0.1: - version "1.1.5" - resolved "https://registry.yarnpkg.com/ws/-/ws-1.1.5.tgz#cbd9e6e75e09fc5d2c90015f21f0c40875e0dd51" +ws@^3.2.0: + version "3.3.3" + resolved "https://registry.yarnpkg.com/ws/-/ws-3.3.3.tgz#f1cf84fe2d5e901ebce94efaece785f187a228f2" dependencies: - options ">=0.0.5" - ultron "1.0.x" + async-limiter "~1.0.0" + safe-buffer "~5.1.0" + ultron "~1.1.0" -xml-name-validator@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/xml-name-validator/-/xml-name-validator-2.0.1.tgz#4d8b8f1eccd3419aa362061becef515e1e559635" +ws@^4.0.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/ws/-/ws-4.1.0.tgz#a979b5d7d4da68bf54efe0408967c324869a7289" + dependencies: + async-limiter "~1.0.0" + safe-buffer "~5.1.0" + +xml-name-validator@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/xml-name-validator/-/xml-name-validator-3.0.0.tgz#6ae73e06de4d8c6e47f9fb181f78d648ad457c6a" -"xtend@>=4.0.0 <4.1.0-0", xtend@^4.0.0, xtend@~4.0.1: +"xtend@>=4.0.0 <4.1.0-0", xtend@^4.0.0, xtend@^4.0.1, xtend@~4.0.0, xtend@~4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af" +y18n@^3.2.1: + version "3.2.1" + resolved "https://registry.yarnpkg.com/y18n/-/y18n-3.2.1.tgz#6d15fba884c08679c0d77e88e7759e811e07fa41" + yaeti@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/yaeti/-/yaeti-0.0.6.tgz#f26f484d72684cf42bedfb76970aa1608fbf9577" +yallist@^2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" + yallist@^3.0.0, yallist@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.0.2.tgz#8452b4bb7e83c7c188d8041c1a837c773d6d8bb9" +yargs-parser@^9.0.2: + version "9.0.2" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-9.0.2.tgz#9ccf6a43460fe4ed40a9bb68f48d43b8a68cc077" + dependencies: + camelcase "^4.1.0" + +yargs@^11.0.0: + version "11.1.0" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-11.1.0.tgz#90b869934ed6e871115ea2ff58b03f4724ed2d77" + dependencies: + cliui "^4.0.0" + decamelize "^1.1.1" + find-up "^2.1.0" + get-caller-file "^1.0.1" + os-locale "^2.0.0" + require-directory "^2.1.1" + require-main-filename "^1.0.1" + set-blocking "^2.0.0" + string-width "^2.0.0" + which-module "^2.0.0" + y18n "^3.2.1" + yargs-parser "^9.0.2" + yargs@~3.10.0: version "3.10.0" resolved "https://registry.yarnpkg.com/yargs/-/yargs-3.10.0.tgz#f7ee7bd857dd7c1d2d38c0e74efbd681d1431fd1"