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

logplease

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

logplease - npm Package Compare versions

Comparing version 1.2.7 to 1.2.8

2

dist/logplease.min.js

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

var Logger=function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="",e(e.s=20)}([function(t,e){var n=t.exports={version:"2.4.0"};"number"==typeof __e&&(__e=n)},function(t,e,n){t.exports=!n(2)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(t,e){t.exports=function(t){try{return!!t()}catch(e){return!0}}},function(t,e,n){e.nextTick=function(t){setTimeout(t,0)},e.platform=e.arch=e.execPath=e.title="browser",e.pid=1,e.browser=!0,e.env={},e.argv=[],e.binding=function(t){throw new Error("No such module. (Possibly not yet loaded)")},function(){var t,r="/";e.cwd=function(){return r},e.chdir=function(e){t||(t=n(51)),r=t.resolve(e,r)}}(),e.exit=e.kill=e.umask=e.dlopen=e.uptime=e.memoryUsage=e.uvCounters=function(){},e.features={}},function(t,e,n){var r=n(5),o=n(0),i=n(29),u=n(33),c="prototype",s=function(t,e,n){var f,a,l,p=t&s.F,h=t&s.G,y=t&s.S,v=t&s.P,g=t&s.B,d=t&s.W,m=h?o:o[e]||(o[e]={}),b=m[c],w=h?r:y?r[e]:(r[e]||{})[c];h&&(n=e);for(f in n)a=!p&&w&&void 0!==w[f],a&&f in m||(l=a?w[f]:n[f],m[f]=h&&"function"!=typeof w[f]?n[f]:g&&a?i(l,r):d&&w[f]==l?function(t){var e=function(e,n,r){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,n)}return new t(e,n,r)}return t.apply(this,arguments)};return e[c]=t[c],e}(l):v&&"function"==typeof l?i(Function.call,l):l,v&&((m.virtual||(m.virtual={}))[f]=l,t&s.R&&b&&!b[f]&&u(b,f,l)))};s.F=1,s.G=2,s.S=4,s.P=8,s.B=16,s.W=32,s.U=64,s.R=128,t.exports=s},function(t,e){var n=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},function(t,e,n){var r=n(28);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==r(t)?t.split(""):Object(t)}},function(t,e,n){var r=n(26),o=n(34),i=n(45),u=Object.defineProperty;e.f=n(1)?Object.defineProperty:function(t,e,n){if(r(t),e=i(e,!0),r(n),o)try{return u(t,e,n)}catch(c){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(t[e]=n.value),t}},function(t,e,n){var r=n(37),o=n(31);t.exports=Object.keys||function(t){return r(t,o)}},function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},function(t,e,n){var r=n(8),o=n(7);t.exports=function(t){return r(o(t))}},function(t,e,n){var r=n(7);t.exports=function(t){return Object(r(t))}},function(t,e,n){t.exports={"default":n(22),__esModule:!0}},function(t,e,n){t.exports={"default":n(24),__esModule:!0}},function(t,e){"use strict";e.__esModule=!0,e["default"]=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{"default":t}}e.__esModule=!0;var o=n(21),i=r(o);e["default"]=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),(0,i["default"])(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}()},function(t,e,n){(function(t,r){function o(t,n){var r={seen:[],stylize:u};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),v(n)?r.showHidden=n:n&&e._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=i),s(r,t,r.depth)}function i(t,e){var n=o.styles[e];return n?"["+o.colors[n][0]+"m"+t+"["+o.colors[n][1]+"m":t}function u(t,e){return t}function c(t){var e={};return t.forEach(function(t,n){e[t]=!0}),e}function s(t,n,r){if(t.customInspect&&n&&E(n.inspect)&&n.inspect!==e.inspect&&(!n.constructor||n.constructor.prototype!==n)){var o=n.inspect(r,t);return b(o)||(o=s(t,o,r)),o}var i=f(t,n);if(i)return i;var u=Object.keys(n),v=c(u);if(t.showHidden&&(u=Object.getOwnPropertyNames(n)),S(n)&&(u.indexOf("message")>=0||u.indexOf("description")>=0))return a(n);if(0===u.length){if(E(n)){var g=n.name?": "+n.name:"";return t.stylize("[Function"+g+"]","special")}if(O(n))return t.stylize(RegExp.prototype.toString.call(n),"regexp");if(_(n))return t.stylize(Date.prototype.toString.call(n),"date");if(S(n))return a(n)}var d="",m=!1,w=["{","}"];if(y(n)&&(m=!0,w=["[","]"]),E(n)){var x=n.name?": "+n.name:"";d=" [Function"+x+"]"}if(O(n)&&(d=" "+RegExp.prototype.toString.call(n)),_(n)&&(d=" "+Date.prototype.toUTCString.call(n)),S(n)&&(d=" "+a(n)),0===u.length&&(!m||0==n.length))return w[0]+d+w[1];if(0>r)return O(n)?t.stylize(RegExp.prototype.toString.call(n),"regexp"):t.stylize("[Object]","special");t.seen.push(n);var j;return j=m?l(t,n,r,v,u):u.map(function(e){return p(t,n,r,v,e,m)}),t.seen.pop(),h(j,d,w)}function f(t,e){if(x(e))return t.stylize("undefined","undefined");if(b(e)){var n="'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return t.stylize(n,"string")}return m(e)?t.stylize(""+e,"number"):v(e)?t.stylize(""+e,"boolean"):g(e)?t.stylize("null","null"):void 0}function a(t){return"["+Error.prototype.toString.call(t)+"]"}function l(t,e,n,r,o){for(var i=[],u=0,c=e.length;c>u;++u)L(e,String(u))?i.push(p(t,e,n,r,String(u),!0)):i.push("");return o.forEach(function(o){o.match(/^\d+$/)||i.push(p(t,e,n,r,o,!0))}),i}function p(t,e,n,r,o,i){var u,c,f;if(f=Object.getOwnPropertyDescriptor(e,o)||{value:e[o]},f.get?c=f.set?t.stylize("[Getter/Setter]","special"):t.stylize("[Getter]","special"):f.set&&(c=t.stylize("[Setter]","special")),L(r,o)||(u="["+o+"]"),c||(t.seen.indexOf(f.value)<0?(c=g(n)?s(t,f.value,null):s(t,f.value,n-1),c.indexOf("\n")>-1&&(c=i?c.split("\n").map(function(t){return" "+t}).join("\n").substr(2):"\n"+c.split("\n").map(function(t){return" "+t}).join("\n"))):c=t.stylize("[Circular]","special")),x(u)){if(i&&o.match(/^\d+$/))return c;u=JSON.stringify(""+o),u.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(u=u.substr(1,u.length-2),u=t.stylize(u,"name")):(u=u.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),u=t.stylize(u,"string"))}return u+": "+c}function h(t,e,n){var r=0,o=t.reduce(function(t,e){return r++,e.indexOf("\n")>=0&&r++,t+e.replace(/\u001b\[\d\d?m/g,"").length+1},0);return o>60?n[0]+(""===e?"":e+"\n ")+" "+t.join(",\n ")+" "+n[1]:n[0]+e+" "+t.join(", ")+" "+n[1]}function y(t){return Array.isArray(t)}function v(t){return"boolean"==typeof t}function g(t){return null===t}function d(t){return null==t}function m(t){return"number"==typeof t}function b(t){return"string"==typeof t}function w(t){return"symbol"==typeof t}function x(t){return void 0===t}function O(t){return j(t)&&"[object RegExp]"===k(t)}function j(t){return"object"==typeof t&&null!==t}function _(t){return j(t)&&"[object Date]"===k(t)}function S(t){return j(t)&&("[object Error]"===k(t)||t instanceof Error)}function E(t){return"function"==typeof t}function R(t){return null===t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||"symbol"==typeof t||"undefined"==typeof t}function k(t){return Object.prototype.toString.call(t)}function M(t){return 10>t?"0"+t.toString(10):t.toString(10)}function N(){var t=new Date,e=[M(t.getHours()),M(t.getMinutes()),M(t.getSeconds())].join(":");return[t.getDate(),A[t.getMonth()],e].join(" ")}function L(t,e){return Object.prototype.hasOwnProperty.call(t,e)}var z=/%[sdj%]/g;e.format=function(t){if(!b(t)){for(var e=[],n=0;n<arguments.length;n++)e.push(o(arguments[n]));return e.join(" ")}for(var n=1,r=arguments,i=r.length,u=String(t).replace(z,function(t){if("%%"===t)return"%";if(n>=i)return t;switch(t){case"%s":return String(r[n++]);case"%d":return Number(r[n++]);case"%j":try{return JSON.stringify(r[n++])}catch(e){return"[Circular]"}default:return t}}),c=r[n];i>n;c=r[++n])u+=g(c)||!j(c)?" "+c:" "+o(c);return u},e.deprecate=function(n,o){function i(){if(!u){if(r.throwDeprecation)throw new Error(o);r.traceDeprecation?console.trace(o):console.error(o),u=!0}return n.apply(this,arguments)}if(x(t.process))return function(){return e.deprecate(n,o).apply(this,arguments)};if(r.noDeprecation===!0)return n;var u=!1;return i};var D,T={};e.debuglog=function(t){if(x(D)&&(D=r.env.NODE_DEBUG||""),t=t.toUpperCase(),!T[t])if(new RegExp("\\b"+t+"\\b","i").test(D)){var n=r.pid;T[t]=function(){var r=e.format.apply(e,arguments);console.error("%s %d: %s",t,n,r)}}else T[t]=function(){};return T[t]},e.inspect=o,o.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},o.styles={special:"cyan",number:"yellow","boolean":"yellow",undefined:"grey","null":"bold",string:"green",date:"magenta",regexp:"red"},e.isArray=y,e.isBoolean=v,e.isNull=g,e.isNullOrUndefined=d,e.isNumber=m,e.isString=b,e.isSymbol=w,e.isUndefined=x,e.isRegExp=O,e.isObject=j,e.isDate=_,e.isError=S,e.isFunction=E,e.isPrimitive=R,e.isBuffer=n(52);var A=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];e.log=function(){console.log("%s - %s",N(),e.format.apply(e,arguments))},e.inherits=n(50),e._extend=function(t,e){if(!e||!j(e))return t;for(var n=Object.keys(e),r=n.length;r--;)t[n[r]]=e[n[r]];return t}}).call(e,n(53),n(3))},function(t,e){t.exports={}},function(t,e,n){"use strict";(function(e){function r(t){return t&&t.__esModule?t:{"default":t}}var o=n(15),i=r(o),u=n(14),c=r(u),s=n(16),f=r(s),a=n(17),l=r(a),p=n(19),h=n(18).format,y=!!e.version,v={DEBUG:"DEBUG",INFO:"INFO",WARN:"WARN",ERROR:"ERROR",NONE:"NONE"},g=v.DEBUG,d=null,m={Black:0,Red:1,Green:2,Yellow:3,Blue:4,Magenta:5,Cyan:6,Grey:7,White:9,Default:9};y||(m={Black:"Black",Red:"IndianRed",Green:"LimeGreen",Yellow:"Orange",Blue:"RoyalBlue",Magenta:"Orchid",Cyan:"SkyBlue",Grey:"DimGrey",White:"White",Default:"Black"});var b=[m.Cyan,m.Green,m.Yellow,m.Red,m.Default],w={useColors:!0,color:m.Default,showTimestamp:!0,showLevel:!0,filename:d,appendFile:!0},x=function(){function t(e,n){(0,f["default"])(this,t),this.category=e;var r={};(0,c["default"])(r,w),(0,c["default"])(r,n),this.options=r}return(0,l["default"])(t,[{key:"debug",value:function(){this._write(v.DEBUG,h.apply(null,arguments))}},{key:"log",value:function(){this.debug.apply(this,arguments)}},{key:"info",value:function(){this._write(v.INFO,h.apply(null,arguments))}},{key:"warn",value:function(){this._write(v.WARN,h.apply(null,arguments))}},{key:"error",value:function(){this._write(v.ERROR,h.apply(null,arguments))}},{key:"_write",value:function(t,e){if(this._shouldLog(t)){!this.options.filename&&!d||this.fileWriter||(this.fileWriter=p.openSync(this.options.filename||d,this.options.appendFile?"a+":"w+"));var n=this._format(t,e),r=this._createLogMessage(t,e),o=this._createLogMessage(t,e,n.timestamp,n.level,n.category,n.text);this.fileWriter&&p.writeSync(this.fileWriter,r+"\n",null,"utf-8"),y?console.log(o):t===v.ERROR?this.options.showTimestamp&&this.options.showLevel?console.error(o,n.timestamp,n.level,n.category,n.text):this.options.showTimestamp&&!this.options.showLevel?console.error(o,n.timestamp,n.category,n.text):!this.options.showTimestamp&&this.options.showLevel?console.error(o,n.level,n.category,n.text):console.error(o,n.category,n.text):this.options.showTimestamp&&this.options.showLevel?console.log(o,n.timestamp,n.level,n.category,n.text):this.options.showTimestamp&&!this.options.showLevel?console.log(o,n.timestamp,n.category,n.text):!this.options.showTimestamp&&this.options.showLevel?console.log(o,n.level,n.category,n.text):console.log(o,n.category,n.text)}}},{key:"_format",value:function(t,e){var n="",r="",o="",u=": ";if(this.options.useColors){var c=(0,i["default"])(v).map(function(t){return v[t]}).indexOf(t),s=this.options.color;y?(this.options.showTimestamp&&(n="[3"+m.Grey+"m"),this.options.showLevel&&(r="[3"+b[c]+";22m"),o="[3"+s+";1m",u=": "):(this.options.showTimestamp&&(n="color:"+m.Grey),this.options.showLevel&&(r="color:"+b[c]),o="color:"+s+"; font-weight: bold")}return{timestamp:n,level:r,category:o,text:u}}},{key:"_createLogMessage",value:function(t,e,n,r,o,i){n=n||"",r=r||"",o=o||"",i=i||": ",y||(this.options.showTimestamp&&(n="%c"),this.options.showLevel&&(r="%c"),o="%c",i=": %c");var u="";return this.options.showTimestamp&&(u+=""+(new Date).toISOString()+" "),u=n+u,this.options.showLevel&&(u+=r+"["+t+"]"+(t===v.INFO||t===v.WARN?" ":"")+" "),u+=o+this.category,u+=i+e}},{key:"_shouldLog",value:function(t){var e=(0,i["default"])(v).map(function(t){return v[t]}),n=e.indexOf(t),r=e.indexOf(g);return n>=r}}]),t}();t.exports={Colors:m,LogLevels:v,setLogLevel:function(t){g=t},setLogfile:function(t){d=t},create:function(t,e){var n=new x(t,e);return n},forceBrowserMode:function(t){return y=!t}}}).call(e,n(3))},function(t,e,n){t.exports={"default":n(23),__esModule:!0}},function(t,e,n){n(47),t.exports=n(0).Object.assign},function(t,e,n){n(48);var r=n(0).Object;t.exports=function(t,e,n){return r.defineProperty(t,e,n)}},function(t,e,n){n(49),t.exports=n(0).Object.keys},function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,e,n){var r=n(6);t.exports=function(t){if(!r(t))throw TypeError(t+" is not an object!");return t}},function(t,e,n){var r=n(12),o=n(44),i=n(43);t.exports=function(t){return function(e,n,u){var c,s=r(e),f=o(s.length),a=i(u,f);if(t&&n!=n){for(;f>a;)if(c=s[a++],c!=c)return!0}else for(;f>a;a++)if((t||a in s)&&s[a]===n)return t||a||0;return!t&&-1}}},function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},function(t,e,n){var r=n(25);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,o){return t.call(e,n,r,o)}}return function(){return t.apply(e,arguments)}}},function(t,e,n){var r=n(6),o=n(5).document,i=r(o)&&r(o.createElement);t.exports=function(t){return i?o.createElement(t):{}}},function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},function(t,e,n){var r=n(9),o=n(40);t.exports=n(1)?function(t,e,n){return r.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},function(t,e,n){t.exports=!n(1)&&!n(2)(function(){return 7!=Object.defineProperty(n(30)("div"),"a",{get:function(){return 7}}).a})},function(t,e,n){"use strict";var r=n(10),o=n(36),i=n(38),u=n(13),c=n(8),s=Object.assign;t.exports=!s||n(2)(function(){var t={},e={},n=Symbol(),r="abcdefghijklmnopqrst";return t[n]=7,r.split("").forEach(function(t){e[t]=t}),7!=s({},t)[n]||Object.keys(s({},e)).join("")!=r})?function(t,e){for(var n=u(t),s=arguments.length,f=1,a=o.f,l=i.f;s>f;)for(var p,h=c(arguments[f++]),y=a?r(h).concat(a(h)):r(h),v=y.length,g=0;v>g;)l.call(h,p=y[g++])&&(n[p]=h[p]);return n}:s},function(t,e){e.f=Object.getOwnPropertySymbols},function(t,e,n){var r=n(32),o=n(12),i=n(27)(!1),u=n(41)("IE_PROTO");t.exports=function(t,e){var n,c=o(t),s=0,f=[];for(n in c)n!=u&&r(c,n)&&f.push(n);for(;e.length>s;)r(c,n=e[s++])&&(~i(f,n)||f.push(n));return f}},function(t,e){e.f={}.propertyIsEnumerable},function(t,e,n){var r=n(4),o=n(0),i=n(2);t.exports=function(t,e){var n=(o.Object||{})[t]||Object[t],u={};u[t]=e(n),r(r.S+r.F*i(function(){n(1)}),"Object",u)}},function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},function(t,e,n){var r=n(42)("keys"),o=n(46);t.exports=function(t){return r[t]||(r[t]=o(t))}},function(t,e,n){var r=n(5),o="__core-js_shared__",i=r[o]||(r[o]={});t.exports=function(t){return i[t]||(i[t]={})}},function(t,e,n){var r=n(11),o=Math.max,i=Math.min;t.exports=function(t,e){return t=r(t),0>t?o(t+e,0):i(t,e)}},function(t,e,n){var r=n(11),o=Math.min;t.exports=function(t){return t>0?o(r(t),9007199254740991):0}},function(t,e,n){var r=n(6);t.exports=function(t,e){if(!r(t))return t;var n,o;if(e&&"function"==typeof(n=t.toString)&&!r(o=n.call(t)))return o;if("function"==typeof(n=t.valueOf)&&!r(o=n.call(t)))return o;if(!e&&"function"==typeof(n=t.toString)&&!r(o=n.call(t)))return o;throw TypeError("Can't convert object to primitive value")}},function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++n+r).toString(36))}},function(t,e,n){var r=n(4);r(r.S+r.F,"Object",{assign:n(35)})},function(t,e,n){var r=n(4);r(r.S+r.F*!n(1),"Object",{defineProperty:n(9).f})},function(t,e,n){var r=n(13),o=n(10);n(39)("keys",function(){return function(t){return o(r(t))}})},function(t,e){"function"==typeof Object.create?t.exports=function(t,e){t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}})}:t.exports=function(t,e){t.super_=e;var n=function(){};n.prototype=e.prototype,t.prototype=new n,t.prototype.constructor=t}},function(t,e,n){(function(t){function n(t,e){for(var n=0,r=t.length-1;r>=0;r--){var o=t[r];"."===o?t.splice(r,1):".."===o?(t.splice(r,1),n++):n&&(t.splice(r,1),n--)}if(e)for(;n--;n)t.unshift("..");return t}function r(t,e){if(t.filter)return t.filter(e);for(var n=[],r=0;r<t.length;r++)e(t[r],r,t)&&n.push(t[r]);return n}var o=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,i=function(t){return o.exec(t).slice(1)};e.resolve=function(){for(var e="",o=!1,i=arguments.length-1;i>=-1&&!o;i--){var u=i>=0?arguments[i]:t.cwd();if("string"!=typeof u)throw new TypeError("Arguments to path.resolve must be strings");u&&(e=u+"/"+e,o="/"===u.charAt(0))}return e=n(r(e.split("/"),function(t){return!!t}),!o).join("/"),(o?"/":"")+e||"."},e.normalize=function(t){var o=e.isAbsolute(t),i="/"===u(t,-1);return t=n(r(t.split("/"),function(t){return!!t}),!o).join("/"),t||o||(t="."),t&&i&&(t+="/"),(o?"/":"")+t},e.isAbsolute=function(t){return"/"===t.charAt(0)},e.join=function(){var t=Array.prototype.slice.call(arguments,0);return e.normalize(r(t,function(t,e){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},e.relative=function(t,n){function r(t){for(var e=0;e<t.length&&""===t[e];e++);for(var n=t.length-1;n>=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=e.resolve(t).substr(1),n=e.resolve(n).substr(1);for(var o=r(t.split("/")),i=r(n.split("/")),u=Math.min(o.length,i.length),c=u,s=0;u>s;s++)if(o[s]!==i[s]){c=s;break}for(var f=[],s=c;s<o.length;s++)f.push("..");return f=f.concat(i.slice(c)),f.join("/")},e.sep="/",e.delimiter=":",e.dirname=function(t){var e=i(t),n=e[0],r=e[1];return n||r?(r&&(r=r.substr(0,r.length-1)),n+r):"."},e.basename=function(t,e){var n=i(t)[2];return e&&n.substr(-1*e.length)===e&&(n=n.substr(0,n.length-e.length)),n},e.extname=function(t){return i(t)[3]};var u="b"==="ab".substr(-1)?function(t,e,n){return t.substr(e,n)}:function(t,e,n){return 0>e&&(e=t.length+e),t.substr(e,n)}}).call(e,n(3))},function(t,e){t.exports=function(t){return t&&"object"==typeof t&&"function"==typeof t.copy&&"function"==typeof t.fill&&"function"==typeof t.readUInt8}},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(r){"object"==typeof window&&(n=window)}t.exports=n}]);
var Logger=function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="",e(e.s=20)}([function(t,e){var n=t.exports={version:"2.4.0"};"number"==typeof __e&&(__e=n)},function(t,e,n){t.exports=!n(2)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(t,e){t.exports=function(t){try{return!!t()}catch(e){return!0}}},function(t,e,n){e.nextTick=function(t){setTimeout(t,0)},e.platform=e.arch=e.execPath=e.title="browser",e.pid=1,e.browser=!0,e.env={},e.argv=[],e.binding=function(t){throw new Error("No such module. (Possibly not yet loaded)")},function(){var t,r="/";e.cwd=function(){return r},e.chdir=function(e){t||(t=n(51)),r=t.resolve(e,r)}}(),e.exit=e.kill=e.umask=e.dlopen=e.uptime=e.memoryUsage=e.uvCounters=function(){},e.features={}},function(t,e,n){var r=n(5),o=n(0),i=n(29),u=n(33),c="prototype",s=function(t,e,n){var f,a,l,p=t&s.F,h=t&s.G,y=t&s.S,v=t&s.P,g=t&s.B,d=t&s.W,m=h?o:o[e]||(o[e]={}),b=m[c],w=h?r:y?r[e]:(r[e]||{})[c];h&&(n=e);for(f in n)a=!p&&w&&void 0!==w[f],a&&f in m||(l=a?w[f]:n[f],m[f]=h&&"function"!=typeof w[f]?n[f]:g&&a?i(l,r):d&&w[f]==l?function(t){var e=function(e,n,r){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,n)}return new t(e,n,r)}return t.apply(this,arguments)};return e[c]=t[c],e}(l):v&&"function"==typeof l?i(Function.call,l):l,v&&((m.virtual||(m.virtual={}))[f]=l,t&s.R&&b&&!b[f]&&u(b,f,l)))};s.F=1,s.G=2,s.S=4,s.P=8,s.B=16,s.W=32,s.U=64,s.R=128,t.exports=s},function(t,e){var n=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},function(t,e,n){var r=n(28);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==r(t)?t.split(""):Object(t)}},function(t,e,n){var r=n(26),o=n(34),i=n(45),u=Object.defineProperty;e.f=n(1)?Object.defineProperty:function(t,e,n){if(r(t),e=i(e,!0),r(n),o)try{return u(t,e,n)}catch(c){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(t[e]=n.value),t}},function(t,e,n){var r=n(37),o=n(31);t.exports=Object.keys||function(t){return r(t,o)}},function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},function(t,e,n){var r=n(8),o=n(7);t.exports=function(t){return r(o(t))}},function(t,e,n){var r=n(7);t.exports=function(t){return Object(r(t))}},function(t,e,n){t.exports={"default":n(22),__esModule:!0}},function(t,e,n){t.exports={"default":n(24),__esModule:!0}},function(t,e){"use strict";e.__esModule=!0,e["default"]=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{"default":t}}e.__esModule=!0;var o=n(21),i=r(o);e["default"]=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),(0,i["default"])(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}()},function(t,e,n){(function(t,r){function o(t,n){var r={seen:[],stylize:u};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),v(n)?r.showHidden=n:n&&e._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=i),s(r,t,r.depth)}function i(t,e){var n=o.styles[e];return n?"["+o.colors[n][0]+"m"+t+"["+o.colors[n][1]+"m":t}function u(t,e){return t}function c(t){var e={};return t.forEach(function(t,n){e[t]=!0}),e}function s(t,n,r){if(t.customInspect&&n&&E(n.inspect)&&n.inspect!==e.inspect&&(!n.constructor||n.constructor.prototype!==n)){var o=n.inspect(r,t);return b(o)||(o=s(t,o,r)),o}var i=f(t,n);if(i)return i;var u=Object.keys(n),v=c(u);if(t.showHidden&&(u=Object.getOwnPropertyNames(n)),S(n)&&(u.indexOf("message")>=0||u.indexOf("description")>=0))return a(n);if(0===u.length){if(E(n)){var g=n.name?": "+n.name:"";return t.stylize("[Function"+g+"]","special")}if(O(n))return t.stylize(RegExp.prototype.toString.call(n),"regexp");if(_(n))return t.stylize(Date.prototype.toString.call(n),"date");if(S(n))return a(n)}var d="",m=!1,w=["{","}"];if(y(n)&&(m=!0,w=["[","]"]),E(n)){var x=n.name?": "+n.name:"";d=" [Function"+x+"]"}if(O(n)&&(d=" "+RegExp.prototype.toString.call(n)),_(n)&&(d=" "+Date.prototype.toUTCString.call(n)),S(n)&&(d=" "+a(n)),0===u.length&&(!m||0==n.length))return w[0]+d+w[1];if(0>r)return O(n)?t.stylize(RegExp.prototype.toString.call(n),"regexp"):t.stylize("[Object]","special");t.seen.push(n);var j;return j=m?l(t,n,r,v,u):u.map(function(e){return p(t,n,r,v,e,m)}),t.seen.pop(),h(j,d,w)}function f(t,e){if(x(e))return t.stylize("undefined","undefined");if(b(e)){var n="'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return t.stylize(n,"string")}return m(e)?t.stylize(""+e,"number"):v(e)?t.stylize(""+e,"boolean"):g(e)?t.stylize("null","null"):void 0}function a(t){return"["+Error.prototype.toString.call(t)+"]"}function l(t,e,n,r,o){for(var i=[],u=0,c=e.length;c>u;++u)N(e,String(u))?i.push(p(t,e,n,r,String(u),!0)):i.push("");return o.forEach(function(o){o.match(/^\d+$/)||i.push(p(t,e,n,r,o,!0))}),i}function p(t,e,n,r,o,i){var u,c,f;if(f=Object.getOwnPropertyDescriptor(e,o)||{value:e[o]},f.get?c=f.set?t.stylize("[Getter/Setter]","special"):t.stylize("[Getter]","special"):f.set&&(c=t.stylize("[Setter]","special")),N(r,o)||(u="["+o+"]"),c||(t.seen.indexOf(f.value)<0?(c=g(n)?s(t,f.value,null):s(t,f.value,n-1),c.indexOf("\n")>-1&&(c=i?c.split("\n").map(function(t){return" "+t}).join("\n").substr(2):"\n"+c.split("\n").map(function(t){return" "+t}).join("\n"))):c=t.stylize("[Circular]","special")),x(u)){if(i&&o.match(/^\d+$/))return c;u=JSON.stringify(""+o),u.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(u=u.substr(1,u.length-2),u=t.stylize(u,"name")):(u=u.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),u=t.stylize(u,"string"))}return u+": "+c}function h(t,e,n){var r=0,o=t.reduce(function(t,e){return r++,e.indexOf("\n")>=0&&r++,t+e.replace(/\u001b\[\d\d?m/g,"").length+1},0);return o>60?n[0]+(""===e?"":e+"\n ")+" "+t.join(",\n ")+" "+n[1]:n[0]+e+" "+t.join(", ")+" "+n[1]}function y(t){return Array.isArray(t)}function v(t){return"boolean"==typeof t}function g(t){return null===t}function d(t){return null==t}function m(t){return"number"==typeof t}function b(t){return"string"==typeof t}function w(t){return"symbol"==typeof t}function x(t){return void 0===t}function O(t){return j(t)&&"[object RegExp]"===k(t)}function j(t){return"object"==typeof t&&null!==t}function _(t){return j(t)&&"[object Date]"===k(t)}function S(t){return j(t)&&("[object Error]"===k(t)||t instanceof Error)}function E(t){return"function"==typeof t}function R(t){return null===t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||"symbol"==typeof t||"undefined"==typeof t}function k(t){return Object.prototype.toString.call(t)}function M(t){return 10>t?"0"+t.toString(10):t.toString(10)}function L(){var t=new Date,e=[M(t.getHours()),M(t.getMinutes()),M(t.getSeconds())].join(":");return[t.getDate(),G[t.getMonth()],e].join(" ")}function N(t,e){return Object.prototype.hasOwnProperty.call(t,e)}var z=/%[sdj%]/g;e.format=function(t){if(!b(t)){for(var e=[],n=0;n<arguments.length;n++)e.push(o(arguments[n]));return e.join(" ")}for(var n=1,r=arguments,i=r.length,u=String(t).replace(z,function(t){if("%%"===t)return"%";if(n>=i)return t;switch(t){case"%s":return String(r[n++]);case"%d":return Number(r[n++]);case"%j":try{return JSON.stringify(r[n++])}catch(e){return"[Circular]"}default:return t}}),c=r[n];i>n;c=r[++n])u+=g(c)||!j(c)?" "+c:" "+o(c);return u},e.deprecate=function(n,o){function i(){if(!u){if(r.throwDeprecation)throw new Error(o);r.traceDeprecation?console.trace(o):console.error(o),u=!0}return n.apply(this,arguments)}if(x(t.process))return function(){return e.deprecate(n,o).apply(this,arguments)};if(r.noDeprecation===!0)return n;var u=!1;return i};var D,T={};e.debuglog=function(t){if(x(D)&&(D=r.env.NODE_DEBUG||""),t=t.toUpperCase(),!T[t])if(new RegExp("\\b"+t+"\\b","i").test(D)){var n=r.pid;T[t]=function(){var r=e.format.apply(e,arguments);console.error("%s %d: %s",t,n,r)}}else T[t]=function(){};return T[t]},e.inspect=o,o.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},o.styles={special:"cyan",number:"yellow","boolean":"yellow",undefined:"grey","null":"bold",string:"green",date:"magenta",regexp:"red"},e.isArray=y,e.isBoolean=v,e.isNull=g,e.isNullOrUndefined=d,e.isNumber=m,e.isString=b,e.isSymbol=w,e.isUndefined=x,e.isRegExp=O,e.isObject=j,e.isDate=_,e.isError=S,e.isFunction=E,e.isPrimitive=R,e.isBuffer=n(52);var G=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];e.log=function(){console.log("%s - %s",L(),e.format.apply(e,arguments))},e.inherits=n(50),e._extend=function(t,e){if(!e||!j(e))return t;for(var n=Object.keys(e),r=n.length;r--;)t[n[r]]=e[n[r]];return t}}).call(e,n(53),n(3))},function(t,e){t.exports={}},function(t,e,n){"use strict";(function(e){function r(t){return t&&t.__esModule?t:{"default":t}}var o=n(15),i=r(o),u=n(14),c=r(u),s=n(16),f=r(s),a=n(17),l=r(a),p=n(19),h=n(18).format,y=!!e.version,v={DEBUG:"DEBUG",INFO:"INFO",WARN:"WARN",ERROR:"ERROR",NONE:"NONE"},g=v.DEBUG,d=null,m={Black:0,Red:1,Green:2,Yellow:3,Blue:4,Magenta:5,Cyan:6,Grey:7,White:9,Default:9};y||(m={Black:"Black",Red:"IndianRed",Green:"LimeGreen",Yellow:"Orange",Blue:"RoyalBlue",Magenta:"Orchid",Cyan:"SkyBlue",Grey:"DimGrey",White:"White",Default:"Black"});var b=[m.Cyan,m.Green,m.Yellow,m.Red,m.Default],w={useColors:!0,color:m.Default,showTimestamp:!0,showLevel:!0,filename:d,appendFile:!0},x=function(){function t(e,n){(0,f["default"])(this,t),this.category=e;var r={};(0,c["default"])(r,w),(0,c["default"])(r,n),this.options=r}return(0,l["default"])(t,[{key:"debug",value:function(){this._write(v.DEBUG,h.apply(null,arguments))}},{key:"log",value:function(){this.debug.apply(this,arguments)}},{key:"info",value:function(){this._write(v.INFO,h.apply(null,arguments))}},{key:"warn",value:function(){this._write(v.WARN,h.apply(null,arguments))}},{key:"error",value:function(){this._write(v.ERROR,h.apply(null,arguments))}},{key:"_write",value:function(t,e){if(this._shouldLog(t)){!this.options.filename&&!d||this.fileWriter||(this.fileWriter=p.openSync(this.options.filename||d,this.options.appendFile?"a+":"w+"));var n=this._format(t,e),r=this._createLogMessage(t,e),o=this._createLogMessage(t,e,n.timestamp,n.level,n.category,n.text);this.fileWriter&&p.writeSync(this.fileWriter,r+"\n",null,"utf-8"),y?console.log(o):t===v.ERROR?this.options.showTimestamp&&this.options.showLevel?console.error(o,n.timestamp,n.level,n.category,n.text):this.options.showTimestamp&&!this.options.showLevel?console.error(o,n.timestamp,n.category,n.text):!this.options.showTimestamp&&this.options.showLevel?console.error(o,n.level,n.category,n.text):console.error(o,n.category,n.text):this.options.showTimestamp&&this.options.showLevel?console.log(o,n.timestamp,n.level,n.category,n.text):this.options.showTimestamp&&!this.options.showLevel?console.log(o,n.timestamp,n.category,n.text):!this.options.showTimestamp&&this.options.showLevel?console.log(o,n.level,n.category,n.text):console.log(o,n.category,n.text)}}},{key:"_format",value:function(t,e){var n="",r="",o="",u=": ";if(this.options.useColors){var c=(0,i["default"])(v).map(function(t){return v[t]}).indexOf(t),s=this.options.color;y?(this.options.showTimestamp&&(n="[3"+m.Grey+"m"),this.options.showLevel&&(r="[3"+b[c]+";22m"),o="[3"+s+";1m",u=": "):(this.options.showTimestamp&&(n="color:"+m.Grey),this.options.showLevel&&(r="color:"+b[c]),o="color:"+s+"; font-weight: bold")}return{timestamp:n,level:r,category:o,text:u}}},{key:"_createLogMessage",value:function(t,e,n,r,o,i){n=n||"",r=r||"",o=o||"",i=i||": ",y||(this.options.showTimestamp&&(n="%c"),this.options.showLevel&&(r="%c"),o="%c",i=": %c");var u="";return this.options.showTimestamp&&(u+=""+(new Date).toISOString()+" "),u=n+u,this.options.showLevel&&(u+=r+"["+t+"]"+(t===v.INFO||t===v.WARN?" ":"")+" "),u+=o+this.category,u+=i+e}},{key:"_shouldLog",value:function(t){var n=void 0!==e&&void 0!==e.env&&void 0!==e.env.LOG?e.env.LOG.toUpperCase():g,r=(0,i["default"])(v).map(function(t){return v[t]}),o=r.indexOf(t),u=r.indexOf(n);return o>=u}}]),t}();t.exports={Colors:m,LogLevels:v,setLogLevel:function(t){g=t},setLogfile:function(t){d=t},create:function(t,e){var n=new x(t,e);return n},forceBrowserMode:function(t){return y=!t}}}).call(e,n(3))},function(t,e,n){t.exports={"default":n(23),__esModule:!0}},function(t,e,n){n(47),t.exports=n(0).Object.assign},function(t,e,n){n(48);var r=n(0).Object;t.exports=function(t,e,n){return r.defineProperty(t,e,n)}},function(t,e,n){n(49),t.exports=n(0).Object.keys},function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,e,n){var r=n(6);t.exports=function(t){if(!r(t))throw TypeError(t+" is not an object!");return t}},function(t,e,n){var r=n(12),o=n(44),i=n(43);t.exports=function(t){return function(e,n,u){var c,s=r(e),f=o(s.length),a=i(u,f);if(t&&n!=n){for(;f>a;)if(c=s[a++],c!=c)return!0}else for(;f>a;a++)if((t||a in s)&&s[a]===n)return t||a||0;return!t&&-1}}},function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},function(t,e,n){var r=n(25);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,o){return t.call(e,n,r,o)}}return function(){return t.apply(e,arguments)}}},function(t,e,n){var r=n(6),o=n(5).document,i=r(o)&&r(o.createElement);t.exports=function(t){return i?o.createElement(t):{}}},function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},function(t,e,n){var r=n(9),o=n(40);t.exports=n(1)?function(t,e,n){return r.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},function(t,e,n){t.exports=!n(1)&&!n(2)(function(){return 7!=Object.defineProperty(n(30)("div"),"a",{get:function(){return 7}}).a})},function(t,e,n){"use strict";var r=n(10),o=n(36),i=n(38),u=n(13),c=n(8),s=Object.assign;t.exports=!s||n(2)(function(){var t={},e={},n=Symbol(),r="abcdefghijklmnopqrst";return t[n]=7,r.split("").forEach(function(t){e[t]=t}),7!=s({},t)[n]||Object.keys(s({},e)).join("")!=r})?function(t,e){for(var n=u(t),s=arguments.length,f=1,a=o.f,l=i.f;s>f;)for(var p,h=c(arguments[f++]),y=a?r(h).concat(a(h)):r(h),v=y.length,g=0;v>g;)l.call(h,p=y[g++])&&(n[p]=h[p]);return n}:s},function(t,e){e.f=Object.getOwnPropertySymbols},function(t,e,n){var r=n(32),o=n(12),i=n(27)(!1),u=n(41)("IE_PROTO");t.exports=function(t,e){var n,c=o(t),s=0,f=[];for(n in c)n!=u&&r(c,n)&&f.push(n);for(;e.length>s;)r(c,n=e[s++])&&(~i(f,n)||f.push(n));return f}},function(t,e){e.f={}.propertyIsEnumerable},function(t,e,n){var r=n(4),o=n(0),i=n(2);t.exports=function(t,e){var n=(o.Object||{})[t]||Object[t],u={};u[t]=e(n),r(r.S+r.F*i(function(){n(1)}),"Object",u)}},function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},function(t,e,n){var r=n(42)("keys"),o=n(46);t.exports=function(t){return r[t]||(r[t]=o(t))}},function(t,e,n){var r=n(5),o="__core-js_shared__",i=r[o]||(r[o]={});t.exports=function(t){return i[t]||(i[t]={})}},function(t,e,n){var r=n(11),o=Math.max,i=Math.min;t.exports=function(t,e){return t=r(t),0>t?o(t+e,0):i(t,e)}},function(t,e,n){var r=n(11),o=Math.min;t.exports=function(t){return t>0?o(r(t),9007199254740991):0}},function(t,e,n){var r=n(6);t.exports=function(t,e){if(!r(t))return t;var n,o;if(e&&"function"==typeof(n=t.toString)&&!r(o=n.call(t)))return o;if("function"==typeof(n=t.valueOf)&&!r(o=n.call(t)))return o;if(!e&&"function"==typeof(n=t.toString)&&!r(o=n.call(t)))return o;throw TypeError("Can't convert object to primitive value")}},function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++n+r).toString(36))}},function(t,e,n){var r=n(4);r(r.S+r.F,"Object",{assign:n(35)})},function(t,e,n){var r=n(4);r(r.S+r.F*!n(1),"Object",{defineProperty:n(9).f})},function(t,e,n){var r=n(13),o=n(10);n(39)("keys",function(){return function(t){return o(r(t))}})},function(t,e){"function"==typeof Object.create?t.exports=function(t,e){t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}})}:t.exports=function(t,e){t.super_=e;var n=function(){};n.prototype=e.prototype,t.prototype=new n,t.prototype.constructor=t}},function(t,e,n){(function(t){function n(t,e){for(var n=0,r=t.length-1;r>=0;r--){var o=t[r];"."===o?t.splice(r,1):".."===o?(t.splice(r,1),n++):n&&(t.splice(r,1),n--)}if(e)for(;n--;n)t.unshift("..");return t}function r(t,e){if(t.filter)return t.filter(e);for(var n=[],r=0;r<t.length;r++)e(t[r],r,t)&&n.push(t[r]);return n}var o=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,i=function(t){return o.exec(t).slice(1)};e.resolve=function(){for(var e="",o=!1,i=arguments.length-1;i>=-1&&!o;i--){var u=i>=0?arguments[i]:t.cwd();if("string"!=typeof u)throw new TypeError("Arguments to path.resolve must be strings");u&&(e=u+"/"+e,o="/"===u.charAt(0))}return e=n(r(e.split("/"),function(t){return!!t}),!o).join("/"),(o?"/":"")+e||"."},e.normalize=function(t){var o=e.isAbsolute(t),i="/"===u(t,-1);return t=n(r(t.split("/"),function(t){return!!t}),!o).join("/"),t||o||(t="."),t&&i&&(t+="/"),(o?"/":"")+t},e.isAbsolute=function(t){return"/"===t.charAt(0)},e.join=function(){var t=Array.prototype.slice.call(arguments,0);return e.normalize(r(t,function(t,e){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},e.relative=function(t,n){function r(t){for(var e=0;e<t.length&&""===t[e];e++);for(var n=t.length-1;n>=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=e.resolve(t).substr(1),n=e.resolve(n).substr(1);for(var o=r(t.split("/")),i=r(n.split("/")),u=Math.min(o.length,i.length),c=u,s=0;u>s;s++)if(o[s]!==i[s]){c=s;break}for(var f=[],s=c;s<o.length;s++)f.push("..");return f=f.concat(i.slice(c)),f.join("/")},e.sep="/",e.delimiter=":",e.dirname=function(t){var e=i(t),n=e[0],r=e[1];return n||r?(r&&(r=r.substr(0,r.length-1)),n+r):"."},e.basename=function(t,e){var n=i(t)[2];return e&&n.substr(-1*e.length)===e&&(n=n.substr(0,n.length-e.length)),n},e.extname=function(t){return i(t)[3]};var u="b"==="ab".substr(-1)?function(t,e,n){return t.substr(e,n)}:function(t,e,n){return 0>e&&(e=t.length+e),t.substr(e,n)}}).call(e,n(3))},function(t,e){t.exports=function(t){return t&&"object"==typeof t&&"function"==typeof t.copy&&"function"==typeof t.fill&&"function"==typeof t.readUInt8}},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(r){"object"==typeof window&&(n=window)}t.exports=n}]);

@@ -505,2 +505,3 @@ /******/ (function(modules) { // webpackBootstrap

value: function _shouldLog(level) {
var logLevel = process !== undefined && process.env !== undefined && process.env.LOG !== undefined ? process.env.LOG.toUpperCase() : GlobalLogLevel;
var levels = (0, _keys2.default)(LogLevels).map(function (f) {

@@ -510,3 +511,3 @@ return LogLevels[f];

var index = levels.indexOf(level);
var levelIdx = levels.indexOf(GlobalLogLevel);
var levelIdx = levels.indexOf(logLevel);
return index >= levelIdx;

@@ -513,0 +514,0 @@ }

{
"name": "logplease",
"version": "1.2.7",
"version": "1.2.8",
"description": "Simple Javascript logger for Node.js and Browsers",

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

@@ -47,2 +47,4 @@ # logplease

Default log level is `DEBUG`. You can set the log level with `LOG` environment variable, eg. `LOG=debug node example/example.js`. See [Log levels](#log-levels) for available options.
### Browser

@@ -85,2 +87,13 @@ Copy `dist/logplease.min.js` to your javascripts directory and include it in your html. See [example/index.html](https://github.com/haadcode/logplease/blob/master/example/index.html) for details.

### Log levels
```
DEBUG
INFO
WARN
ERROR
NONE
```
Default log level is `DEBUG`. To display errors only, use `ERROR`. To turn off all logging, use `NONE`.
### Global log level

@@ -96,11 +109,2 @@ You can set a global log level to display only the wanted log messages.

Log levels:
```
DEBUG
INFO
WARN
ERROR
NONE
```
You can mute all loggers with log level *NONE*:

@@ -107,0 +111,0 @@ ```javascript

@@ -205,5 +205,6 @@ 'use strict';

_shouldLog(level) {
const logLevel = process !== undefined && process.env !== undefined && process.env.LOG !== undefined ? process.env.LOG.toUpperCase() : GlobalLogLevel;
const levels = Object.keys(LogLevels).map((f) => LogLevels[f]);
const index = levels.indexOf(level);
const levelIdx = levels.indexOf(GlobalLogLevel);
const levelIdx = levels.indexOf(logLevel);
return index >= levelIdx;

@@ -210,0 +211,0 @@ }

@@ -319,2 +319,20 @@ 'use strict';

});
describe('LOG environment variable', () => {
it('logs according to LOG environment variable', (done) => {
let out = '';
let old = console.log;
console.log = (d) => out += d;
const log = Logger.create('test1', { showTimestamp: false, useColors: false });
Logger.setLogLevel(Logger.LogLevels.NONE);
process.env.LOG = 'debug'
log.warn("hi");
console.log = old;
assert.equal(out, '[WARN] test1: hi');
const logfile = 'test123.log';
fs.unlinkSync(logfile);
done();
});
});
});
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc