mirror of
https://github.com/beestat/app.git
synced 2025-06-01 20:56:44 -04:00
4 lines
55 KiB
JavaScript
4 lines
55 KiB
JavaScript
/*! @sentry/browser 5.13.2 (9cfa4a5b) | https://github.com/getsentry/sentry-javascript */
|
|
var Sentry=function(n){var t=function(n,r){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,t){n.__proto__=t}||function(n,t){for(var r in t)t.hasOwnProperty(r)&&(n[r]=t[r])})(n,r)};function r(n,r){function e(){this.constructor=n}t(n,r),n.prototype=null===r?Object.create(r):(e.prototype=r.prototype,new e)}var e=function(){return(e=Object.assign||function(n){for(var t,r=1,e=arguments.length;r<e;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(n[i]=t[i]);return n}).apply(this,arguments)};function i(n){var t="function"==typeof Symbol&&n[Symbol.iterator],r=0;return t?t.call(n):{next:function(){return n&&r>=n.length&&(n=void 0),{value:n&&n[r++],done:!n}}}}function o(n,t){var r="function"==typeof Symbol&&n[Symbol.iterator];if(!r)return n;var e,i,o=r.call(n),u=[];try{for(;(void 0===t||t-- >0)&&!(e=o.next()).done;)u.push(e.value)}catch(n){i={error:n}}finally{try{e&&!e.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return u}function u(){for(var n=[],t=0;t<arguments.length;t++)n=n.concat(o(arguments[t]));return n}var c,a,s,f;!function(n){n[n.None=0]="None",n[n.Error=1]="Error",n[n.Debug=2]="Debug",n[n.Verbose=3]="Verbose"}(c||(c={})),(a=n.Severity||(n.Severity={})).Fatal="fatal",a.Error="error",a.Warning="warning",a.Log="log",a.Info="info",a.Debug="debug",a.Critical="critical",function(n){n.fromString=function(t){switch(t){case"debug":return n.Debug;case"info":return n.Info;case"warn":case"warning":return n.Warning;case"error":return n.Error;case"fatal":return n.Fatal;case"critical":return n.Critical;case"log":default:return n.Log}}}(n.Severity||(n.Severity={})),function(n){n.Ok="ok",n.DeadlineExceeded="deadline_exceeded",n.Unauthenticated="unauthenticated",n.PermissionDenied="permission_denied",n.NotFound="not_found",n.ResourceExhausted="resource_exhausted",n.InvalidArgument="invalid_argument",n.Unimplemented="unimplemented",n.Unavailable="unavailable",n.InternalError="internal_error",n.UnknownError="unknown_error",n.Cancelled="cancelled",n.AlreadyExists="already_exists",n.FailedPrecondition="failed_precondition",n.Aborted="aborted",n.OutOfRange="out_of_range",n.DataLoss="data_loss"}(s||(s={})),function(n){n.fromHttpCode=function(t){if(t<400)return n.Ok;if(t>=400&&t<500)switch(t){case 401:return n.Unauthenticated;case 403:return n.PermissionDenied;case 404:return n.NotFound;case 409:return n.AlreadyExists;case 413:return n.FailedPrecondition;case 429:return n.ResourceExhausted;default:return n.InvalidArgument}if(t>=500&&t<600)switch(t){case 501:return n.Unimplemented;case 503:return n.Unavailable;case 504:return n.DeadlineExceeded;default:return n.InternalError}return n.UnknownError}}(s||(s={})),(f=n.Status||(n.Status={})).Unknown="unknown",f.Skipped="skipped",f.Success="success",f.RateLimit="rate_limit",f.Invalid="invalid",f.Failed="failed",function(n){n.fromHttpCode=function(t){return t>=200&&t<300?n.Success:429===t?n.RateLimit:t>=400&&t<500?n.Invalid:t>=500?n.Failed:n.Unknown}}(n.Status||(n.Status={}));var h=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(n,t){return n.__proto__=t,n}:function(n,t){for(var r in t)n.hasOwnProperty(r)||(n[r]=t[r]);return n});var v=function(n){function t(t){var r=this.constructor,e=n.call(this,t)||this;return e.message=t,e.name=r.prototype.constructor.name,h(e,r.prototype),e}return r(t,n),t}(Error);function l(n){switch(Object.prototype.toString.call(n)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return x(n,Error)}}function d(n){return"[object ErrorEvent]"===Object.prototype.toString.call(n)}function p(n){return"[object DOMError]"===Object.prototype.toString.call(n)}function y(n){return"[object String]"===Object.prototype.toString.call(n)}function m(n){return null===n||"object"!=typeof n&&"function"!=typeof n}function b(n){return"[object Object]"===Object.prototype.toString.call(n)}function w(n){return"undefined"!=typeof Event&&x(n,Event)}function g(n){return"undefined"!=typeof Element&&x(n,Element)}function E(n){return Boolean(n&&n.then&&"function"==typeof n.then)}function x(n,t){try{return n instanceof t}catch(n){return!1}}function j(n,t){return void 0===t&&(t=0),"string"!=typeof n||0===t?n:n.length<=t?n:n.substr(0,t)+"..."}function k(n,t){if(!Array.isArray(n))return"";for(var r=[],e=0;e<n.length;e++){var i=n[e];try{r.push(String(i))}catch(n){r.push("[value cannot be serialized]")}}return r.join(t)}function _(n,t){return r=t,"[object RegExp]"===Object.prototype.toString.call(r)?t.test(n):"string"==typeof t&&-1!==n.indexOf(t);var r}function S(){return"[object process]"===Object.prototype.toString.call("undefined"!=typeof process?process:0)}var O={};function T(){return S()?global:"undefined"!=typeof window?window:"undefined"!=typeof self?self:O}function D(){var n=T(),t=n.crypto||n.msCrypto;if(void 0!==t&&t.getRandomValues){var r=new Uint16Array(8);t.getRandomValues(r),r[3]=4095&r[3]|16384,r[4]=16383&r[4]|32768;var e=function(n){for(var t=n.toString(16);t.length<4;)t="0"+t;return t};return e(r[0])+e(r[1])+e(r[2])+e(r[3])+e(r[4])+e(r[5])+e(r[6])+e(r[7])}return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,function(n){var t=16*Math.random()|0;return("x"===n?t:3&t|8).toString(16)})}function R(n){if(!n)return{};var t=n.match(/^(([^:\/?#]+):)?(\/\/([^\/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};var r=t[6]||"",e=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],relative:t[5]+r+e}}function N(n){if(n.message)return n.message;if(n.exception&&n.exception.values&&n.exception.values[0]){var t=n.exception.values[0];return t.type&&t.value?t.type+": "+t.value:t.type||t.value||n.event_id||"<unknown>"}return n.event_id||"<unknown>"}function I(n){var t=T();if(!("console"in t))return n();var r=t.console,e={};["debug","info","warn","error","log","assert"].forEach(function(n){n in t.console&&r[n].__sentry_original__&&(e[n]=r[n],r[n]=r[n].__sentry_original__)});var i=n();return Object.keys(e).forEach(function(n){r[n]=e[n]}),i}function C(n,t,r){n.exception=n.exception||{},n.exception.values=n.exception.values||[],n.exception.values[0]=n.exception.values[0]||{},n.exception.values[0].value=n.exception.values[0].value||t||"",n.exception.values[0].type=n.exception.values[0].type||r||"Error"}function M(n,t){void 0===t&&(t={});try{n.exception.values[0].mechanism=n.exception.values[0].mechanism||{},Object.keys(t).forEach(function(r){n.exception.values[0].mechanism[r]=t[r]})}catch(n){}}function A(n){try{for(var t=n,r=[],e=0,i=0,o=" > ".length,u=void 0;t&&e++<5&&!("html"===(u=U(t))||e>1&&i+r.length*o+u.length>=80);)r.push(u),i+=u.length,t=t.parentNode;return r.reverse().join(" > ")}catch(n){return"<unknown>"}}function U(n){var t,r,e,i,o,u=n,c=[];if(!u||!u.tagName)return"";if(c.push(u.tagName.toLowerCase()),u.id&&c.push("#"+u.id),(t=u.className)&&y(t))for(r=t.split(/\s+/),o=0;o<r.length;o++)c.push("."+r[o]);var a=["type","name","title","alt"];for(o=0;o<a.length;o++)e=a[o],(i=u.getAttribute(e))&&c.push("["+e+'="'+i+'"]');return c.join("")}function q(){return Date.now()/1e3}var L=6e4;function H(n,t){if(!t)return L;var r=parseInt(""+t,10);if(!isNaN(r))return 1e3*r;var e=Date.parse(""+t);return isNaN(e)?L:e-n}var P="<anonymous>";function F(n){try{return n&&"function"==typeof n&&n.name||P}catch(n){return P}}var W=T(),X="Sentry Logger ",B=function(){function n(){this.t=!1}return n.prototype.disable=function(){this.t=!1},n.prototype.enable=function(){this.t=!0},n.prototype.log=function(){for(var n=[],t=0;t<arguments.length;t++)n[t]=arguments[t];this.t&&I(function(){W.console.log(X+"[Log]: "+n.join(" "))})},n.prototype.warn=function(){for(var n=[],t=0;t<arguments.length;t++)n[t]=arguments[t];this.t&&I(function(){W.console.warn(X+"[Warn]: "+n.join(" "))})},n.prototype.error=function(){for(var n=[],t=0;t<arguments.length;t++)n[t]=arguments[t];this.t&&I(function(){W.console.error(X+"[Error]: "+n.join(" "))})},n}();W.__SENTRY__=W.__SENTRY__||{};var $,G=W.__SENTRY__.logger||(W.__SENTRY__.logger=new B),J=function(){function n(){this.i="function"==typeof WeakSet,this.o=this.i?new WeakSet:[]}return n.prototype.memoize=function(n){if(this.i)return!!this.o.has(n)||(this.o.add(n),!1);for(var t=0;t<this.o.length;t++){if(this.o[t]===n)return!0}return this.o.push(n),!1},n.prototype.unmemoize=function(n){if(this.i)this.o.delete(n);else for(var t=0;t<this.o.length;t++)if(this.o[t]===n){this.o.splice(t,1);break}},n}();function z(n,t,r){if(t in n){var e=n[t],i=r(e);if("function"==typeof i)try{i.prototype=i.prototype||{},Object.defineProperties(i,{__sentry_original__:{enumerable:!1,value:e}})}catch(n){}n[t]=i}}function V(n){if(l(n)){var t=n,r={message:t.message,name:t.name,stack:t.stack};for(var e in t)Object.prototype.hasOwnProperty.call(t,e)&&(r[e]=t[e]);return r}if(w(n)){var i=n,o={};o.type=i.type;try{o.target=g(i.target)?A(i.target):Object.prototype.toString.call(i.target)}catch(n){o.target="<unknown>"}try{o.currentTarget=g(i.currentTarget)?A(i.currentTarget):Object.prototype.toString.call(i.currentTarget)}catch(n){o.currentTarget="<unknown>"}for(var e in"undefined"!=typeof CustomEvent&&x(n,CustomEvent)&&(o.detail=i.detail),i)Object.prototype.hasOwnProperty.call(i,e)&&(o[e]=i);return o}return n}function K(n){return function(n){return~-encodeURI(n).split(/%..|./).length}(JSON.stringify(n))}function Q(n,t,r){void 0===t&&(t=3),void 0===r&&(r=102400);var e=nn(n,t);return K(e)>r?Q(n,t-1,r):e}function Y(n,t){return"domain"===t&&n&&"object"==typeof n&&n.u?"[Domain]":"domainEmitter"===t?"[DomainEmitter]":"undefined"!=typeof global&&n===global?"[Global]":"undefined"!=typeof window&&n===window?"[Window]":"undefined"!=typeof document&&n===document?"[Document]":b(r=n)&&"nativeEvent"in r&&"preventDefault"in r&&"stopPropagation"in r?"[SyntheticEvent]":"number"==typeof n&&n!=n?"[NaN]":void 0===n?"[undefined]":"function"==typeof n?"[Function: "+F(n)+"]":n;var r}function Z(n,t,r,e){if(void 0===r&&(r=1/0),void 0===e&&(e=new J),0===r)return function(n){var t=Object.prototype.toString.call(n);if("string"==typeof n)return n;if("[object Object]"===t)return"[Object]";if("[object Array]"===t)return"[Array]";var r=Y(n);return m(r)?r:t}(t);if(null!=t&&"function"==typeof t.toJSON)return t.toJSON();var i=Y(t,n);if(m(i))return i;var o=V(t),u=Array.isArray(t)?[]:{};if(e.memoize(t))return"[Circular ~]";for(var c in o)Object.prototype.hasOwnProperty.call(o,c)&&(u[c]=Z(c,o[c],r-1,e));return e.unmemoize(t),u}function nn(n,t){try{return JSON.parse(JSON.stringify(n,function(n,r){return Z(n,r,t)}))}catch(n){return"**non-serializable**"}}function tn(n,t){void 0===t&&(t=40);var r=Object.keys(V(n));if(r.sort(),!r.length)return"[object has no keys]";if(r[0].length>=t)return j(r[0],t);for(var e=r.length;e>0;e--){var i=r.slice(0,e).join(", ");if(!(i.length>t))return e===r.length?i:j(i,t)}return""}!function(n){n.PENDING="PENDING",n.RESOLVED="RESOLVED",n.REJECTED="REJECTED"}($||($={}));var rn=function(){function n(n){var t=this;this.s=$.PENDING,this.h=[],this.v=function(n){t.l($.RESOLVED,n)},this.p=function(n){t.l($.REJECTED,n)},this.l=function(n,r){t.s===$.PENDING&&(E(r)?r.then(t.v,t.p):(t.s=n,t.m=r,t.g()))},this.j=function(n){t.h=t.h.concat(n),t.g()},this.g=function(){t.s!==$.PENDING&&(t.s===$.REJECTED?t.h.forEach(function(n){n.onrejected&&n.onrejected(t.m)}):t.h.forEach(function(n){n.onfulfilled&&n.onfulfilled(t.m)}),t.h=[])};try{n(this.v,this.p)}catch(n){this.p(n)}}return n.prototype.toString=function(){return"[object SyncPromise]"},n.resolve=function(t){return new n(function(n){n(t)})},n.reject=function(t){return new n(function(n,r){r(t)})},n.all=function(t){return new n(function(r,e){if(Array.isArray(t))if(0!==t.length){var i=t.length,o=[];t.forEach(function(t,u){n.resolve(t).then(function(n){o[u]=n,0===(i-=1)&&r(o)}).then(null,e)})}else r([]);else e(new TypeError("Promise.all requires an array as input."))})},n.prototype.then=function(t,r){var e=this;return new n(function(n,i){e.j({onfulfilled:function(r){if(t)try{return void n(t(r))}catch(n){return void i(n)}else n(r)},onrejected:function(t){if(r)try{return void n(r(t))}catch(n){return void i(n)}else i(t)}})})},n.prototype.catch=function(n){return this.then(function(n){return n},n)},n.prototype.finally=function(t){var r=this;return new n(function(n,e){var i,o;return r.then(function(n){o=!1,i=n,t&&t()},function(n){o=!0,i=n,t&&t()}).then(function(){o?e(i):n(i)})})},n}(),en=function(){function n(n){this.k=n,this._=[]}return n.prototype.isReady=function(){return void 0===this.k||this.length()<this.k},n.prototype.add=function(n){var t=this;return this.isReady()?(-1===this._.indexOf(n)&&this._.push(n),n.then(function(){return t.remove(n)}).then(null,function(){return t.remove(n).then(null,function(){})}),n):rn.reject(new v("Not adding Promise due to buffer limit reached."))},n.prototype.remove=function(n){return this._.splice(this._.indexOf(n),1)[0]},n.prototype.length=function(){return this._.length},n.prototype.drain=function(n){var t=this;return new rn(function(r){var e=setTimeout(function(){n&&n>0&&r(!1)},n);rn.all(t._).then(function(){clearTimeout(e),r(!0)}).then(null,function(){r(!0)})})},n}();function on(){if(!("fetch"in T()))return!1;try{return new Headers,new Request(""),new Response,!0}catch(n){return!1}}function un(n){return n&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(n.toString())}function cn(){if(!on())return!1;try{return new Request("_",{referrerPolicy:"origin"}),!0}catch(n){return!1}}var an,sn=T(),fn={},hn={};function vn(n){if(!hn[n])switch(hn[n]=!0,n){case"console":!function(){if(!("console"in sn))return;["debug","info","warn","error","log","assert"].forEach(function(n){n in sn.console&&z(sn.console,n,function(t){return function(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];dn("console",{args:r,level:n}),t&&Function.prototype.apply.call(t,sn.console,r)}})})}();break;case"dom":!function(){if(!("document"in sn))return;sn.document.addEventListener("click",En("click",dn.bind(null,"dom")),!1),sn.document.addEventListener("keypress",xn(dn.bind(null,"dom")),!1),["EventTarget","Node"].forEach(function(n){var t=sn[n]&&sn[n].prototype;t&&t.hasOwnProperty&&t.hasOwnProperty("addEventListener")&&(z(t,"addEventListener",function(n){return function(t,r,e){return r&&r.handleEvent?("click"===t&&z(r,"handleEvent",function(n){return function(t){return En("click",dn.bind(null,"dom"))(t),n.call(this,t)}}),"keypress"===t&&z(r,"handleEvent",function(n){return function(t){return xn(dn.bind(null,"dom"))(t),n.call(this,t)}})):("click"===t&&En("click",dn.bind(null,"dom"),!0)(this),"keypress"===t&&xn(dn.bind(null,"dom"))(this)),n.call(this,t,r,e)}}),z(t,"removeEventListener",function(n){return function(t,r,e){var i=r;try{i=i&&(i.__sentry_wrapped__||i)}catch(n){}return n.call(this,t,i,e)}}))})}();break;case"xhr":!function(){if(!("XMLHttpRequest"in sn))return;var n=XMLHttpRequest.prototype;z(n,"open",function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var e=t[1];return this.__sentry_xhr__={method:y(t[0])?t[0].toUpperCase():t[0],url:t[1]},y(e)&&"POST"===this.__sentry_xhr__.method&&e.match(/sentry_key/)&&(this.__sentry_own_request__=!0),n.apply(this,t)}}),z(n,"send",function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var i=this,o={args:t,startTimestamp:Date.now(),xhr:i};return dn("xhr",e({},o)),i.addEventListener("readystatechange",function(){if(4===i.readyState){try{i.__sentry_xhr__&&(i.__sentry_xhr__.status_code=i.status)}catch(n){}dn("xhr",e({},o,{endTimestamp:Date.now()}))}}),n.apply(this,t)}})}();break;case"fetch":!function(){if(!function(){if(!on())return!1;var n=T();if(un(n.fetch))return!0;var t=!1,r=n.document;if(r)try{var e=r.createElement("iframe");e.hidden=!0,r.head.appendChild(e),e.contentWindow&&e.contentWindow.fetch&&(t=un(e.contentWindow.fetch)),r.head.removeChild(e)}catch(n){G.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",n)}return t}())return;z(sn,"fetch",function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var i={args:t,fetchData:{method:pn(t),url:yn(t)},startTimestamp:Date.now()};return dn("fetch",e({},i)),n.apply(sn,t).then(function(n){return dn("fetch",e({},i,{endTimestamp:Date.now(),response:n})),n},function(n){throw dn("fetch",e({},i,{endTimestamp:Date.now(),error:n})),n})}})}();break;case"history":!function(){if(n=T(),t=n.chrome,r=t&&t.app&&t.app.runtime,e="history"in n&&!!n.history.pushState&&!!n.history.replaceState,r||!e)return;var n,t,r,e;var i=sn.onpopstate;function o(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var e=t.length>2?t[2]:void 0;if(e){var i=an,o=String(e);an=o,dn("history",{from:i,to:o})}return n.apply(this,t)}}sn.onpopstate=function(){for(var n=[],t=0;t<arguments.length;t++)n[t]=arguments[t];var r=sn.location.href,e=an;if(an=r,dn("history",{from:e,to:r}),i)return i.apply(this,n)},z(sn.history,"pushState",o),z(sn.history,"replaceState",o)}();break;default:G.warn("unknown instrumentation type:",n)}}function ln(n){n&&"string"==typeof n.type&&"function"==typeof n.callback&&(fn[n.type]=fn[n.type]||[],fn[n.type].push(n.callback),vn(n.type))}function dn(n,t){var r,e;if(n&&fn[n])try{for(var o=i(fn[n]||[]),u=o.next();!u.done;u=o.next()){var c=u.value;try{c(t)}catch(t){G.error("Error while triggering instrumentation handler.\nType: "+n+"\nName: "+F(c)+"\nError: "+t)}}}catch(n){r={error:n}}finally{try{u&&!u.done&&(e=o.return)&&e.call(o)}finally{if(r)throw r.error}}}function pn(n){return void 0===n&&(n=[]),"Request"in sn&&x(n[0],Request)&&n[0].method?String(n[0].method).toUpperCase():n[1]&&n[1].method?String(n[1].method).toUpperCase():"GET"}function yn(n){return void 0===n&&(n=[]),"string"==typeof n[0]?n[0]:"Request"in sn&&x(n[0],Request)?n[0].url:String(n[0])}var mn,bn,wn=1e3,gn=0;function En(n,t,r){return void 0===r&&(r=!1),function(e){mn=void 0,e&&bn!==e&&(bn=e,gn&&clearTimeout(gn),r?gn=setTimeout(function(){t({event:e,name:n})}):t({event:e,name:n}))}}function xn(n){return function(t){var r;try{r=t.target}catch(n){return}var e=r&&r.tagName;e&&("INPUT"===e||"TEXTAREA"===e||r.isContentEditable)&&(mn||En("input",n)(t),clearTimeout(mn),mn=setTimeout(function(){mn=void 0},wn))}}var jn=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+))?@)([\w\.-]+)(?::(\d+))?\/(.+)/,kn=function(){function n(n){"string"==typeof n?this.S(n):this.O(n),this.T()}return n.prototype.toString=function(n){void 0===n&&(n=!1);var t=this,r=t.host,e=t.path,i=t.pass,o=t.port,u=t.projectId;return t.protocol+"://"+t.user+(n&&i?":"+i:"")+"@"+r+(o?":"+o:"")+"/"+(e?e+"/":e)+u},n.prototype.S=function(n){var t=jn.exec(n);if(!t)throw new v("Invalid Dsn");var r=o(t.slice(1),6),e=r[0],i=r[1],u=r[2],c=void 0===u?"":u,a=r[3],s=r[4],f=void 0===s?"":s,h="",l=r[5],d=l.split("/");d.length>1&&(h=d.slice(0,-1).join("/"),l=d.pop()),this.O({host:a,pass:c,path:h,projectId:l,port:f,protocol:e,user:i})},n.prototype.O=function(n){this.protocol=n.protocol,this.user=n.user,this.pass=n.pass||"",this.host=n.host,this.port=n.port||"",this.path=n.path||"",this.projectId=n.projectId},n.prototype.T=function(){var n=this;if(["protocol","user","host","projectId"].forEach(function(t){if(!n[t])throw new v("Invalid Dsn")}),"http"!==this.protocol&&"https"!==this.protocol)throw new v("Invalid Dsn");if(this.port&&isNaN(parseInt(this.port,10)))throw new v("Invalid Dsn")},n}(),_n=function(){function n(){this.D=!1,this.R=[],this.N=[],this.I=[],this.C={},this.M={},this.A={},this.U={}}return n.prototype.addScopeListener=function(n){this.R.push(n)},n.prototype.addEventProcessor=function(n){return this.N.push(n),this},n.prototype.q=function(){var n=this;this.D||(this.D=!0,setTimeout(function(){n.R.forEach(function(t){t(n)}),n.D=!1}))},n.prototype.L=function(n,t,r,i){var o=this;return void 0===i&&(i=0),new rn(function(u,c){var a=n[i];if(null===t||"function"!=typeof a)u(t);else{var s=a(e({},t),r);E(s)?s.then(function(t){return o.L(n,t,r,i+1).then(u)}).then(null,c):o.L(n,s,r,i+1).then(u).then(null,c)}})},n.prototype.setUser=function(n){return this.C=n||{},this.q(),this},n.prototype.setTags=function(n){return this.M=e({},this.M,n),this.q(),this},n.prototype.setTag=function(n,t){var r;return this.M=e({},this.M,((r={})[n]=t,r)),this.q(),this},n.prototype.setExtras=function(n){return this.A=e({},this.A,n),this.q(),this},n.prototype.setExtra=function(n,t){var r;return this.A=e({},this.A,((r={})[n]=t,r)),this.q(),this},n.prototype.setFingerprint=function(n){return this.H=n,this.q(),this},n.prototype.setLevel=function(n){return this.P=n,this.q(),this},n.prototype.setTransaction=function(n){return this.F=n,this.W&&(this.W.transaction=n),this.q(),this},n.prototype.setContext=function(n,t){var r;return this.U=e({},this.U,((r={})[n]=t,r)),this.q(),this},n.prototype.setSpan=function(n){return this.W=n,this.q(),this},n.prototype.getSpan=function(){return this.W},n.clone=function(t){var r=new n;return t&&(r.I=u(t.I),r.M=e({},t.M),r.A=e({},t.A),r.U=e({},t.U),r.C=t.C,r.P=t.P,r.W=t.W,r.F=t.F,r.H=t.H,r.N=u(t.N)),r},n.prototype.clear=function(){return this.I=[],this.M={},this.A={},this.C={},this.U={},this.P=void 0,this.F=void 0,this.H=void 0,this.W=void 0,this.q(),this},n.prototype.addBreadcrumb=function(n,t){var r=e({timestamp:q()},n);return this.I=void 0!==t&&t>=0?u(this.I,[r]).slice(-t):u(this.I,[r]),this.q(),this},n.prototype.clearBreadcrumbs=function(){return this.I=[],this.q(),this},n.prototype.X=function(n){n.fingerprint=n.fingerprint?Array.isArray(n.fingerprint)?n.fingerprint:[n.fingerprint]:[],this.H&&(n.fingerprint=n.fingerprint.concat(this.H)),n.fingerprint&&!n.fingerprint.length&&delete n.fingerprint},n.prototype.applyToEvent=function(n,t){return this.A&&Object.keys(this.A).length&&(n.extra=e({},this.A,n.extra)),this.M&&Object.keys(this.M).length&&(n.tags=e({},this.M,n.tags)),this.C&&Object.keys(this.C).length&&(n.user=e({},this.C,n.user)),this.U&&Object.keys(this.U).length&&(n.contexts=e({},this.U,n.contexts)),this.P&&(n.level=this.P),this.F&&(n.transaction=this.F),this.X(n),n.breadcrumbs=u(n.breadcrumbs||[],this.I),n.breadcrumbs=n.breadcrumbs.length>0?n.breadcrumbs:void 0,this.L(u(Sn(),this.N),n,t)},n}();function Sn(){var n=T();return n.__SENTRY__=n.__SENTRY__||{},n.__SENTRY__.globalEventProcessors=n.__SENTRY__.globalEventProcessors||[],n.__SENTRY__.globalEventProcessors}function On(n){Sn().push(n)}var Tn=3,Dn=function(){function n(n,t,r){void 0===t&&(t=new _n),void 0===r&&(r=Tn),this.B=r,this.$=[],this.$.push({client:n,scope:t})}return n.prototype.G=function(n){for(var t,r=[],e=1;e<arguments.length;e++)r[e-1]=arguments[e];var i=this.getStackTop();i&&i.client&&i.client[n]&&(t=i.client)[n].apply(t,u(r,[i.scope]))},n.prototype.isOlderThan=function(n){return this.B<n},n.prototype.bindClient=function(n){this.getStackTop().client=n},n.prototype.pushScope=function(){var n=this.getStack(),t=n.length>0?n[n.length-1].scope:void 0,r=_n.clone(t);return this.getStack().push({client:this.getClient(),scope:r}),r},n.prototype.popScope=function(){return void 0!==this.getStack().pop()},n.prototype.withScope=function(n){var t=this.pushScope();try{n(t)}finally{this.popScope()}},n.prototype.getClient=function(){return this.getStackTop().client},n.prototype.getScope=function(){return this.getStackTop().scope},n.prototype.getStack=function(){return this.$},n.prototype.getStackTop=function(){return this.$[this.$.length-1]},n.prototype.captureException=function(n,t){var r=this.J=D(),i=t;if(!t){var o=void 0;try{throw new Error("Sentry syntheticException")}catch(n){o=n}i={originalException:n,syntheticException:o}}return this.G("captureException",n,e({},i,{event_id:r})),r},n.prototype.captureMessage=function(n,t,r){var i=this.J=D(),o=r;if(!r){var u=void 0;try{throw new Error(n)}catch(n){u=n}o={originalException:n,syntheticException:u}}return this.G("captureMessage",n,t,e({},o,{event_id:i})),i},n.prototype.captureEvent=function(n,t){var r=this.J=D();return this.G("captureEvent",n,e({},t,{event_id:r})),r},n.prototype.lastEventId=function(){return this.J},n.prototype.addBreadcrumb=function(n,t){var r=this.getStackTop();if(r.scope&&r.client){var i=r.client.getOptions&&r.client.getOptions()||{},o=i.beforeBreadcrumb,u=void 0===o?null:o,c=i.maxBreadcrumbs,a=void 0===c?100:c;if(!(a<=0)){var s=q(),f=e({timestamp:s},n),h=u?I(function(){return u(f,t)}):f;null!==h&&r.scope.addBreadcrumb(h,Math.min(a,100))}}},n.prototype.setUser=function(n){var t=this.getStackTop();t.scope&&t.scope.setUser(n)},n.prototype.setTags=function(n){var t=this.getStackTop();t.scope&&t.scope.setTags(n)},n.prototype.setExtras=function(n){var t=this.getStackTop();t.scope&&t.scope.setExtras(n)},n.prototype.setTag=function(n,t){var r=this.getStackTop();r.scope&&r.scope.setTag(n,t)},n.prototype.setExtra=function(n,t){var r=this.getStackTop();r.scope&&r.scope.setExtra(n,t)},n.prototype.setContext=function(n,t){var r=this.getStackTop();r.scope&&r.scope.setContext(n,t)},n.prototype.configureScope=function(n){var t=this.getStackTop();t.scope&&t.client&&n(t.scope)},n.prototype.run=function(n){var t=Nn(this);try{n(this)}finally{Nn(t)}},n.prototype.getIntegration=function(n){var t=this.getClient();if(!t)return null;try{return t.getIntegration(n)}catch(t){return G.warn("Cannot retrieve integration "+n.id+" from the current Hub"),null}},n.prototype.startSpan=function(n,t){return void 0===t&&(t=!1),this.V("startSpan",n,t)},n.prototype.traceHeaders=function(){return this.V("traceHeaders")},n.prototype.V=function(n){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];var e=Rn().__SENTRY__;if(e&&e.extensions&&"function"==typeof e.extensions[n])return e.extensions[n].apply(this,t);G.warn("Extension method "+n+" couldn't be found, doing nothing.")},n}();function Rn(){var n=T();return n.__SENTRY__=n.__SENTRY__||{extensions:{},hub:void 0},n}function Nn(n){var t=Rn(),r=Mn(t);return An(t,n),r}function In(){var n=Rn();return Cn(n)&&!Mn(n).isOlderThan(Tn)||An(n,new Dn),S()?function(n){try{var t=(i=module,o="domain",i.require(o)),r=t.active;if(!r)return Mn(n);if(!Cn(r)||Mn(r).isOlderThan(Tn)){var e=Mn(n).getStackTop();An(r,new Dn(e.client,_n.clone(e.scope)))}return Mn(r)}catch(t){return Mn(n)}var i,o}(n):Mn(n)}function Cn(n){return!!(n&&n.__SENTRY__&&n.__SENTRY__.hub)}function Mn(n){return n&&n.__SENTRY__&&n.__SENTRY__.hub?n.__SENTRY__.hub:(n.__SENTRY__=n.__SENTRY__||{},n.__SENTRY__.hub=new Dn,n.__SENTRY__.hub)}function An(n,t){return!!n&&(n.__SENTRY__=n.__SENTRY__||{},n.__SENTRY__.hub=t,!0)}function Un(n){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];var e=In();if(e&&e[n])return e[n].apply(e,u(t));throw new Error("No hub defined or "+n+" was not found on the hub, please open a bug report.")}function captureException(n){var t;try{throw new Error("Sentry syntheticException")}catch(n){t=n}return Un("captureException",n,{originalException:n,syntheticException:t})}function qn(n){Un("withScope",n)}var Ln=function(){function n(n){this.dsn=n,this.K=new kn(n)}return n.prototype.getDsn=function(){return this.K},n.prototype.getStoreEndpoint=function(){return""+this.Y()+this.getStoreEndpointPath()},n.prototype.getStoreEndpointWithUrlEncodedAuth=function(){var n,t={sentry_key:this.K.user,sentry_version:"7"};return this.getStoreEndpoint()+"?"+(n=t,Object.keys(n).map(function(t){return encodeURIComponent(t)+"="+encodeURIComponent(n[t])}).join("&"))},n.prototype.Y=function(){var n=this.K,t=n.protocol?n.protocol+":":"",r=n.port?":"+n.port:"";return t+"//"+n.host+r},n.prototype.getStoreEndpointPath=function(){var n=this.K;return(n.path?"/"+n.path:"")+"/api/"+n.projectId+"/store/"},n.prototype.getRequestHeaders=function(n,t){var r=this.K,e=["Sentry sentry_version=7"];return e.push("sentry_client="+n+"/"+t),e.push("sentry_key="+r.user),r.pass&&e.push("sentry_secret="+r.pass),{"Content-Type":"application/json","X-Sentry-Auth":e.join(", ")}},n.prototype.getReportDialogEndpoint=function(n){void 0===n&&(n={});var t=this.K,r=this.Y()+(t.path?"/"+t.path:"")+"/api/embed/error-page/",e=[];for(var i in e.push("dsn="+t.toString()),n)if("user"===i){if(!n.user)continue;n.user.name&&e.push("name="+encodeURIComponent(n.user.name)),n.user.email&&e.push("email="+encodeURIComponent(n.user.email))}else e.push(encodeURIComponent(i)+"="+encodeURIComponent(n[i]));return e.length?r+"?"+e.join("&"):r},n}(),Hn=[];function Pn(n){var t={};return function(n){var t=n.defaultIntegrations&&u(n.defaultIntegrations)||[],r=n.integrations,e=[];if(Array.isArray(r)){var i=r.map(function(n){return n.name}),o=[];t.forEach(function(n){-1===i.indexOf(n.name)&&-1===o.indexOf(n.name)&&(e.push(n),o.push(n.name))}),r.forEach(function(n){-1===o.indexOf(n.name)&&(e.push(n),o.push(n.name))})}else"function"==typeof r?(e=r(t),e=Array.isArray(e)?e:[e]):e=u(t);var c=e.map(function(n){return n.name});return-1!==c.indexOf("Debug")&&e.push.apply(e,u(e.splice(c.indexOf("Debug"),1))),e}(n).forEach(function(n){t[n.name]=n,function(n){-1===Hn.indexOf(n.name)&&(n.setupOnce(On,In),Hn.push(n.name),G.log("Integration installed: "+n.name))}(n)}),t}var Fn,Wn=function(){function n(n,t){this.Z={},this.nn=!1,this.tn=new n(t),this.rn=t,t.dsn&&(this.en=new kn(t.dsn)),this.in()&&(this.Z=Pn(this.rn))}return n.prototype.captureException=function(n,t,r){var e=this,i=t&&t.event_id;return this.nn=!0,this.on().eventFromException(n,t).then(function(n){return e.un(n,t,r)}).then(function(n){i=n&&n.event_id,e.nn=!1}).then(null,function(n){G.error(n),e.nn=!1}),i},n.prototype.captureMessage=function(n,t,r,e){var i=this,o=r&&r.event_id;return this.nn=!0,(m(n)?this.on().eventFromMessage(""+n,t,r):this.on().eventFromException(n,r)).then(function(n){return i.un(n,r,e)}).then(function(n){o=n&&n.event_id,i.nn=!1}).then(null,function(n){G.error(n),i.nn=!1}),o},n.prototype.captureEvent=function(n,t,r){var e=this,i=t&&t.event_id;return this.nn=!0,this.un(n,t,r).then(function(n){i=n&&n.event_id,e.nn=!1}).then(null,function(n){G.error(n),e.nn=!1}),i},n.prototype.getDsn=function(){return this.en},n.prototype.getOptions=function(){return this.rn},n.prototype.flush=function(n){var t=this;return this.cn(n).then(function(r){return clearInterval(r.interval),t.on().getTransport().close(n).then(function(n){return r.ready&&n})})},n.prototype.close=function(n){var t=this;return this.flush(n).then(function(n){return t.getOptions().enabled=!1,n})},n.prototype.getIntegrations=function(){return this.Z||{}},n.prototype.getIntegration=function(n){try{return this.Z[n.id]||null}catch(t){return G.warn("Cannot retrieve integration "+n.id+" from the current Client"),null}},n.prototype.cn=function(n){var t=this;return new rn(function(r){var e=0,i=0;clearInterval(i),i=setInterval(function(){t.nn?(e+=1,n&&e>=n&&r({interval:i,ready:!1})):r({interval:i,ready:!0})},1)})},n.prototype.on=function(){return this.tn},n.prototype.in=function(){return!1!==this.getOptions().enabled&&void 0!==this.en},n.prototype.an=function(n,t,r){var i=this,o=this.getOptions(),u=o.environment,c=o.release,a=o.dist,s=o.maxValueLength,f=void 0===s?250:s,h=o.normalizeDepth,v=void 0===h?3:h,l=e({},n);void 0===l.environment&&void 0!==u&&(l.environment=u),void 0===l.release&&void 0!==c&&(l.release=c),void 0===l.dist&&void 0!==a&&(l.dist=a),l.message&&(l.message=j(l.message,f));var d=l.exception&&l.exception.values&&l.exception.values[0];d&&d.value&&(d.value=j(d.value,f));var p=l.request;p&&p.url&&(p.url=j(p.url,f)),void 0===l.event_id&&(l.event_id=r&&r.event_id?r.event_id:D()),this.sn(l.sdk);var y=rn.resolve(l);return t&&(y=t.applyToEvent(l,r)),y.then(function(n){return"number"==typeof v&&v>0?i.fn(n,v):n})},n.prototype.fn=function(n,t){return n?e({},n,n.breadcrumbs&&{breadcrumbs:n.breadcrumbs.map(function(n){return e({},n,n.data&&{data:nn(n.data,t)})})},n.user&&{user:nn(n.user,t)},n.contexts&&{contexts:nn(n.contexts,t)},n.extra&&{extra:nn(n.extra,t)}):null},n.prototype.sn=function(n){var t=Object.keys(this.Z);n&&t.length>0&&(n.integrations=t)},n.prototype.un=function(n,t,r){var e=this,i=this.getOptions(),o=i.beforeSend,u=i.sampleRate;return this.in()?"number"==typeof u&&Math.random()>u?rn.reject("This event has been sampled, will not send event."):new rn(function(i,u){e.an(n,r,t).then(function(n){if(null!==n){var r=n;if(t&&t.data&&!0===t.data.__sentry__||!o)return e.on().sendEvent(r),void i(r);var c=o(n,t);if(void 0===c)G.error("`beforeSend` method has to return `null` or a valid event.");else if(E(c))e.hn(c,i,u);else{if(null===(r=c))return G.log("`beforeSend` returned `null`, will not send event."),void i(null);e.on().sendEvent(r),i(r)}}else u("An event processor returned null, will not send event.")}).then(null,function(n){e.captureException(n,{data:{__sentry__:!0},originalException:n}),u("Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: "+n)})}):rn.reject("SDK not enabled, will not send event.")},n.prototype.hn=function(n,t,r){var e=this;n.then(function(n){null!==n?(e.on().sendEvent(n),t(n)):r("`beforeSend` returned `null`, will not send event.")}).then(null,function(n){r("beforeSend rejected with "+n)})},n}(),Xn=function(){function t(){}return t.prototype.sendEvent=function(t){return rn.resolve({reason:"NoopTransport: Event has been skipped because no Dsn is configured.",status:n.Status.Skipped})},t.prototype.close=function(n){return rn.resolve(!0)},t}(),Bn=function(){function n(n){this.rn=n,this.rn.dsn||G.warn("No DSN provided, backend will not do anything."),this.vn=this.ln()}return n.prototype.ln=function(){return new Xn},n.prototype.eventFromException=function(n,t){throw new v("Backend has to implement `eventFromException` method")},n.prototype.eventFromMessage=function(n,t,r){throw new v("Backend has to implement `eventFromMessage` method")},n.prototype.sendEvent=function(n){this.vn.sendEvent(n).then(null,function(n){G.error("Error while sending event: "+n)})},n.prototype.getTransport=function(){return this.vn},n}();var $n=function(){function n(){this.name=n.id}return n.prototype.setupOnce=function(){Fn=Function.prototype.toString,Function.prototype.toString=function(){for(var n=[],t=0;t<arguments.length;t++)n[t]=arguments[t];var r=this.__sentry_original__||this;return Fn.apply(r,n)}},n.id="FunctionToString",n}(),Gn=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/],Jn=function(){function n(t){void 0===t&&(t={}),this.rn=t,this.name=n.id}return n.prototype.setupOnce=function(){On(function(t){var r=In();if(!r)return t;var e=r.getIntegration(n);if(e){var i=r.getClient(),o=i?i.getOptions():{},u=e.dn(o);if(e.pn(t,u))return null}return t})},n.prototype.pn=function(n,t){return this.yn(n,t)?(G.warn("Event dropped due to being internal Sentry Error.\nEvent: "+N(n)),!0):this.mn(n,t)?(G.warn("Event dropped due to being matched by `ignoreErrors` option.\nEvent: "+N(n)),!0):this.bn(n,t)?(G.warn("Event dropped due to being matched by `blacklistUrls` option.\nEvent: "+N(n)+".\nUrl: "+this.wn(n)),!0):!this.gn(n,t)&&(G.warn("Event dropped due to not being matched by `whitelistUrls` option.\nEvent: "+N(n)+".\nUrl: "+this.wn(n)),!0)},n.prototype.yn=function(n,t){if(void 0===t&&(t={}),!t.ignoreInternal)return!1;try{return n&&n.exception&&n.exception.values&&n.exception.values[0]&&"SentryError"===n.exception.values[0].type||!1}catch(n){return!1}},n.prototype.mn=function(n,t){return void 0===t&&(t={}),!(!t.ignoreErrors||!t.ignoreErrors.length)&&this.En(n).some(function(n){return t.ignoreErrors.some(function(t){return _(n,t)})})},n.prototype.bn=function(n,t){if(void 0===t&&(t={}),!t.blacklistUrls||!t.blacklistUrls.length)return!1;var r=this.wn(n);return!!r&&t.blacklistUrls.some(function(n){return _(r,n)})},n.prototype.gn=function(n,t){if(void 0===t&&(t={}),!t.whitelistUrls||!t.whitelistUrls.length)return!0;var r=this.wn(n);return!r||t.whitelistUrls.some(function(n){return _(r,n)})},n.prototype.dn=function(n){return void 0===n&&(n={}),{blacklistUrls:u(this.rn.blacklistUrls||[],n.blacklistUrls||[]),ignoreErrors:u(this.rn.ignoreErrors||[],n.ignoreErrors||[],Gn),ignoreInternal:void 0===this.rn.ignoreInternal||this.rn.ignoreInternal,whitelistUrls:u(this.rn.whitelistUrls||[],n.whitelistUrls||[])}},n.prototype.En=function(n){if(n.message)return[n.message];if(n.exception)try{var t=n.exception.values&&n.exception.values[0]||{},r=t.type,e=void 0===r?"":r,i=t.value,o=void 0===i?"":i;return[""+o,e+": "+o]}catch(t){return G.error("Cannot extract message for event "+N(n)),[]}return[]},n.prototype.wn=function(n){try{if(n.stacktrace){var t=n.stacktrace.frames;return t&&t[t.length-1].filename||null}if(n.exception){var r=n.exception.values&&n.exception.values[0].stacktrace&&n.exception.values[0].stacktrace.frames;return r&&r[r.length-1].filename||null}return null}catch(t){return G.error("Cannot extract url for event "+N(n)),null}},n.id="InboundFilters",n}(),zn=Object.freeze({FunctionToString:$n,InboundFilters:Jn}),Vn="?",Kn=/^\s*at (?:(.*?) ?\()?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,Qn=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js))(?::(\d+))?(?::(\d+))?\s*$/i,Yn=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,Zn=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,nt=/\((\S*)(?::(\d+))(?::(\d+))\)/;function tt(n){var t=null,r=n&&n.framesToPop;try{if(t=function(n){if(!n||!n.stacktrace)return null;for(var t,r=n.stacktrace,e=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,i=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^\)]+))\((.*)\))? in (.*):\s*$/i,o=r.split("\n"),u=[],c=0;c<o.length;c+=2){var a=null;(t=e.exec(o[c]))?a={url:t[2],func:t[3],args:[],line:+t[1],column:null}:(t=i.exec(o[c]))&&(a={url:t[6],func:t[3]||t[4],args:t[5]?t[5].split(","):[],line:+t[1],column:+t[2]}),a&&(!a.func&&a.line&&(a.func=Vn),u.push(a))}if(!u.length)return null;return{message:et(n),name:n.name,stack:u}}(n))return rt(t,r)}catch(n){}try{if(t=function(n){if(!n||!n.stack)return null;for(var t,r,e,i=[],o=n.stack.split("\n"),u=0;u<o.length;++u){if(r=Kn.exec(o[u])){var c=r[2]&&0===r[2].indexOf("native");r[2]&&0===r[2].indexOf("eval")&&(t=nt.exec(r[2]))&&(r[2]=t[1],r[3]=t[2],r[4]=t[3]),e={url:r[2]&&0===r[2].indexOf("address at ")?r[2].substr("address at ".length):r[2],func:r[1]||Vn,args:c?[r[2]]:[],line:r[3]?+r[3]:null,column:r[4]?+r[4]:null}}else if(r=Yn.exec(o[u]))e={url:r[2],func:r[1]||Vn,args:[],line:+r[3],column:r[4]?+r[4]:null};else{if(!(r=Qn.exec(o[u])))continue;r[3]&&r[3].indexOf(" > eval")>-1&&(t=Zn.exec(r[3]))?(r[1]=r[1]||"eval",r[3]=t[1],r[4]=t[2],r[5]=""):0!==u||r[5]||void 0===n.columnNumber||(i[0].column=n.columnNumber+1),e={url:r[3],func:r[1]||Vn,args:r[2]?r[2].split(","):[],line:r[4]?+r[4]:null,column:r[5]?+r[5]:null}}!e.func&&e.line&&(e.func=Vn),i.push(e)}if(!i.length)return null;return{message:et(n),name:n.name,stack:i}}(n))return rt(t,r)}catch(n){}return{message:et(n),name:n&&n.name,stack:[],failed:!0}}function rt(n,t){try{return e({},n,{stack:n.stack.slice(t)})}catch(t){return n}}function et(n){var t=n&&n.message;return t?t.error&&"string"==typeof t.error.message?t.error.message:t:"No error message"}var it=50;function ot(n){var t=ct(n.stack),r={type:n.name,value:n.message};return t&&t.length&&(r.stacktrace={frames:t}),void 0===r.type&&""===r.value&&(r.value="Unrecoverable error caught"),r}function ut(n){return{exception:{values:[ot(n)]}}}function ct(n){if(!n||!n.length)return[];var t=n,r=t[0].func||"",e=t[t.length-1].func||"";return-1===r.indexOf("captureMessage")&&-1===r.indexOf("captureException")||(t=t.slice(1)),-1!==e.indexOf("sentryWrapped")&&(t=t.slice(0,-1)),t.map(function(n){return{colno:null===n.column?void 0:n.column,filename:n.url||t[0].url,function:n.func||"?",in_app:!0,lineno:null===n.line?void 0:n.line}}).slice(0,it).reverse()}function at(n,t,r){var e,i;if(void 0===r&&(r={}),d(n)&&n.error)return e=ut(tt(n=n.error));if(p(n)||(i=n,"[object DOMException]"===Object.prototype.toString.call(i))){var o=n,u=o.name||(p(o)?"DOMError":"DOMException"),c=o.message?u+": "+o.message:u;return C(e=st(c,t,r),c),e}return l(n)?e=ut(tt(n)):b(n)||w(n)?(M(e=function(n,t,r){var e={exception:{values:[{type:w(n)?n.constructor.name:r?"UnhandledRejection":"Error",value:"Non-Error "+(r?"promise rejection":"exception")+" captured with keys: "+tn(n)}]},extra:{__serialized__:Q(n)}};if(t){var i=ct(tt(t).stack);e.stacktrace={frames:i}}return e}(n,t,r.rejection),{synthetic:!0}),e):(C(e=st(n,t,r),""+n,void 0),M(e,{synthetic:!0}),e)}function st(n,t,r){void 0===r&&(r={});var e={message:n};if(r.attachStacktrace&&t){var i=ct(tt(t).stack);e.stacktrace={frames:i}}return e}var ft=function(){function n(n){this.options=n,this._=new en(30),this.url=new Ln(this.options.dsn).getStoreEndpointWithUrlEncodedAuth()}return n.prototype.sendEvent=function(n){throw new v("Transport Class has to implement `sendEvent` method")},n.prototype.close=function(n){return this._.drain(n)},n}(),ht=T(),vt=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.xn=new Date(Date.now()),n}return r(e,t),e.prototype.sendEvent=function(t){var r=this;if(new Date(Date.now())<this.xn)return Promise.reject({event:t,reason:"Transport locked till "+this.xn+" due to too many requests.",status:429});var e={body:JSON.stringify(t),method:"POST",referrerPolicy:cn()?"origin":""};return void 0!==this.options.headers&&(e.headers=this.options.headers),this._.add(new rn(function(t,i){ht.fetch(r.url,e).then(function(e){var o=n.Status.fromHttpCode(e.status);if(o!==n.Status.Success){if(o===n.Status.RateLimit){var u=Date.now();r.xn=new Date(u+H(u,e.headers.get("Retry-After"))),G.warn("Too many requests, backing off till: "+r.xn)}i(e)}else t({status:o})}).catch(i)}))},e}(ft),lt=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.xn=new Date(Date.now()),n}return r(e,t),e.prototype.sendEvent=function(t){var r=this;return new Date(Date.now())<this.xn?Promise.reject({event:t,reason:"Transport locked till "+this.xn+" due to too many requests.",status:429}):this._.add(new rn(function(e,i){var o=new XMLHttpRequest;for(var u in o.onreadystatechange=function(){if(4===o.readyState){var t=n.Status.fromHttpCode(o.status);if(t!==n.Status.Success){if(t===n.Status.RateLimit){var u=Date.now();r.xn=new Date(u+H(u,o.getResponseHeader("Retry-After"))),G.warn("Too many requests, backing off till: "+r.xn)}i(o)}else e({status:t})}},o.open("POST",r.url),r.options.headers)r.options.headers.hasOwnProperty(u)&&o.setRequestHeader(u,r.options.headers[u]);o.send(JSON.stringify(t))}))},e}(ft),dt=Object.freeze({BaseTransport:ft,FetchTransport:vt,XHRTransport:lt}),pt=function(t){function i(){return null!==t&&t.apply(this,arguments)||this}return r(i,t),i.prototype.ln=function(){if(!this.rn.dsn)return t.prototype.ln.call(this);var n=e({},this.rn.transportOptions,{dsn:this.rn.dsn});return this.rn.transport?new this.rn.transport(n):on()?new vt(n):new lt(n)},i.prototype.eventFromException=function(t,r){var e=at(t,r&&r.syntheticException||void 0,{attachStacktrace:this.rn.attachStacktrace});return M(e,{handled:!0,type:"generic"}),e.level=n.Severity.Error,r&&r.event_id&&(e.event_id=r.event_id),rn.resolve(e)},i.prototype.eventFromMessage=function(t,r,e){void 0===r&&(r=n.Severity.Info);var i=st(t,e&&e.syntheticException||void 0,{attachStacktrace:this.rn.attachStacktrace});return i.level=r,e&&e.event_id&&(i.event_id=e.event_id),rn.resolve(i)},i}(Bn),yt="sentry.javascript.browser",mt=function(n){function t(t){return void 0===t&&(t={}),n.call(this,pt,t)||this}return r(t,n),t.prototype.an=function(t,r,i){return t.platform=t.platform||"javascript",t.sdk=e({},t.sdk,{name:yt,packages:u(t.sdk&&t.sdk.packages||[],[{name:"npm:@sentry/browser",version:"5.13.2"}]),version:"5.13.2"}),n.prototype.an.call(this,t,r,i)},t.prototype.showReportDialog=function(n){void 0===n&&(n={});var t=T().document;if(t)if(this.in()){var r=n.dsn||this.getDsn();if(n.eventId)if(r){var e=t.createElement("script");e.async=!0,e.src=new Ln(r).getReportDialogEndpoint(n),n.onLoad&&(e.onload=n.onLoad),(t.head||t.body).appendChild(e)}else G.error("Missing `Dsn` option in showReportDialog call");else G.error("Missing `eventId` option in showReportDialog call")}else G.error("Trying to call showReportDialog with Sentry Client is disabled")},t}(Wn),bt=0;function wt(){return bt>0}function gt(n,t,r){if(void 0===t&&(t={}),"function"!=typeof n)return n;try{if(n.__sentry__)return n;if(n.__sentry_wrapped__)return n.__sentry_wrapped__}catch(t){return n}var sentryWrapped=function(){var i=Array.prototype.slice.call(arguments);try{r&&"function"==typeof r&&r.apply(this,arguments);var o=i.map(function(n){return gt(n,t)});return n.handleEvent?n.handleEvent.apply(this,o):n.apply(this,o)}catch(n){throw bt+=1,setTimeout(function(){bt-=1}),qn(function(r){r.addEventProcessor(function(n){var r=e({},n);return t.mechanism&&(C(r,void 0,void 0),M(r,t.mechanism)),r.extra=e({},r.extra,{arguments:i}),r}),captureException(n)}),n}};try{for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(sentryWrapped[i]=n[i])}catch(n){}n.prototype=n.prototype||{},sentryWrapped.prototype=n.prototype,Object.defineProperty(n,"__sentry_wrapped__",{enumerable:!1,value:sentryWrapped}),Object.defineProperties(sentryWrapped,{__sentry__:{enumerable:!1,value:!0},__sentry_original__:{enumerable:!1,value:n}});try{Object.getOwnPropertyDescriptor(sentryWrapped,"name").configurable&&Object.defineProperty(sentryWrapped,"name",{get:function(){return n.name}})}catch(n){}return sentryWrapped}var Et=function(){function t(n){this.name=t.id,this.jn=T(),this.kn=null,this._n=null,this.Sn=!1,this.On=!1,this.rn=e({onerror:!0,onunhandledrejection:!0},n)}return t.prototype.setupOnce=function(){Error.stackTraceLimit=50,this.rn.onerror&&(G.log("Global Handler attached: onerror"),this.Tn()),this.rn.onunhandledrejection&&(G.log("Global Handler attached: onunhandledrejection"),this.Dn())},t.prototype.Tn=function(){if(!this.Sn){var n=this;this.kn=this.jn.onerror,this.jn.onerror=function(r,e,i,o,u){var c=In(),a=c.getIntegration(t),s=u&&!0===u.__sentry_own_request__;if(!a||wt()||s)return!!n.kn&&n.kn.apply(this,arguments);var f=c.getClient(),h=m(u)?n.Rn(r,e,i,o):n.Nn(at(u,void 0,{attachStacktrace:f&&f.getOptions().attachStacktrace,rejection:!1}),e,i,o);return M(h,{handled:!1,type:"onerror"}),c.captureEvent(h,{originalException:u}),!!n.kn&&n.kn.apply(this,arguments)},this.Sn=!0}},t.prototype.Dn=function(){if(!this.On){var r=this;this._n=this.jn.onunhandledrejection,this.jn.onunhandledrejection=function(e){var i=e;try{"reason"in e?i=e.reason:"detail"in e&&"reason"in e.detail&&(i=e.detail.reason)}catch(n){}var o=In(),u=o.getIntegration(t),c=i&&!0===i.__sentry_own_request__;if(!u||wt()||c)return!r._n||r._n.apply(this,arguments);var a=o.getClient(),s=m(i)?r.In(i):at(i,void 0,{attachStacktrace:a&&a.getOptions().attachStacktrace,rejection:!0});return s.level=n.Severity.Error,M(s,{handled:!1,type:"onunhandledrejection"}),o.captureEvent(s,{originalException:i}),!r._n||r._n.apply(this,arguments)},this.On=!0}},t.prototype.Rn=function(n,t,r,e){var i,o=d(n)?n.message:n;if(y(o)){var u=o.match(/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i);u&&(i=u[1],o=u[2])}var c={exception:{values:[{type:i||"Error",value:o}]}};return this.Nn(c,t,r,e)},t.prototype.In=function(n){return{exception:{values:[{type:"UnhandledRejection",value:"Non-Error promise rejection captured with value: "+n}]}}},t.prototype.Nn=function(n,t,r,e){n.exception=n.exception||{},n.exception.values=n.exception.values||[],n.exception.values[0]=n.exception.values[0]||{},n.exception.values[0].stacktrace=n.exception.values[0].stacktrace||{},n.exception.values[0].stacktrace.frames=n.exception.values[0].stacktrace.frames||[];var i=isNaN(parseInt(e,10))?void 0:e,o=isNaN(parseInt(r,10))?void 0:r,u=y(t)&&t.length>0?t:function(){try{return document.location.href}catch(n){return""}}();return 0===n.exception.values[0].stacktrace.frames.length&&n.exception.values[0].stacktrace.frames.push({colno:i,filename:u,function:"?",in_app:!0,lineno:o}),n},t.id="GlobalHandlers",t}(),xt=function(){function n(){this.Cn=0,this.name=n.id}return n.prototype.Mn=function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var e=t[0];return t[0]=gt(e,{mechanism:{data:{function:F(n)},handled:!0,type:"instrument"}}),n.apply(this,t)}},n.prototype.An=function(n){return function(t){return n(gt(t,{mechanism:{data:{function:"requestAnimationFrame",handler:F(n)},handled:!0,type:"instrument"}}))}},n.prototype.Un=function(n){var t=T(),r=t[n]&&t[n].prototype;r&&r.hasOwnProperty&&r.hasOwnProperty("addEventListener")&&(z(r,"addEventListener",function(t){return function(r,e,i){try{"function"==typeof e.handleEvent&&(e.handleEvent=gt(e.handleEvent.bind(e),{mechanism:{data:{function:"handleEvent",handler:F(e),target:n},handled:!0,type:"instrument"}}))}catch(n){}return t.call(this,r,gt(e,{mechanism:{data:{function:"addEventListener",handler:F(e),target:n},handled:!0,type:"instrument"}}),i)}}),z(r,"removeEventListener",function(n){return function(t,r,e){var i=r;try{i=i&&(i.__sentry_wrapped__||i)}catch(n){}return n.call(this,t,i,e)}}))},n.prototype.qn=function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var e=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(function(n){n in e&&"function"==typeof e[n]&&z(e,n,function(t){var r={mechanism:{data:{function:n,handler:F(t)},handled:!0,type:"instrument"}};return t.__sentry_original__&&(r.mechanism.data.handler=F(t.__sentry_original__)),gt(t,r)})}),n.apply(this,t)}},n.prototype.setupOnce=function(){this.Cn=this.Cn;var n=T();z(n,"setTimeout",this.Mn.bind(this)),z(n,"setInterval",this.Mn.bind(this)),z(n,"requestAnimationFrame",this.An.bind(this)),"XMLHttpRequest"in n&&z(XMLHttpRequest.prototype,"send",this.qn.bind(this)),["EventTarget","Window","Node","ApplicationCache","AudioTrackList","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"].forEach(this.Un.bind(this))},n.id="TryCatch",n}(),jt=function(){function t(n){this.name=t.id,this.rn=e({console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0},n)}return t.prototype.Ln=function(t){var r={category:"console",data:{arguments:t.args,logger:"console"},level:n.Severity.fromString(t.level),message:k(t.args," ")};if("assert"===t.level){if(!1!==t.args[0])return;r.message="Assertion failed: "+(k(t.args.slice(1)," ")||"console.assert"),r.data.arguments=t.args.slice(1)}In().addBreadcrumb(r,{input:t.args,level:t.level})},t.prototype.Hn=function(n){var t;try{t=n.event.target?A(n.event.target):A(n.event)}catch(n){t="<unknown>"}0!==t.length&&In().addBreadcrumb({category:"ui."+n.name,message:t},{event:n.event,name:n.name})},t.prototype.Pn=function(n){if(n.endTimestamp){if(n.xhr.__sentry_own_request__)return;In().addBreadcrumb({category:"xhr",data:n.xhr.__sentry_xhr__,type:"http"},{xhr:n.xhr})}else n.xhr.__sentry_own_request__&&kt(n.args[0])},t.prototype.Fn=function(t){if(t.endTimestamp){var r=In().getClient(),i=r&&r.getDsn();if(i){var o=new Ln(i).getStoreEndpoint();if(o&&-1!==t.fetchData.url.indexOf(o)&&"POST"===t.fetchData.method&&t.args[1]&&t.args[1].body)return void kt(t.args[1].body)}t.error?In().addBreadcrumb({category:"fetch",data:e({},t.fetchData,{status_code:t.response.status}),level:n.Severity.Error,type:"http"},{data:t.error,input:t.args}):In().addBreadcrumb({category:"fetch",data:e({},t.fetchData,{status_code:t.response.status}),type:"http"},{input:t.args,response:t.response})}},t.prototype.Wn=function(n){var t=T(),r=n.from,e=n.to,i=R(t.location.href),o=R(r),u=R(e);o.path||(o=i),i.protocol===u.protocol&&i.host===u.host&&(e=u.relative),i.protocol===o.protocol&&i.host===o.host&&(r=o.relative),In().addBreadcrumb({category:"navigation",data:{from:r,to:e}})},t.prototype.setupOnce=function(){var n=this;this.rn.console&&ln({callback:function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];n.Ln.apply(n,u(t))},type:"console"}),this.rn.dom&&ln({callback:function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];n.Hn.apply(n,u(t))},type:"dom"}),this.rn.xhr&&ln({callback:function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];n.Pn.apply(n,u(t))},type:"xhr"}),this.rn.fetch&&ln({callback:function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];n.Fn.apply(n,u(t))},type:"fetch"}),this.rn.history&&ln({callback:function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];n.Wn.apply(n,u(t))},type:"history"})},t.id="Breadcrumbs",t}();function kt(t){try{var r=JSON.parse(t);In().addBreadcrumb({category:"sentry."+("transaction"===r.type?"transaction":"event"),event_id:r.event_id,level:r.level||n.Severity.fromString("error"),message:N(r)},{event:r})}catch(n){G.error("Error while adding sentry type breadcrumb")}}var _t="cause",St=5,Ot=function(){function n(t){void 0===t&&(t={}),this.name=n.id,this.Xn=t.key||_t,this.k=t.limit||St}return n.prototype.setupOnce=function(){On(function(t,r){var e=In().getIntegration(n);return e?e.Bn(t,r):t})},n.prototype.Bn=function(n,t){if(!(n.exception&&n.exception.values&&t&&x(t.originalException,Error)))return n;var r=this.$n(t.originalException,this.Xn);return n.exception.values=u(r,n.exception.values),n},n.prototype.$n=function(n,t,r){if(void 0===r&&(r=[]),!x(n[t],Error)||r.length+1>=this.k)return r;var e=ot(tt(n[t]));return this.$n(n[t],t,u([e],r))},n.id="LinkedErrors",n}(),Tt=T(),Dt=function(){function n(){this.name=n.id}return n.prototype.setupOnce=function(){On(function(t){if(In().getIntegration(n)){if(!Tt.navigator||!Tt.location)return t;var r=t.request||{};return r.url=r.url||Tt.location.href,r.headers=r.headers||{},r.headers["User-Agent"]=Tt.navigator.userAgent,e({},t,{request:r})}return t})},n.id="UserAgent",n}(),Rt=Object.freeze({GlobalHandlers:Et,TryCatch:xt,Breadcrumbs:jt,LinkedErrors:Ot,UserAgent:Dt}),Nt=[new Jn,new $n,new xt,new jt,new Et,new Ot,new Dt];var It={},Ct=T();Ct.Sentry&&Ct.Sentry.Integrations&&(It=Ct.Sentry.Integrations);var Mt=e({},It,zn,Rt);return n.BrowserClient=mt,n.Hub=Dn,n.Integrations=Mt,n.SDK_NAME=yt,n.SDK_VERSION="5.13.2",n.Scope=_n,n.Transports=dt,n.addBreadcrumb=function(n){Un("addBreadcrumb",n)},n.addGlobalEventProcessor=On,n.captureEvent=function(n){return Un("captureEvent",n)},n.captureException=captureException,n.captureMessage=function(n,t){var r;try{throw new Error(n)}catch(n){r=n}return Un("captureMessage",n,t,{originalException:n,syntheticException:r})},n.close=function(n){var t=In().getClient();return t?t.close(n):rn.reject(!1)},n.configureScope=function(n){Un("configureScope",n)},n.defaultIntegrations=Nt,n.flush=function(n){var t=In().getClient();return t?t.flush(n):rn.reject(!1)},n.forceLoad=function(){},n.getCurrentHub=In,n.getHubFromCarrier=Mn,n.init=function(n){if(void 0===n&&(n={}),void 0===n.defaultIntegrations&&(n.defaultIntegrations=Nt),void 0===n.release){var t=T();t.SENTRY_RELEASE&&t.SENTRY_RELEASE.id&&(n.release=t.SENTRY_RELEASE.id)}!function(n,t){!0===t.debug&&G.enable(),In().bindClient(new n(t))}(mt,n)},n.lastEventId=function(){return In().lastEventId()},n.onLoad=function(n){n()},n.setContext=function(n,t){Un("setContext",n,t)},n.setExtra=function(n,t){Un("setExtra",n,t)},n.setExtras=function(n){Un("setExtras",n)},n.setTag=function(n,t){Un("setTag",n,t)},n.setTags=function(n){Un("setTags",n)},n.setUser=function(n){Un("setUser",n)},n.showReportDialog=function(n){void 0===n&&(n={}),n.eventId||(n.eventId=In().lastEventId());var t=In().getClient();t&&t.showReportDialog(n)},n.withScope=qn,n.wrap=function(n){return gt(n)()},n}({});
|
|
//# sourceMappingURL=bundle.min.js.map
|