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.14 to 1.2.15

.circleci/config.yml

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.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=14)}([function(t,e){var n=t.exports={version:"2.5.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(t){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(15)),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){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,n){var r=n(4),o=n(0),i=n(30),s=n(32),u=function(t,e,n){var c,l,a,f=t&u.F,p=t&u.G,h=t&u.S,v=t&u.P,y=t&u.B,g=t&u.W,d=p?o:o[e]||(o[e]={}),m=d.prototype,b=p?r:h?r[e]:(r[e]||{}).prototype;p&&(n=e);for(c in n)(l=!f&&b&&void 0!==b[c])&&c in d||(a=l?b[c]:n[c],d[c]=p&&"function"!=typeof b[c]?n[c]:y&&l?i(a,r):g&&b[c]==a?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.prototype=t.prototype,e}(a):v&&"function"==typeof a?i(Function.call,a):a,v&&((d.virtual||(d.virtual={}))[c]=a,t&u.R&&m&&!m[c]&&s(m,c,a)))};u.F=1,u.G=2,u.S=4,u.P=8,u.B=16,u.W=32,u.U=64,u.R=128,t.exports=u},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e,n){var r=n(8);t.exports=function(t){return Object(r(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(19),o=n(28);t.exports=Object.keys||function(t){return r(t,o)}},function(t,e,n){var r=n(11),o=n(8);t.exports=function(t){return r(o(t))}},function(t,e,n){var r=n(21);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==r(t)?t.split(""):Object(t)}},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(33),o=n(34),i=n(36),s=Object.defineProperty;e.f=n(1)?Object.defineProperty:function(t,e,n){if(r(t),e=i(e,!0),r(n),o)try{return s(t,e,n)}catch(t){}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){"use strict";(function(e){function r(t){return t&&t.__esModule?t:{default:t}}var o=n(16),i=r(o),s=n(38),u=r(s),c=n(44),l=r(c),a=n(45),f=r(a),p=n(49),h=n(50).format,v=n(54).EventEmitter,y=!!e.version,g={DEBUG:"DEBUG",INFO:"INFO",WARN:"WARN",ERROR:"ERROR",NONE:"NONE"},d=g.DEBUG,m=null,b=new v,w={Black:0,Red:1,Green:2,Yellow:3,Blue:4,Magenta:5,Cyan:6,Grey:7,White:9,Default:9};y||(w={Black:"Black",Red:"IndianRed",Green:"LimeGreen",Yellow:"Orange",Blue:"RoyalBlue",Magenta:"Orchid",Cyan:"SkyBlue",Grey:"DimGrey",White:"White",Default:"Black"});var _=[w.Cyan,w.Green,w.Yellow,w.Red,w.Default],x={useColors:!0,color:w.Default,showTimestamp:!0,showLevel:!0,filename:m,appendFile:!0},O=function(){function t(e,n){(0,l.default)(this,t),this.category=e;var r={};(0,u.default)(r,x),(0,u.default)(r,n),this.options=r}return(0,f.default)(t,[{key:"debug",value:function(){this._shouldLog(g.DEBUG)&&this._write(g.DEBUG,h.apply(null,arguments))}},{key:"log",value:function(){this._shouldLog(g.DEBUG)&&this.debug.apply(this,arguments)}},{key:"info",value:function(){this._shouldLog(g.INFO)&&this._write(g.INFO,h.apply(null,arguments))}},{key:"warn",value:function(){this._shouldLog(g.WARN)&&this._write(g.WARN,h.apply(null,arguments))}},{key:"error",value:function(){this._shouldLog(g.ERROR)&&this._write(g.ERROR,h.apply(null,arguments))}},{key:"_write",value:function(t,e){(this.options.filename||m)&&!this.fileWriter&&y&&(this.fileWriter=p.openSync(this.options.filename||m,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&&y&&p.writeSync(this.fileWriter,r+"\n",null,"utf-8"),y||!this.options.useColors?(console.log(o),b.emit("data",this.category,t,e)):t===g.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="",s=": ";if(this.options.useColors){var u=(0,i.default)(g).map(function(t){return g[t]}).indexOf(t),c=this.options.color;y?(this.options.showTimestamp&&(n="[3"+w.Grey+"m"),this.options.showLevel&&(r="[3"+_[u]+";22m"),o="[3"+c+";1m",s=": "):(this.options.showTimestamp&&(n="color:"+w.Grey),this.options.showLevel&&(r="color:"+_[u]),o="color:"+c+"; font-weight: bold")}return{timestamp:n,level:r,category:o,text:s}}},{key:"_createLogMessage",value:function(t,e,n,r,o,i){n=n||"",r=r||"",o=o||"",i=i||": ",!y&&this.options.useColors&&(this.options.showTimestamp&&(n="%c"),this.options.showLevel&&(r="%c"),o="%c",i=": %c");var s="";return this.options.showTimestamp&&(s+=(new Date).toISOString()+" "),s=n+s,this.options.showLevel&&(s+=r+"["+t+"]"+(t===g.INFO||t===g.WARN?" ":"")+" "),s+=o+this.category,s+=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():null;n="undefined"!=typeof window&&window.LOG?window.LOG.toUpperCase():n;var r=n||d,o=(0,i.default)(g).map(function(t){return g[t]});return o.indexOf(t)>=o.indexOf(r)}}]),t}();t.exports={Colors:w,LogLevels:g,setLogLevel:function(t){d=t},setLogfile:function(t){m=t},create:function(t,e){return new O(t,e)},forceBrowserMode:function(t){return y=!t},events:b}}).call(e,n(3))},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 s=i>=0?arguments[i]:t.cwd();if("string"!=typeof s)throw new TypeError("Arguments to path.resolve must be strings");s&&(e=s+"/"+e,o="/"===s.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="/"===s(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("/")),s=Math.min(o.length,i.length),u=s,c=0;c<s;c++)if(o[c]!==i[c]){u=c;break}for(var l=[],c=u;c<o.length;c++)l.push("..");return l=l.concat(i.slice(u)),l.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 s="b"==="ab".substr(-1)?function(t,e,n){return t.substr(e,n)}:function(t,e,n){return e<0&&(e=t.length+e),t.substr(e,n)}}).call(e,n(3))},function(t,e,n){t.exports={default:n(17),__esModule:!0}},function(t,e,n){n(18),t.exports=n(0).Object.keys},function(t,e,n){var r=n(7),o=n(9);n(29)("keys",function(){return function(t){return o(r(t))}})},function(t,e,n){var r=n(20),o=n(10),i=n(22)(!1),s=n(25)("IE_PROTO");t.exports=function(t,e){var n,u=o(t),c=0,l=[];for(n in u)n!=s&&r(u,n)&&l.push(n);for(;e.length>c;)r(u,n=e[c++])&&(~i(l,n)||l.push(n));return l}},function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},function(t,e,n){var r=n(10),o=n(23),i=n(24);t.exports=function(t){return function(e,n,s){var u,c=r(e),l=o(c.length),a=i(s,l);if(t&&n!=n){for(;l>a;)if((u=c[a++])!=u)return!0}else for(;l>a;a++)if((t||a in c)&&c[a]===n)return t||a||0;return!t&&-1}}},function(t,e,n){var r=n(12),o=Math.min;t.exports=function(t){return t>0?o(r(t),9007199254740991):0}},function(t,e,n){var r=n(12),o=Math.max,i=Math.min;t.exports=function(t,e){return t=r(t),t<0?o(t+e,0):i(t,e)}},function(t,e,n){var r=n(26)("keys"),o=n(27);t.exports=function(t){return r[t]||(r[t]=o(t))}},function(t,e,n){var r=n(4),o=r["__core-js_shared__"]||(r["__core-js_shared__"]={});t.exports=function(t){return o[t]||(o[t]={})}},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){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,e,n){var r=n(5),o=n(0),i=n(2);t.exports=function(t,e){var n=(o.Object||{})[t]||Object[t],s={};s[t]=e(n),r(r.S+r.F*i(function(){n(1)}),"Object",s)}},function(t,e,n){var r=n(31);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){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,e,n){var r=n(13),o=n(37);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){var r=n(6);t.exports=function(t){if(!r(t))throw TypeError(t+" is not an object!");return t}},function(t,e,n){t.exports=!n(1)&&!n(2)(function(){return 7!=Object.defineProperty(n(35)("div"),"a",{get:function(){return 7}}).a})},function(t,e,n){var r=n(6),o=n(4).document,i=r(o)&&r(o.createElement);t.exports=function(t){return i?o.createElement(t):{}}},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){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},function(t,e,n){t.exports={default:n(39),__esModule:!0}},function(t,e,n){n(40),t.exports=n(0).Object.assign},function(t,e,n){var r=n(5);r(r.S+r.F,"Object",{assign:n(41)})},function(t,e,n){"use strict";var r=n(9),o=n(42),i=n(43),s=n(7),u=n(11),c=Object.assign;t.exports=!c||n(2)(function(){var t={},e={},n=Symbol(),r="abcdefghijklmnopqrst";return t[n]=7,r.split("").forEach(function(t){e[t]=t}),7!=c({},t)[n]||Object.keys(c({},e)).join("")!=r})?function(t,e){for(var n=s(t),c=arguments.length,l=1,a=o.f,f=i.f;c>l;)for(var p,h=u(arguments[l++]),v=a?r(h).concat(a(h)):r(h),y=v.length,g=0;y>g;)f.call(h,p=v[g++])&&(n[p]=h[p]);return n}:c},function(t,e){e.f=Object.getOwnPropertySymbols},function(t,e){e.f={}.propertyIsEnumerable},function(t,e,n){"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";e.__esModule=!0;var r=n(46),o=function(t){return t&&t.__esModule?t:{default:t}}(r);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,o.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){t.exports={default:n(47),__esModule:!0}},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){var r=n(5);r(r.S+r.F*!n(1),"Object",{defineProperty:n(13).f})},function(t,e){},function(t,e,n){(function(t,r){function o(t,n){var r={seen:[],stylize:s};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),y(n)?r.showHidden=n:n&&e._extend(r,n),_(r.showHidden)&&(r.showHidden=!1),_(r.depth)&&(r.depth=2),_(r.colors)&&(r.colors=!1),_(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=i),c(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 s(t,e){return t}function u(t){var e={};return t.forEach(function(t,n){e[t]=!0}),e}function c(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=c(t,o,r)),o}var i=l(t,n);if(i)return i;var s=Object.keys(n),y=u(s);if(t.showHidden&&(s=Object.getOwnPropertyNames(n)),L(n)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return a(n);if(0===s.length){if(E(n)){var g=n.name?": "+n.name:"";return t.stylize("[Function"+g+"]","special")}if(x(n))return t.stylize(RegExp.prototype.toString.call(n),"regexp");if(j(n))return t.stylize(Date.prototype.toString.call(n),"date");if(L(n))return a(n)}var d="",m=!1,w=["{","}"];if(v(n)&&(m=!0,w=["[","]"]),E(n)){d=" [Function"+(n.name?": "+n.name:"")+"]"}if(x(n)&&(d=" "+RegExp.prototype.toString.call(n)),j(n)&&(d=" "+Date.prototype.toUTCString.call(n)),L(n)&&(d=" "+a(n)),0===s.length&&(!m||0==n.length))return w[0]+d+w[1];if(r<0)return x(n)?t.stylize(RegExp.prototype.toString.call(n),"regexp"):t.stylize("[Object]","special");t.seen.push(n);var _;return _=m?f(t,n,r,y,s):s.map(function(e){return p(t,n,r,y,e,m)}),t.seen.pop(),h(_,d,w)}function l(t,e){if(_(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"):y(e)?t.stylize(""+e,"boolean"):g(e)?t.stylize("null","null"):void 0}function a(t){return"["+Error.prototype.toString.call(t)+"]"}function f(t,e,n,r,o){for(var i=[],s=0,u=e.length;s<u;++s)N(e,String(s))?i.push(p(t,e,n,r,String(s),!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 s,u,l;if(l=Object.getOwnPropertyDescriptor(e,o)||{value:e[o]},l.get?u=l.set?t.stylize("[Getter/Setter]","special"):t.stylize("[Getter]","special"):l.set&&(u=t.stylize("[Setter]","special")),N(r,o)||(s="["+o+"]"),u||(t.seen.indexOf(l.value)<0?(u=g(n)?c(t,l.value,null):c(t,l.value,n-1),u.indexOf("\n")>-1&&(u=i?u.split("\n").map(function(t){return" "+t}).join("\n").substr(2):"\n"+u.split("\n").map(function(t){return" "+t}).join("\n"))):u=t.stylize("[Circular]","special")),_(s)){if(i&&o.match(/^\d+$/))return u;s=JSON.stringify(""+o),s.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.substr(1,s.length-2),s=t.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=t.stylize(s,"string"))}return s+": "+u}function h(t,e,n){var r=0;return t.reduce(function(t,e){return r++,e.indexOf("\n")>=0&&r++,t+e.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?n[0]+(""===e?"":e+"\n ")+" "+t.join(",\n ")+" "+n[1]:n[0]+e+" "+t.join(", ")+" "+n[1]}function v(t){return Array.isArray(t)}function y(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 _(t){return void 0===t}function x(t){return O(t)&&"[object RegExp]"===R(t)}function O(t){return"object"==typeof t&&null!==t}function j(t){return O(t)&&"[object Date]"===R(t)}function L(t){return O(t)&&("[object Error]"===R(t)||t instanceof Error)}function E(t){return"function"==typeof t}function S(t){return null===t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||"symbol"==typeof t||void 0===t}function R(t){return Object.prototype.toString.call(t)}function k(t){return t<10?"0"+t.toString(10):t.toString(10)}function M(){var t=new Date,e=[k(t.getHours()),k(t.getMinutes()),k(t.getSeconds())].join(":");return[t.getDate(),G[t.getMonth()],e].join(" ")}function N(t,e){return Object.prototype.hasOwnProperty.call(t,e)}var T=/%[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,s=String(t).replace(T,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(t){return"[Circular]"}default:return t}}),u=r[n];n<i;u=r[++n])g(u)||!O(u)?s+=" "+u:s+=" "+o(u);return s},e.deprecate=function(n,o){function i(){if(!s){if(r.throwDeprecation)throw new Error(o);r.traceDeprecation?console.trace(o):console.error(o),s=!0}return n.apply(this,arguments)}if(_(t.process))return function(){return e.deprecate(n,o).apply(this,arguments)};if(!0===r.noDeprecation)return n;var s=!1;return i};var A,D={};e.debuglog=function(t){if(_(A)&&(A=r.env.NODE_DEBUG||""),t=t.toUpperCase(),!D[t])if(new RegExp("\\b"+t+"\\b","i").test(A)){var n=r.pid;D[t]=function(){var r=e.format.apply(e,arguments);console.error("%s %d: %s",t,n,r)}}else D[t]=function(){};return D[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=v,e.isBoolean=y,e.isNull=g,e.isNullOrUndefined=d,e.isNumber=m,e.isString=b,e.isSymbol=w,e.isUndefined=_,e.isRegExp=x,e.isObject=O,e.isDate=j,e.isError=L,e.isFunction=E,e.isPrimitive=S,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",M(),e.format.apply(e,arguments))},e.inherits=n(53),e._extend=function(t,e){if(!e||!O(e))return t;for(var n=Object.keys(e),r=n.length;r--;)t[n[r]]=e[n[r]];return t}}).call(e,n(51),n(3))},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(n=window)}t.exports=n},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){"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){function n(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}function r(t){return"function"==typeof t}function o(t){return"number"==typeof t}function i(t){return"object"==typeof t&&null!==t}function s(t){return void 0===t}t.exports=n,n.EventEmitter=n,n.prototype._events=void 0,n.prototype._maxListeners=void 0,n.defaultMaxListeners=10,n.prototype.setMaxListeners=function(t){if(!o(t)||t<0||isNaN(t))throw TypeError("n must be a positive number");return this._maxListeners=t,this},n.prototype.emit=function(t){var e,n,o,u,c,l;if(this._events||(this._events={}),"error"===t&&(!this._events.error||i(this._events.error)&&!this._events.error.length)){if((e=arguments[1])instanceof Error)throw e;var a=new Error('Uncaught, unspecified "error" event. ('+e+")");throw a.context=e,a}if(n=this._events[t],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:u=Array.prototype.slice.call(arguments,1),n.apply(this,u)}else if(i(n))for(u=Array.prototype.slice.call(arguments,1),l=n.slice(),o=l.length,c=0;c<o;c++)l[c].apply(this,u);return!0},n.prototype.addListener=function(t,e){var o;if(!r(e))throw TypeError("listener must be a function");return this._events||(this._events={}),this._events.newListener&&this.emit("newListener",t,r(e.listener)?e.listener:e),this._events[t]?i(this._events[t])?this._events[t].push(e):this._events[t]=[this._events[t],e]:this._events[t]=e,i(this._events[t])&&!this._events[t].warned&&(o=s(this._maxListeners)?n.defaultMaxListeners:this._maxListeners)&&o>0&&this._events[t].length>o&&(this._events[t].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[t].length),"function"==typeof console.trace&&console.trace()),this},n.prototype.on=n.prototype.addListener,n.prototype.once=function(t,e){function n(){this.removeListener(t,n),o||(o=!0,e.apply(this,arguments))}if(!r(e))throw TypeError("listener must be a function");var o=!1;return n.listener=e,this.on(t,n),this},n.prototype.removeListener=function(t,e){var n,o,s,u;if(!r(e))throw TypeError("listener must be a function");if(!this._events||!this._events[t])return this;if(n=this._events[t],s=n.length,o=-1,n===e||r(n.listener)&&n.listener===e)delete this._events[t],this._events.removeListener&&this.emit("removeListener",t,e);else if(i(n)){for(u=s;u-- >0;)if(n[u]===e||n[u].listener&&n[u].listener===e){o=u;break}if(o<0)return this;1===n.length?(n.length=0,delete this._events[t]):n.splice(o,1),this._events.removeListener&&this.emit("removeListener",t,e)}return this},n.prototype.removeAllListeners=function(t){var e,n;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[t]&&delete this._events[t],this;if(0===arguments.length){for(e in this._events)"removeListener"!==e&&this.removeAllListeners(e);return this.removeAllListeners("removeListener"),this._events={},this}if(n=this._events[t],r(n))this.removeListener(t,n);else if(n)for(;n.length;)this.removeListener(t,n[n.length-1]);return delete this._events[t],this},n.prototype.listeners=function(t){return this._events&&this._events[t]?r(this._events[t])?[this._events[t]]:this._events[t].slice():[]},n.prototype.listenerCount=function(t){if(this._events){var e=this._events[t];if(r(e))return 1;if(e)return e.length}return 0},n.listenerCount=function(t,e){return t.listenerCount(e)}}]);
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.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=15)}([function(t,e){var n=t.exports={version:"2.5.7"};"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(t){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(16)),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){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,n){var r=n(4),o=n(0),i=n(31),s=n(33),u=n(10),c=function(t,e,n){var l,a,f,p=t&c.F,h=t&c.G,v=t&c.S,y=t&c.P,g=t&c.B,d=t&c.W,m=h?o:o[e]||(o[e]={}),b=m.prototype,w=h?r:v?r[e]:(r[e]||{}).prototype;h&&(n=e);for(l in n)(a=!p&&w&&void 0!==w[l])&&u(m,l)||(f=a?w[l]:n[l],m[l]=h&&"function"!=typeof w[l]?n[l]:g&&a?i(f,r):d&&w[l]==f?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.prototype=t.prototype,e}(f):y&&"function"==typeof f?i(Function.call,f):f,y&&((m.virtual||(m.virtual={}))[l]=f,t&c.R&&b&&!b[l]&&s(b,l,f)))};c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,t.exports=c},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e,n){var r=n(8);t.exports=function(t){return Object(r(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(20),o=n(29);t.exports=Object.keys||function(t){return r(t,o)}},function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},function(t,e,n){var r=n(12),o=n(8);t.exports=function(t){return r(o(t))}},function(t,e,n){var r=n(21);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==r(t)?t.split(""):Object(t)}},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(34),o=n(35),i=n(37),s=Object.defineProperty;e.f=n(1)?Object.defineProperty:function(t,e,n){if(r(t),e=i(e,!0),r(n),o)try{return s(t,e,n)}catch(t){}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){"use strict";(function(e){function r(t){return t&&t.__esModule?t:{default:t}}var o=n(17),i=r(o),s=n(39),u=r(s),c=n(45),l=r(c),a=n(46),f=r(a),p=n(50),h=n(51).format,v=n(55).EventEmitter,y=e.type&&"renderer"===e.type,g=!(y||!e.version),d={DEBUG:"DEBUG",INFO:"INFO",WARN:"WARN",ERROR:"ERROR",NONE:"NONE"},m=d.DEBUG,b=null,w=new v,_={Black:0,Red:1,Green:2,Yellow:3,Blue:4,Magenta:5,Cyan:6,Grey:7,White:9,Default:9};g||(_={Black:"Black",Red:"IndianRed",Green:"LimeGreen",Yellow:"Orange",Blue:"RoyalBlue",Magenta:"Orchid",Cyan:"SkyBlue",Grey:"DimGrey",White:"White",Default:"Black"});var x=[_.Cyan,_.Green,_.Yellow,_.Red,_.Default],O={useColors:!0,color:_.Default,showTimestamp:!0,useLocalTime:!1,showLevel:!0,filename:b,appendFile:!0},L=function(){function t(e,n){(0,l.default)(this,t),this.category=e;var r={};(0,u.default)(r,O),(0,u.default)(r,n),this.options=r,this.debug=this.debug.bind(this),this.log=this.log.bind(this),this.info=this.info.bind(this),this.warn=this.warn.bind(this),this.error=this.error.bind(this)}return(0,f.default)(t,[{key:"debug",value:function(){this._shouldLog(d.DEBUG)&&this._write(d.DEBUG,h.apply(null,arguments))}},{key:"log",value:function(){this._shouldLog(d.DEBUG)&&this.debug.apply(this,arguments)}},{key:"info",value:function(){this._shouldLog(d.INFO)&&this._write(d.INFO,h.apply(null,arguments))}},{key:"warn",value:function(){this._shouldLog(d.WARN)&&this._write(d.WARN,h.apply(null,arguments))}},{key:"error",value:function(){this._shouldLog(d.ERROR)&&this._write(d.ERROR,h.apply(null,arguments))}},{key:"_write",value:function(t,e){(this.options.filename||b)&&!this.fileWriter&&g&&(this.fileWriter=p.openSync(this.options.filename||b,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&&g&&p.writeSync(this.fileWriter,r+"\n",null,"utf-8"),g||!this.options.useColors?(console.log(o),w.emit("data",this.category,t,e)):t===d.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="",s=": ";if(this.options.useColors){var u=(0,i.default)(d).map(function(t){return d[t]}).indexOf(t),c=this.options.color;g?(this.options.showTimestamp&&(n="[3"+_.Grey+"m"),this.options.showLevel&&(r="[3"+x[u]+";22m"),o="[3"+c+";1m",s=": "):(this.options.showTimestamp&&(n="color:"+_.Grey),this.options.showLevel&&(r="color:"+x[u]),o="color:"+c+"; font-weight: bold")}return{timestamp:n,level:r,category:o,text:s}}},{key:"_createLogMessage",value:function(t,e,n,r,o,i){n=n||"",r=r||"",o=o||"",i=i||": ",!g&&this.options.useColors&&(this.options.showTimestamp&&(n="%c"),this.options.showLevel&&(r="%c"),o="%c",i=": %c");var s="";return this.options.showTimestamp&&!this.options.useLocalTime&&(s+=(new Date).toISOString()+" "),this.options.showTimestamp&&this.options.useLocalTime&&(s+=(new Date).toLocaleString()+" "),s=n+s,this.options.showLevel&&(s+=r+"["+t+"]"+(t===d.INFO||t===d.WARN?" ":"")+" "),s+=o+this.category,s+=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():null;n="undefined"!=typeof window&&window.LOG?window.LOG.toUpperCase():n;var r=n||m,o=(0,i.default)(d).map(function(t){return d[t]});return o.indexOf(t)>=o.indexOf(r)}}]),t}();t.exports={Colors:_,LogLevels:d,setLogLevel:function(t){m=t},setLogfile:function(t){b=t},create:function(t,e){return new L(t,e)},forceBrowserMode:function(t){return g=!t},events:w}}).call(e,n(3))},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 s=i>=0?arguments[i]:t.cwd();if("string"!=typeof s)throw new TypeError("Arguments to path.resolve must be strings");s&&(e=s+"/"+e,o="/"===s.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="/"===s(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("/")),s=Math.min(o.length,i.length),u=s,c=0;c<s;c++)if(o[c]!==i[c]){u=c;break}for(var l=[],c=u;c<o.length;c++)l.push("..");return l=l.concat(i.slice(u)),l.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 s="b"==="ab".substr(-1)?function(t,e,n){return t.substr(e,n)}:function(t,e,n){return e<0&&(e=t.length+e),t.substr(e,n)}}).call(e,n(3))},function(t,e,n){t.exports={default:n(18),__esModule:!0}},function(t,e,n){n(19),t.exports=n(0).Object.keys},function(t,e,n){var r=n(7),o=n(9);n(30)("keys",function(){return function(t){return o(r(t))}})},function(t,e,n){var r=n(10),o=n(11),i=n(22)(!1),s=n(25)("IE_PROTO");t.exports=function(t,e){var n,u=o(t),c=0,l=[];for(n in u)n!=s&&r(u,n)&&l.push(n);for(;e.length>c;)r(u,n=e[c++])&&(~i(l,n)||l.push(n));return l}},function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},function(t,e,n){var r=n(11),o=n(23),i=n(24);t.exports=function(t){return function(e,n,s){var u,c=r(e),l=o(c.length),a=i(s,l);if(t&&n!=n){for(;l>a;)if((u=c[a++])!=u)return!0}else for(;l>a;a++)if((t||a in c)&&c[a]===n)return t||a||0;return!t&&-1}}},function(t,e,n){var r=n(13),o=Math.min;t.exports=function(t){return t>0?o(r(t),9007199254740991):0}},function(t,e,n){var r=n(13),o=Math.max,i=Math.min;t.exports=function(t,e){return t=r(t),t<0?o(t+e,0):i(t,e)}},function(t,e,n){var r=n(26)("keys"),o=n(28);t.exports=function(t){return r[t]||(r[t]=o(t))}},function(t,e,n){var r=n(0),o=n(4),i=o["__core-js_shared__"]||(o["__core-js_shared__"]={});(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:r.version,mode:n(27)?"pure":"global",copyright:"© 2018 Denis Pushkarev (zloirock.ru)"})},function(t,e){t.exports=!0},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){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,e,n){var r=n(5),o=n(0),i=n(2);t.exports=function(t,e){var n=(o.Object||{})[t]||Object[t],s={};s[t]=e(n),r(r.S+r.F*i(function(){n(1)}),"Object",s)}},function(t,e,n){var r=n(32);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){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,e,n){var r=n(14),o=n(38);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){var r=n(6);t.exports=function(t){if(!r(t))throw TypeError(t+" is not an object!");return t}},function(t,e,n){t.exports=!n(1)&&!n(2)(function(){return 7!=Object.defineProperty(n(36)("div"),"a",{get:function(){return 7}}).a})},function(t,e,n){var r=n(6),o=n(4).document,i=r(o)&&r(o.createElement);t.exports=function(t){return i?o.createElement(t):{}}},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){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},function(t,e,n){t.exports={default:n(40),__esModule:!0}},function(t,e,n){n(41),t.exports=n(0).Object.assign},function(t,e,n){var r=n(5);r(r.S+r.F,"Object",{assign:n(42)})},function(t,e,n){"use strict";var r=n(9),o=n(43),i=n(44),s=n(7),u=n(12),c=Object.assign;t.exports=!c||n(2)(function(){var t={},e={},n=Symbol(),r="abcdefghijklmnopqrst";return t[n]=7,r.split("").forEach(function(t){e[t]=t}),7!=c({},t)[n]||Object.keys(c({},e)).join("")!=r})?function(t,e){for(var n=s(t),c=arguments.length,l=1,a=o.f,f=i.f;c>l;)for(var p,h=u(arguments[l++]),v=a?r(h).concat(a(h)):r(h),y=v.length,g=0;y>g;)f.call(h,p=v[g++])&&(n[p]=h[p]);return n}:c},function(t,e){e.f=Object.getOwnPropertySymbols},function(t,e){e.f={}.propertyIsEnumerable},function(t,e,n){"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";e.__esModule=!0;var r=n(47),o=function(t){return t&&t.__esModule?t:{default:t}}(r);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,o.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){t.exports={default:n(48),__esModule:!0}},function(t,e,n){n(49);var r=n(0).Object;t.exports=function(t,e,n){return r.defineProperty(t,e,n)}},function(t,e,n){var r=n(5);r(r.S+r.F*!n(1),"Object",{defineProperty:n(14).f})},function(t,e){},function(t,e,n){(function(t,r){function o(t,n){var r={seen:[],stylize:s};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),y(n)?r.showHidden=n:n&&e._extend(r,n),_(r.showHidden)&&(r.showHidden=!1),_(r.depth)&&(r.depth=2),_(r.colors)&&(r.colors=!1),_(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=i),c(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 s(t,e){return t}function u(t){var e={};return t.forEach(function(t,n){e[t]=!0}),e}function c(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=c(t,o,r)),o}var i=l(t,n);if(i)return i;var s=Object.keys(n),y=u(s);if(t.showHidden&&(s=Object.getOwnPropertyNames(n)),j(n)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return a(n);if(0===s.length){if(E(n)){var g=n.name?": "+n.name:"";return t.stylize("[Function"+g+"]","special")}if(x(n))return t.stylize(RegExp.prototype.toString.call(n),"regexp");if(L(n))return t.stylize(Date.prototype.toString.call(n),"date");if(j(n))return a(n)}var d="",m=!1,w=["{","}"];if(v(n)&&(m=!0,w=["[","]"]),E(n)){d=" [Function"+(n.name?": "+n.name:"")+"]"}if(x(n)&&(d=" "+RegExp.prototype.toString.call(n)),L(n)&&(d=" "+Date.prototype.toUTCString.call(n)),j(n)&&(d=" "+a(n)),0===s.length&&(!m||0==n.length))return w[0]+d+w[1];if(r<0)return x(n)?t.stylize(RegExp.prototype.toString.call(n),"regexp"):t.stylize("[Object]","special");t.seen.push(n);var _;return _=m?f(t,n,r,y,s):s.map(function(e){return p(t,n,r,y,e,m)}),t.seen.pop(),h(_,d,w)}function l(t,e){if(_(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"):y(e)?t.stylize(""+e,"boolean"):g(e)?t.stylize("null","null"):void 0}function a(t){return"["+Error.prototype.toString.call(t)+"]"}function f(t,e,n,r,o){for(var i=[],s=0,u=e.length;s<u;++s)T(e,String(s))?i.push(p(t,e,n,r,String(s),!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 s,u,l;if(l=Object.getOwnPropertyDescriptor(e,o)||{value:e[o]},l.get?u=l.set?t.stylize("[Getter/Setter]","special"):t.stylize("[Getter]","special"):l.set&&(u=t.stylize("[Setter]","special")),T(r,o)||(s="["+o+"]"),u||(t.seen.indexOf(l.value)<0?(u=g(n)?c(t,l.value,null):c(t,l.value,n-1),u.indexOf("\n")>-1&&(u=i?u.split("\n").map(function(t){return" "+t}).join("\n").substr(2):"\n"+u.split("\n").map(function(t){return" "+t}).join("\n"))):u=t.stylize("[Circular]","special")),_(s)){if(i&&o.match(/^\d+$/))return u;s=JSON.stringify(""+o),s.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.substr(1,s.length-2),s=t.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=t.stylize(s,"string"))}return s+": "+u}function h(t,e,n){var r=0;return t.reduce(function(t,e){return r++,e.indexOf("\n")>=0&&r++,t+e.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?n[0]+(""===e?"":e+"\n ")+" "+t.join(",\n ")+" "+n[1]:n[0]+e+" "+t.join(", ")+" "+n[1]}function v(t){return Array.isArray(t)}function y(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 _(t){return void 0===t}function x(t){return O(t)&&"[object RegExp]"===k(t)}function O(t){return"object"==typeof t&&null!==t}function L(t){return O(t)&&"[object Date]"===k(t)}function j(t){return O(t)&&("[object Error]"===k(t)||t instanceof Error)}function E(t){return"function"==typeof t}function S(t){return null===t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||"symbol"==typeof t||void 0===t}function k(t){return Object.prototype.toString.call(t)}function R(t){return t<10?"0"+t.toString(10):t.toString(10)}function M(){var t=new Date,e=[R(t.getHours()),R(t.getMinutes()),R(t.getSeconds())].join(":");return[t.getDate(),z[t.getMonth()],e].join(" ")}function T(t,e){return Object.prototype.hasOwnProperty.call(t,e)}var N=/%[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,s=String(t).replace(N,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(t){return"[Circular]"}default:return t}}),u=r[n];n<i;u=r[++n])g(u)||!O(u)?s+=" "+u:s+=" "+o(u);return s},e.deprecate=function(n,o){function i(){if(!s){if(r.throwDeprecation)throw new Error(o);r.traceDeprecation?console.trace(o):console.error(o),s=!0}return n.apply(this,arguments)}if(_(t.process))return function(){return e.deprecate(n,o).apply(this,arguments)};if(!0===r.noDeprecation)return n;var s=!1;return i};var D,A={};e.debuglog=function(t){if(_(D)&&(D=r.env.NODE_DEBUG||""),t=t.toUpperCase(),!A[t])if(new RegExp("\\b"+t+"\\b","i").test(D)){var n=r.pid;A[t]=function(){var r=e.format.apply(e,arguments);console.error("%s %d: %s",t,n,r)}}else A[t]=function(){};return A[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=v,e.isBoolean=y,e.isNull=g,e.isNullOrUndefined=d,e.isNumber=m,e.isString=b,e.isSymbol=w,e.isUndefined=_,e.isRegExp=x,e.isObject=O,e.isDate=L,e.isError=j,e.isFunction=E,e.isPrimitive=S,e.isBuffer=n(53);var z=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];e.log=function(){console.log("%s - %s",M(),e.format.apply(e,arguments))},e.inherits=n(54),e._extend=function(t,e){if(!e||!O(e))return t;for(var n=Object.keys(e),r=n.length;r--;)t[n[r]]=e[n[r]];return t}}).call(e,n(52),n(3))},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(n=window)}t.exports=n},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){"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){function n(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}function r(t){return"function"==typeof t}function o(t){return"number"==typeof t}function i(t){return"object"==typeof t&&null!==t}function s(t){return void 0===t}t.exports=n,n.EventEmitter=n,n.prototype._events=void 0,n.prototype._maxListeners=void 0,n.defaultMaxListeners=10,n.prototype.setMaxListeners=function(t){if(!o(t)||t<0||isNaN(t))throw TypeError("n must be a positive number");return this._maxListeners=t,this},n.prototype.emit=function(t){var e,n,o,u,c,l;if(this._events||(this._events={}),"error"===t&&(!this._events.error||i(this._events.error)&&!this._events.error.length)){if((e=arguments[1])instanceof Error)throw e;var a=new Error('Uncaught, unspecified "error" event. ('+e+")");throw a.context=e,a}if(n=this._events[t],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:u=Array.prototype.slice.call(arguments,1),n.apply(this,u)}else if(i(n))for(u=Array.prototype.slice.call(arguments,1),l=n.slice(),o=l.length,c=0;c<o;c++)l[c].apply(this,u);return!0},n.prototype.addListener=function(t,e){var o;if(!r(e))throw TypeError("listener must be a function");return this._events||(this._events={}),this._events.newListener&&this.emit("newListener",t,r(e.listener)?e.listener:e),this._events[t]?i(this._events[t])?this._events[t].push(e):this._events[t]=[this._events[t],e]:this._events[t]=e,i(this._events[t])&&!this._events[t].warned&&(o=s(this._maxListeners)?n.defaultMaxListeners:this._maxListeners)&&o>0&&this._events[t].length>o&&(this._events[t].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[t].length),"function"==typeof console.trace&&console.trace()),this},n.prototype.on=n.prototype.addListener,n.prototype.once=function(t,e){function n(){this.removeListener(t,n),o||(o=!0,e.apply(this,arguments))}if(!r(e))throw TypeError("listener must be a function");var o=!1;return n.listener=e,this.on(t,n),this},n.prototype.removeListener=function(t,e){var n,o,s,u;if(!r(e))throw TypeError("listener must be a function");if(!this._events||!this._events[t])return this;if(n=this._events[t],s=n.length,o=-1,n===e||r(n.listener)&&n.listener===e)delete this._events[t],this._events.removeListener&&this.emit("removeListener",t,e);else if(i(n)){for(u=s;u-- >0;)if(n[u]===e||n[u].listener&&n[u].listener===e){o=u;break}if(o<0)return this;1===n.length?(n.length=0,delete this._events[t]):n.splice(o,1),this._events.removeListener&&this.emit("removeListener",t,e)}return this},n.prototype.removeAllListeners=function(t){var e,n;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[t]&&delete this._events[t],this;if(0===arguments.length){for(e in this._events)"removeListener"!==e&&this.removeAllListeners(e);return this.removeAllListeners("removeListener"),this._events={},this}if(n=this._events[t],r(n))this.removeListener(t,n);else if(n)for(;n.length;)this.removeListener(t,n[n.length-1]);return delete this._events[t],this},n.prototype.listeners=function(t){return this._events&&this._events[t]?r(this._events[t])?[this._events[t]]:this._events[t].slice():[]},n.prototype.listenerCount=function(t){if(this._events){var e=this._events[t];if(r(e))return 1;if(e)return e.length}return 0},n.listenerCount=function(t,e){return t.listenerCount(e)}}]);

@@ -25,3 +25,4 @@ 'use strict';

var isNodejs = process.version ? true : false;
var isElectronRenderer = process.type && process.type === 'renderer';
var isNodejs = !isElectronRenderer && process.version ? true : false;

@@ -80,2 +81,3 @@ var LogLevels = {

showTimestamp: true,
useLocalTime: false,
showLevel: true,

@@ -95,2 +97,7 @@ filename: GlobalLogfile,

this.options = opts;
this.debug = this.debug.bind(this);
this.log = this.log.bind(this);
this.info = this.info.bind(this);
this.warn = this.warn.bind(this);
this.error = this.error.bind(this);
}

@@ -218,4 +225,6 @@

if (this.options.showTimestamp) result += '' + new Date().toISOString() + ' ';
if (this.options.showTimestamp && !this.options.useLocalTime) result += '' + new Date().toISOString() + ' ';
if (this.options.showTimestamp && this.options.useLocalTime) result += '' + new Date().toLocaleString() + ' ';
result = timestampFormat + result;

@@ -222,0 +231,0 @@

'use strict';
/*
Using the ES5 module for the sake of example.
/*
Using the ES5 module for the sake of example.
To use the regular ES6 version, one would include it with:

@@ -13,2 +13,3 @@ const Logger = require('logplease')

const logger3 = Logger.create('logger3', { color: Logger.Colors.Magenta, showTimestamp: false, showLevel: false });
const logger4 = Logger.create('logger4-local-time', { useLocalTime: true });

@@ -41,2 +42,7 @@ const red = Logger.create('red', { color: Logger.Colors.Red, showTimestamp: false, showLevel: false });

logger4.debug(`This is a debug message #${number}`);
logger4.info(`This is an info message #${number}`);
logger4.warn(`This is a warning message #${number}`);
logger4.error(`This is an error message #${number}`);
red.log(`Red log message`); // log() is an alias for debug()

@@ -43,0 +49,0 @@ green.log(`Green log message`);

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

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

"buffer": "^5.0.7",
"mocha": "^3.5.0",
"mocha": "^5.2.0",
"webpack": "^3.5.5"
}
}

@@ -82,2 +82,3 @@ # logplease

showTimestamp: true, // Display timestamp in the log message
useLocalTime: false, // Display timestamp in local timezone
showLevel: true, // Display log level in the log message

@@ -84,0 +85,0 @@ filename: null, // Set file path to log to a file

@@ -7,3 +7,4 @@ 'use strict';

let isNodejs = process.version ? true : false;
let isElectronRenderer = process.type && process.type === 'renderer';
let isNodejs = !isElectronRenderer && process.version ? true : false;

@@ -62,2 +63,3 @@ const LogLevels = {

showTimestamp: true,
useLocalTime: false,
showLevel: true,

@@ -75,2 +77,7 @@ filename: GlobalLogfile,

this.options = opts;
this.debug = this.debug.bind(this);
this.log = this.log.bind(this);
this.info = this.info.bind(this);
this.warn = this.warn.bind(this);
this.error = this.error.bind(this);
}

@@ -200,5 +207,8 @@

if(this.options.showTimestamp)
if(this.options.showTimestamp && !this.options.useLocalTime)
result += '' + new Date().toISOString() + ' ';
if(this.options.showTimestamp && this.options.useLocalTime)
result += '' + new Date().toLocaleString() + ' ';
result = timestampFormat + result;

@@ -205,0 +215,0 @@

@@ -72,2 +72,3 @@ 'use strict'

showTimestamp: false,
useLocalTime: true,
showLevel: false,

@@ -83,2 +84,3 @@ filename: 'test.log',

assert.equal(log.options.showTimestamp, false)
assert.equal(log.options.useLocalTime, true)
assert.equal(log.options.showLevel, false)

@@ -101,2 +103,3 @@ assert.equal(log.options.filename, 'test.log')

assert.equal(log.options.showTimestamp, true)
assert.equal(log.options.useLocalTime, false)
assert.equal(log.options.showLevel, true)

@@ -184,5 +187,7 @@ assert.equal(log.options.filename, null)

it('writes timestamp', (done) => {
it('writes timestamp in iso time', (done) => {
let out = ''
let old = console.log
// ignore seconds when comparing times
let isoTime = new Date().toISOString().slice(0, 19)
console.log = (d) => out += d

@@ -194,5 +199,22 @@ const log = Logger.create('test1')

assert.equal(out.split(" ")[3], 'hi')
let loggedTime = out.split(" ")[0].replace('\u001b[37m', '').slice(0, 19)
assert.equal(isoTime, loggedTime)
done()
})
it('writes timestamp in local time', (done) => {
let out = ''
let old = console.log
let localTime = new Date().toLocaleString()
console.log = (d) => out += d
const log = Logger.create('test1', {useLocalTime: true})
log.debug("hi")
console.log = old
let logArray = out.split(" ")
assert.equal(logArray[logArray.length - 1], 'hi')
let loggedTime = logArray.slice(0, logArray.length - 3).join(' ').replace('\u001b[37m', '')
assert.equal(localTime, loggedTime)
done()
})
it('doesn\'t write timestamp', (done) => {

@@ -199,0 +221,0 @@ let out = ''

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

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