@cloudflare/vite-plugin 0.0.0-53e63233c → 0.0.0-54c809450

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  // ../workers-shared/dist/asset-worker.mjs
2
- import { WorkerEntrypoint as mo } from "cloudflare:workers";
3
- var de = class {
2
+ import { WorkerEntrypoint as go } from "cloudflare:workers";
3
+ var X = class {
4
4
  constructor(e) {
5
5
  this.performanceTimer = e;
6
6
  }
@@ -8,81 +8,6 @@ var de = class {
8
8
  return this.performanceTimer ? this.performanceTimer.timeOrigin + this.performanceTimer.now() : Date.now();
9
9
  }
10
10
  };
11
- var it = class extends Response {
12
- constructor(e, n) {
13
- super(e, { ...n, status: it.status });
14
- }
15
- };
16
- var S = it;
17
- S.status = 200;
18
- var at = class extends Response {
19
- constructor(...[e, n]) {
20
- super(e, { ...n, status: at.status, statusText: "Not Found" });
21
- }
22
- };
23
- var D = at;
24
- D.status = 404;
25
- var fe = class extends D {
26
- constructor() {
27
- super();
28
- }
29
- };
30
- var ct = class extends Response {
31
- constructor(...[e, n]) {
32
- super(e, { ...n, status: ct.status, statusText: "Method Not Allowed" });
33
- }
34
- };
35
- var X = ct;
36
- X.status = 405;
37
- var ut = class extends Response {
38
- constructor(e, n) {
39
- super(null, { ...n, status: ut.status });
40
- }
41
- };
42
- var M = ut;
43
- M.status = 500;
44
- var lt = class extends Response {
45
- constructor(...[e, n]) {
46
- super(null, { ...n, status: lt.status, statusText: "Not Modified" });
47
- }
48
- };
49
- var Q = lt;
50
- Q.status = 304;
51
- var pt = class extends Response {
52
- constructor(e, n) {
53
- super(null, { ...n, status: pt.status, statusText: "Moved Permanently", headers: { ...n?.headers, Location: e } });
54
- }
55
- };
56
- var ee = pt;
57
- ee.status = 301;
58
- var dt = class extends Response {
59
- constructor(e, n) {
60
- super(null, { ...n, status: dt.status, statusText: "Found", headers: { ...n?.headers, Location: e } });
61
- }
62
- };
63
- var te = dt;
64
- te.status = 302;
65
- var ft = class extends Response {
66
- constructor(e, n) {
67
- super(null, { ...n, status: ft.status, statusText: "See Other", headers: { ...n?.headers, Location: e } });
68
- }
69
- };
70
- var ne = ft;
71
- ne.status = 303;
72
- var mt = class extends Response {
73
- constructor(e, n) {
74
- super(null, { ...n, status: mt.status, statusText: "Temporary Redirect", headers: { ...n?.headers, Location: e } });
75
- }
76
- };
77
- var F = mt;
78
- F.status = 307;
79
- var ht = class extends Response {
80
- constructor(e, n) {
81
- super(null, { ...n, status: ht.status, statusText: "Permanent Redirect", headers: { ...n?.headers, Location: e } });
82
- }
83
- };
84
- var re = ht;
85
- re.status = 308;
86
11
  var cn = Object.prototype.toString;
87
12
  function z(t) {
88
13
  switch (cn.call(t)) {
@@ -91,74 +16,74 @@ function z(t) {
91
16
  case "[object DOMException]":
92
17
  return true;
93
18
  default:
94
- return k(t, Error);
19
+ return M(t, Error);
95
20
  }
96
21
  }
97
- function gt(t, e) {
22
+ function it(t, e) {
98
23
  return cn.call(t) === `[object ${e}]`;
99
24
  }
100
- function _t(t) {
101
- return gt(t, "ErrorEvent");
25
+ function at(t) {
26
+ return it(t, "ErrorEvent");
102
27
  }
103
- function Et(t) {
104
- return gt(t, "String");
28
+ function ct(t) {
29
+ return it(t, "String");
105
30
  }
106
- function se(t) {
31
+ function Q(t) {
107
32
  return typeof t == "object" && t !== null && "__sentry_template_string__" in t && "__sentry_template_values__" in t;
108
33
  }
109
34
  function Oe(t) {
110
- return t === null || se(t) || typeof t != "object" && typeof t != "function";
35
+ return t === null || Q(t) || typeof t != "object" && typeof t != "function";
111
36
  }
112
37
  function O(t) {
113
- return gt(t, "Object");
38
+ return it(t, "Object");
114
39
  }
115
- function St(t) {
116
- return typeof Event < "u" && k(t, Event);
40
+ function ut(t) {
41
+ return typeof Event < "u" && M(t, Event);
117
42
  }
118
- function yt(t) {
119
- return typeof Element < "u" && k(t, Element);
43
+ function lt(t) {
44
+ return typeof Element < "u" && M(t, Element);
120
45
  }
121
- function P(t) {
46
+ function D(t) {
122
47
  return !!(t && t.then && typeof t.then == "function");
123
48
  }
124
- function Tt(t) {
49
+ function pt(t) {
125
50
  return O(t) && "nativeEvent" in t && "preventDefault" in t && "stopPropagation" in t;
126
51
  }
127
- function k(t, e) {
52
+ function M(t, e) {
128
53
  try {
129
54
  return t instanceof e;
130
55
  } catch {
131
56
  return false;
132
57
  }
133
58
  }
134
- function It(t) {
59
+ function dt(t) {
135
60
  return !!(typeof t == "object" && t !== null && (t.__isVue || t._isVue));
136
61
  }
137
- function U(t, e = 0) {
62
+ function F(t, e = 0) {
138
63
  return typeof t != "string" || e === 0 || t.length <= e ? t : `${t.slice(0, e)}...`;
139
64
  }
140
- var $ = "8.9.2";
65
+ var U = "8.9.2";
141
66
  var h = globalThis;
142
- function oe(t, e, n) {
143
- let r = n || h, s = r.__SENTRY__ = r.__SENTRY__ || {}, o = s[$] = s[$] || {};
67
+ function ee(t, e, n) {
68
+ let r = n || h, s = r.__SENTRY__ = r.__SENTRY__ || {}, o = s[U] = s[U] || {};
144
69
  return o[t] || (o[t] = e());
145
70
  }
146
- var Sr = h;
147
- var yr = 80;
71
+ var Tr = h;
72
+ var Ir = 80;
148
73
  function un(t, e = {}) {
149
74
  if (!t) return "<unknown>";
150
75
  try {
151
- let n = t, r = 5, s = [], o = 0, i = 0, a = " > ", c = a.length, u, l = Array.isArray(e) ? e : e.keyAttrs, p = !Array.isArray(e) && e.maxStringLength || yr;
152
- for (; n && o++ < r && (u = Tr(n, l), !(u === "html" || o > 1 && i + s.length * c + u.length >= p)); ) s.push(u), i += u.length, n = n.parentNode;
76
+ let n = t, r = 5, s = [], o = 0, i = 0, a = " > ", c = a.length, u, l = Array.isArray(e) ? e : e.keyAttrs, p = !Array.isArray(e) && e.maxStringLength || Ir;
77
+ for (; n && o++ < r && (u = xr(n, l), !(u === "html" || o > 1 && i + s.length * c + u.length >= p)); ) s.push(u), i += u.length, n = n.parentNode;
153
78
  return s.reverse().join(a);
154
79
  } catch {
155
80
  return "<unknown>";
156
81
  }
157
82
  }
158
- function Tr(t, e) {
83
+ function xr(t, e) {
159
84
  let n = t, r = [], s, o, i, a, c;
160
85
  if (!n || !n.tagName) return "";
161
- if (Sr.HTMLElement && n instanceof HTMLElement && n.dataset) {
86
+ if (Tr.HTMLElement && n instanceof HTMLElement && n.dataset) {
162
87
  if (n.dataset.sentryComponent) return n.dataset.sentryComponent;
163
88
  if (n.dataset.sentryElement) return n.dataset.sentryElement;
164
89
  }
@@ -167,20 +92,20 @@ function Tr(t, e) {
167
92
  if (u && u.length) u.forEach((p) => {
168
93
  r.push(`[${p[0]}="${p[1]}"]`);
169
94
  });
170
- else if (n.id && r.push(`#${n.id}`), s = n.className, s && Et(s)) for (o = s.split(/\s+/), c = 0; c < o.length; c++) r.push(`.${o[c]}`);
95
+ else if (n.id && r.push(`#${n.id}`), s = n.className, s && ct(s)) for (o = s.split(/\s+/), c = 0; c < o.length; c++) r.push(`.${o[c]}`);
171
96
  let l = ["aria-label", "type", "name", "title", "alt"];
172
97
  for (c = 0; c < l.length; c++) i = l[c], a = n.getAttribute(i), a && r.push(`[${i}="${a}"]`);
173
98
  return r.join("");
174
99
  }
175
- var H = typeof __SENTRY_DEBUG__ > "u" || __SENTRY_DEBUG__;
176
- var Ir = "Sentry Logger ";
177
- var xt = ["debug", "info", "warn", "error", "log", "assert", "trace"];
178
- var At = {};
100
+ var $ = typeof __SENTRY_DEBUG__ > "u" || __SENTRY_DEBUG__;
101
+ var Ar = "Sentry Logger ";
102
+ var ft = ["debug", "info", "warn", "error", "log", "assert", "trace"];
103
+ var mt = {};
179
104
  function ve(t) {
180
105
  if (!("console" in h)) return t();
181
- let e = h.console, n = {}, r = Object.keys(At);
106
+ let e = h.console, n = {}, r = Object.keys(mt);
182
107
  r.forEach((s) => {
183
- let o = At[s];
108
+ let o = mt[s];
184
109
  n[s] = e[s], e[s] = o;
185
110
  });
186
111
  try {
@@ -191,34 +116,34 @@ function ve(t) {
191
116
  });
192
117
  }
193
118
  }
194
- function xr() {
119
+ function br() {
195
120
  let t = false, e = { enable: () => {
196
121
  t = true;
197
122
  }, disable: () => {
198
123
  t = false;
199
124
  }, isEnabled: () => t };
200
- return H ? xt.forEach((n) => {
125
+ return $ ? ft.forEach((n) => {
201
126
  e[n] = (...r) => {
202
127
  t && ve(() => {
203
- h.console[n](`${Ir}[${n}]:`, ...r);
128
+ h.console[n](`${Ar}[${n}]:`, ...r);
204
129
  });
205
130
  };
206
- }) : xt.forEach((n) => {
131
+ }) : ft.forEach((n) => {
207
132
  e[n] = () => {
208
133
  };
209
134
  }), e;
210
135
  }
211
- var f = xr();
212
- var Ar = /^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;
213
- function br(t) {
136
+ var m = br();
137
+ var Rr = /^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;
138
+ function Cr(t) {
214
139
  return t === "http" || t === "https";
215
140
  }
216
- function B(t, e = false) {
141
+ function H(t, e = false) {
217
142
  let { host: n, path: r, pass: s, port: o, projectId: i, protocol: a, publicKey: c } = t;
218
143
  return `${a}://${c}${e && s ? `:${s}` : ""}@${n}${o ? `:${o}` : ""}/${r && `${r}/`}${i}`;
219
144
  }
220
145
  function ln(t) {
221
- let e = Ar.exec(t);
146
+ let e = Rr.exec(t);
222
147
  if (!e) {
223
148
  ve(() => {
224
149
  console.error(`Invalid Sentry Dsn: ${t}`);
@@ -235,14 +160,14 @@ function ln(t) {
235
160
  function pn(t) {
236
161
  return { protocol: t.protocol, publicKey: t.publicKey || "", pass: t.pass || "", host: t.host, port: t.port || "", path: t.path || "", projectId: t.projectId };
237
162
  }
238
- function Rr(t) {
239
- if (!H) return true;
163
+ function Nr(t) {
164
+ if (!$) return true;
240
165
  let { port: e, projectId: n, protocol: r } = t;
241
- return ["protocol", "publicKey", "host", "projectId"].find((i) => t[i] ? false : (f.error(`Invalid Sentry Dsn: ${i} missing`), true)) ? false : n.match(/^\d+$/) ? br(r) ? e && isNaN(parseInt(e, 10)) ? (f.error(`Invalid Sentry Dsn: Invalid port ${e}`), false) : true : (f.error(`Invalid Sentry Dsn: Invalid protocol ${r}`), false) : (f.error(`Invalid Sentry Dsn: Invalid projectId ${n}`), false);
166
+ return ["protocol", "publicKey", "host", "projectId"].find((i) => t[i] ? false : (m.error(`Invalid Sentry Dsn: ${i} missing`), true)) ? false : n.match(/^\d+$/) ? Cr(r) ? e && isNaN(parseInt(e, 10)) ? (m.error(`Invalid Sentry Dsn: Invalid port ${e}`), false) : true : (m.error(`Invalid Sentry Dsn: Invalid protocol ${r}`), false) : (m.error(`Invalid Sentry Dsn: Invalid projectId ${n}`), false);
242
167
  }
243
168
  function we(t) {
244
169
  let e = typeof t == "string" ? ln(t) : pn(t);
245
- if (!(!e || !Rr(e))) return e;
170
+ if (!(!e || !Nr(e))) return e;
246
171
  }
247
172
  var b = class extends Error {
248
173
  constructor(e, n = "warn") {
@@ -253,22 +178,22 @@ function Y(t, e, n) {
253
178
  try {
254
179
  Object.defineProperty(t, e, { value: n, writable: true, configurable: true });
255
180
  } catch {
256
- H && f.log(`Failed to add non-enumerable property "${e}" to object`, t);
181
+ $ && m.log(`Failed to add non-enumerable property "${e}" to object`, t);
257
182
  }
258
183
  }
259
- function Rt(t) {
184
+ function gt(t) {
260
185
  return Object.keys(t).map((e) => `${encodeURIComponent(e)}=${encodeURIComponent(t[e])}`).join("&");
261
186
  }
262
187
  function De(t) {
263
188
  if (z(t)) return { message: t.message, name: t.name, stack: t.stack, ...fn(t) };
264
- if (St(t)) {
189
+ if (ut(t)) {
265
190
  let e = { type: t.type, target: dn(t.target), currentTarget: dn(t.currentTarget), ...fn(t) };
266
- return typeof CustomEvent < "u" && k(t, CustomEvent) && (e.detail = t.detail), e;
191
+ return typeof CustomEvent < "u" && M(t, CustomEvent) && (e.detail = t.detail), e;
267
192
  } else return t;
268
193
  }
269
194
  function dn(t) {
270
195
  try {
271
- return yt(t) ? un(t) : Object.prototype.toString.call(t);
196
+ return lt(t) ? un(t) : Object.prototype.toString.call(t);
272
197
  } catch {
273
198
  return "<unknown>";
274
199
  }
@@ -280,26 +205,26 @@ function fn(t) {
280
205
  return e;
281
206
  } else return {};
282
207
  }
283
- function me(t, e = 40) {
208
+ function fe(t, e = 40) {
284
209
  let n = Object.keys(De(t));
285
210
  if (n.sort(), !n.length) return "[object has no keys]";
286
- if (n[0].length >= e) return U(n[0], e);
211
+ if (n[0].length >= e) return F(n[0], e);
287
212
  for (let r = n.length; r > 0; r--) {
288
213
  let s = n.slice(0, r).join(", ");
289
- if (!(s.length > e)) return r === n.length ? s : U(s, e);
214
+ if (!(s.length > e)) return r === n.length ? s : F(s, e);
290
215
  }
291
216
  return "";
292
217
  }
293
- function y(t) {
294
- return bt(t, /* @__PURE__ */ new Map());
218
+ function S(t) {
219
+ return ht(t, /* @__PURE__ */ new Map());
295
220
  }
296
- function bt(t, e) {
297
- if (Cr(t)) {
221
+ function ht(t, e) {
222
+ if (Or(t)) {
298
223
  let n = e.get(t);
299
224
  if (n !== void 0) return n;
300
225
  let r = {};
301
226
  e.set(t, r);
302
- for (let s of Object.keys(t)) typeof t[s] < "u" && (r[s] = bt(t[s], e));
227
+ for (let s of Object.keys(t)) typeof t[s] < "u" && (r[s] = ht(t[s], e));
303
228
  return r;
304
229
  }
305
230
  if (Array.isArray(t)) {
@@ -307,12 +232,12 @@ function bt(t, e) {
307
232
  if (n !== void 0) return n;
308
233
  let r = [];
309
234
  return e.set(t, r), t.forEach((s) => {
310
- r.push(bt(s, e));
235
+ r.push(ht(s, e));
311
236
  }), r;
312
237
  }
313
238
  return t;
314
239
  }
315
- function Cr(t) {
240
+ function Or(t) {
316
241
  if (!O(t)) return false;
317
242
  try {
318
243
  let e = Object.getPrototypeOf(t).constructor.name;
@@ -347,7 +272,7 @@ function Pe(...t) {
347
272
  return gn(o.slice(s));
348
273
  };
349
274
  }
350
- function Nt(t) {
275
+ function Et(t) {
351
276
  return Array.isArray(t) ? Pe(...t) : t;
352
277
  }
353
278
  function gn(t) {
@@ -355,12 +280,12 @@ function gn(t) {
355
280
  let e = Array.from(t);
356
281
  return /sentryWrapped/.test(e[e.length - 1].function || "") && e.pop(), e.reverse(), hn.test(e[e.length - 1].function || "") && (e.pop(), hn.test(e[e.length - 1].function || "") && e.pop()), e.slice(0, 50).map((n) => ({ ...n, filename: n.filename || e[e.length - 1].filename, function: n.function || Me }));
357
282
  }
358
- var Ct = "<anonymous>";
359
- function he(t) {
283
+ var _t = "<anonymous>";
284
+ function me(t) {
360
285
  try {
361
- return !t || typeof t != "function" ? Ct : t.name || Ct;
286
+ return !t || typeof t != "function" ? _t : t.name || _t;
362
287
  } catch {
363
- return Ct;
288
+ return _t;
364
289
  }
365
290
  }
366
291
  var ke = {};
@@ -376,49 +301,49 @@ function Ue(t, e) {
376
301
  if (n) for (let r of n) try {
377
302
  r(e);
378
303
  } catch (s) {
379
- H && f.error(`Error while triggering instrumentation handler.
304
+ $ && m.error(`Error while triggering instrumentation handler.
380
305
  Type: ${t}
381
- Name: ${he(r)}
306
+ Name: ${me(r)}
382
307
  Error:`, s);
383
308
  }
384
309
  }
385
310
  var En = 1e3;
386
- function ie() {
311
+ function te() {
387
312
  return Date.now() / En;
388
313
  }
389
- function Nr() {
314
+ function vr() {
390
315
  let { performance: t } = h;
391
- if (!t || !t.now) return ie;
316
+ if (!t || !t.now) return te;
392
317
  let e = Date.now() - t.now(), n = t.timeOrigin == null ? e : t.timeOrigin;
393
318
  return () => (n + t.now()) / En;
394
319
  }
395
- var _e = Nr();
396
- var ge;
397
- var Or = (() => {
320
+ var ge = vr();
321
+ var he;
322
+ var wr = (() => {
398
323
  let { performance: t } = h;
399
324
  if (!t || !t.now) {
400
- ge = "none";
325
+ he = "none";
401
326
  return;
402
327
  }
403
328
  let e = 3600 * 1e3, n = t.now(), r = Date.now(), s = t.timeOrigin ? Math.abs(t.timeOrigin + n - r) : e, o = s < e, i = t.timing && t.timing.navigationStart, c = typeof i == "number" ? Math.abs(i + n - r) : e, u = c < e;
404
- return o || u ? s <= c ? (ge = "timeOrigin", t.timeOrigin) : (ge = "navigationStart", i) : (ge = "dateNow", r);
329
+ return o || u ? s <= c ? (he = "timeOrigin", t.timeOrigin) : (he = "navigationStart", i) : (he = "dateNow", r);
405
330
  })();
406
331
  var $e = null;
407
- function Ot(t) {
332
+ function St(t) {
408
333
  let e = "error";
409
- Le(e, t), Fe(e, vr);
334
+ Le(e, t), Fe(e, Dr);
410
335
  }
411
- function vr() {
336
+ function Dr() {
412
337
  $e = h.onerror, h.onerror = function(t, e, n, r, s) {
413
338
  return Ue("error", { column: r, error: s, line: n, msg: t, url: e }), $e && !$e.__SENTRY_LOADER__ ? $e.apply(this, arguments) : false;
414
339
  }, h.onerror.__SENTRY_INSTRUMENTED__ = true;
415
340
  }
416
341
  var He = null;
417
- function vt(t) {
342
+ function yt(t) {
418
343
  let e = "unhandledrejection";
419
- Le(e, t), Fe(e, wr);
344
+ Le(e, t), Fe(e, Mr);
420
345
  }
421
- function wr() {
346
+ function Mr() {
422
347
  He = h.onunhandledrejection, h.onunhandledrejection = function(t) {
423
348
  return Ue("unhandledrejection", t), He && !He.__SENTRY_LOADER__ ? He.apply(this, arguments) : true;
424
349
  }, h.onunhandledrejection.__SENTRY_INSTRUMENTED__ = true;
@@ -451,15 +376,15 @@ function x() {
451
376
  }
452
377
  return ("10000000100040008000" + 1e11).replace(/[018]/g, (r) => (r ^ (n() & 15) >> r / 4).toString(16));
453
378
  }
454
- function Dr(t) {
379
+ function Pr(t) {
455
380
  return t.exception && t.exception.values ? t.exception.values[0] : void 0;
456
381
  }
457
- function Ee(t, e, n) {
382
+ function _e(t, e, n) {
458
383
  let r = t.exception = t.exception || {}, s = r.values = r.values || [], o = s[0] = s[0] || {};
459
384
  o.value || (o.value = e || ""), o.type || (o.type = n || "Error");
460
385
  }
461
386
  function J(t, e) {
462
- let n = Dr(t);
387
+ let n = Pr(t);
463
388
  if (!n) return;
464
389
  let r = { type: "generic", handled: true }, s = n.mechanism;
465
390
  if (n.mechanism = { ...r, ...s, ...e }, e && "data" in e) {
@@ -475,24 +400,24 @@ function Be(t) {
475
400
  }
476
401
  return false;
477
402
  }
478
- function Se(t) {
403
+ function Ee(t) {
479
404
  return Array.isArray(t) ? t : [t];
480
405
  }
481
406
  function v(t, e = 100, n = 1 / 0) {
482
407
  try {
483
- return wt("", t, e, n);
408
+ return Tt("", t, e, n);
484
409
  } catch (r) {
485
410
  return { ERROR: `**non-serializable** (${r})` };
486
411
  }
487
412
  }
488
- function ae(t, e = 3, n = 100 * 1024) {
413
+ function ne(t, e = 3, n = 100 * 1024) {
489
414
  let r = v(t, e);
490
- return Lr(r) > n ? ae(t, e - 1, n) : r;
415
+ return Ur(r) > n ? ne(t, e - 1, n) : r;
491
416
  }
492
- function wt(t, e, n = 1 / 0, r = 1 / 0, s = Sn()) {
417
+ function Tt(t, e, n = 1 / 0, r = 1 / 0, s = Sn()) {
493
418
  let [o, i] = s;
494
419
  if (e == null || ["number", "boolean", "string"].includes(typeof e) && !Number.isNaN(e)) return e;
495
- let a = Mr(t, e);
420
+ let a = kr(t, e);
496
421
  if (!a.startsWith("[object ")) return a;
497
422
  if (e.__sentry_skip_normalization__) return e;
498
423
  let c = typeof e.__sentry_override_normalization_depth__ == "number" ? e.__sentry_override_normalization_depth__ : n;
@@ -501,51 +426,51 @@ function wt(t, e, n = 1 / 0, r = 1 / 0, s = Sn()) {
501
426
  let u = e;
502
427
  if (u && typeof u.toJSON == "function") try {
503
428
  let d = u.toJSON();
504
- return wt("", d, c - 1, r, s);
429
+ return Tt("", d, c - 1, r, s);
505
430
  } catch {
506
431
  }
507
- let l = Array.isArray(e) ? [] : {}, p = 0, m = De(e);
508
- for (let d in m) {
509
- if (!Object.prototype.hasOwnProperty.call(m, d)) continue;
432
+ let l = Array.isArray(e) ? [] : {}, p = 0, f = De(e);
433
+ for (let d in f) {
434
+ if (!Object.prototype.hasOwnProperty.call(f, d)) continue;
510
435
  if (p >= r) {
511
436
  l[d] = "[MaxProperties ~]";
512
437
  break;
513
438
  }
514
- let g = m[d];
515
- l[d] = wt(d, g, c - 1, r, s), p++;
439
+ let g = f[d];
440
+ l[d] = Tt(d, g, c - 1, r, s), p++;
516
441
  }
517
442
  return i(e), l;
518
443
  }
519
- function Mr(t, e) {
444
+ function kr(t, e) {
520
445
  try {
521
446
  if (t === "domain" && e && typeof e == "object" && e._events) return "[Domain]";
522
447
  if (t === "domainEmitter") return "[DomainEmitter]";
523
448
  if (typeof global < "u" && e === global) return "[Global]";
524
449
  if (typeof window < "u" && e === window) return "[Window]";
525
450
  if (typeof document < "u" && e === document) return "[Document]";
526
- if (It(e)) return "[VueViewModel]";
527
- if (Tt(e)) return "[SyntheticEvent]";
451
+ if (dt(e)) return "[VueViewModel]";
452
+ if (pt(e)) return "[SyntheticEvent]";
528
453
  if (typeof e == "number" && e !== e) return "[NaN]";
529
- if (typeof e == "function") return `[Function: ${he(e)}]`;
454
+ if (typeof e == "function") return `[Function: ${me(e)}]`;
530
455
  if (typeof e == "symbol") return `[${String(e)}]`;
531
456
  if (typeof e == "bigint") return `[BigInt: ${String(e)}]`;
532
- let n = Pr(e);
457
+ let n = Lr(e);
533
458
  return /^HTML(\w*)Element$/.test(n) ? `[HTMLElement: ${n}]` : `[object ${n}]`;
534
459
  } catch (n) {
535
460
  return `**non-serializable** (${n})`;
536
461
  }
537
462
  }
538
- function Pr(t) {
463
+ function Lr(t) {
539
464
  let e = Object.getPrototypeOf(t);
540
465
  return e ? e.constructor.name : "null prototype";
541
466
  }
542
- function kr(t) {
467
+ function Fr(t) {
543
468
  return ~-encodeURI(t).split(/%..|./).length;
544
469
  }
545
- function Lr(t) {
546
- return kr(JSON.stringify(t));
470
+ function Ur(t) {
471
+ return Fr(JSON.stringify(t));
547
472
  }
548
- function Fr(t, e) {
473
+ function $r(t, e) {
549
474
  let n = 0;
550
475
  for (let r = t.length - 1; r >= 0; r--) {
551
476
  let s = t[r];
@@ -554,18 +479,18 @@ function Fr(t, e) {
554
479
  if (e) for (; n--; n) t.unshift("..");
555
480
  return t;
556
481
  }
557
- var Ur = /^(\S+:\\|\/?)([\s\S]*?)((?:\.{1,2}|[^/\\]+?|)(\.[^./\\]*|))(?:[/\\]*)$/;
558
- function $r(t) {
559
- let e = t.length > 1024 ? `<truncated>${t.slice(-1024)}` : t, n = Ur.exec(e);
482
+ var Hr = /^(\S+:\\|\/?)([\s\S]*?)((?:\.{1,2}|[^/\\]+?|)(\.[^./\\]*|))(?:[/\\]*)$/;
483
+ function Br(t) {
484
+ let e = t.length > 1024 ? `<truncated>${t.slice(-1024)}` : t, n = Hr.exec(e);
560
485
  return n ? n.slice(1) : [];
561
486
  }
562
- function Dt(...t) {
487
+ function It(...t) {
563
488
  let e = "", n = false;
564
489
  for (let r = t.length - 1; r >= -1 && !n; r--) {
565
490
  let s = r >= 0 ? t[r] : "/";
566
491
  s && (e = `${s}/${e}`, n = s.charAt(0) === "/");
567
492
  }
568
- return e = Fr(e.split("/").filter((r) => !!r), !n).join("/"), (n ? "/" : "") + e || ".";
493
+ return e = $r(e.split("/").filter((r) => !!r), !n).join("/"), (n ? "/" : "") + e || ".";
569
494
  }
570
495
  function yn(t) {
571
496
  let e = 0;
@@ -574,8 +499,8 @@ function yn(t) {
574
499
  for (; n >= 0 && t[n] === ""; n--) ;
575
500
  return e > n ? [] : t.slice(e, n - e + 1);
576
501
  }
577
- function Mt(t, e) {
578
- t = Dt(t).slice(1), e = Dt(e).slice(1);
502
+ function xt(t, e) {
503
+ t = It(t).slice(1), e = It(e).slice(1);
579
504
  let n = yn(t.split("/")), r = yn(e.split("/")), s = Math.min(n.length, r.length), o = s;
580
505
  for (let a = 0; a < s; a++) if (n[a] !== r[a]) {
581
506
  o = a;
@@ -585,18 +510,18 @@ function Mt(t, e) {
585
510
  for (let a = o; a < n.length; a++) i.push("..");
586
511
  return i = i.concat(r.slice(o)), i.join("/");
587
512
  }
588
- function ye(t, e) {
589
- let n = $r(t)[2];
513
+ function Se(t, e) {
514
+ let n = Br(t)[2];
590
515
  return e && n.slice(e.length * -1) === e && (n = n.slice(0, n.length - e.length)), n;
591
516
  }
592
- var L;
517
+ var P;
593
518
  (function(t) {
594
519
  t[t.PENDING = 0] = "PENDING";
595
520
  let n = 1;
596
521
  t[t.RESOLVED = n] = "RESOLVED";
597
522
  let r = 2;
598
523
  t[t.REJECTED = r] = "REJECTED";
599
- })(L || (L = {}));
524
+ })(P || (P = {}));
600
525
  function R(t) {
601
526
  return new A((e) => {
602
527
  e(t);
@@ -609,7 +534,7 @@ function V(t) {
609
534
  }
610
535
  var A = class {
611
536
  constructor(e) {
612
- A.prototype.__init.call(this), A.prototype.__init2.call(this), A.prototype.__init3.call(this), A.prototype.__init4.call(this), this._state = L.PENDING, this._handlers = [];
537
+ A.prototype.__init.call(this), A.prototype.__init2.call(this), A.prototype.__init3.call(this), A.prototype.__init4.call(this), this._state = P.PENDING, this._handlers = [];
613
538
  try {
614
539
  e(this._resolve, this._reject);
615
540
  } catch (n) {
@@ -656,18 +581,18 @@ var A = class {
656
581
  }
657
582
  __init() {
658
583
  this._resolve = (e) => {
659
- this._setResult(L.RESOLVED, e);
584
+ this._setResult(P.RESOLVED, e);
660
585
  };
661
586
  }
662
587
  __init2() {
663
588
  this._reject = (e) => {
664
- this._setResult(L.REJECTED, e);
589
+ this._setResult(P.REJECTED, e);
665
590
  };
666
591
  }
667
592
  __init3() {
668
593
  this._setResult = (e, n) => {
669
- if (this._state === L.PENDING) {
670
- if (P(n)) {
594
+ if (this._state === P.PENDING) {
595
+ if (D(n)) {
671
596
  n.then(this._resolve, this._reject);
672
597
  return;
673
598
  }
@@ -677,15 +602,15 @@ var A = class {
677
602
  }
678
603
  __init4() {
679
604
  this._executeHandlers = () => {
680
- if (this._state === L.PENDING) return;
605
+ if (this._state === P.PENDING) return;
681
606
  let e = this._handlers.slice();
682
607
  this._handlers = [], e.forEach((n) => {
683
- n[0] || (this._state === L.RESOLVED && n[1](this._value), this._state === L.REJECTED && n[2](this._value), n[0] = true);
608
+ n[0] || (this._state === P.RESOLVED && n[1](this._value), this._state === P.REJECTED && n[2](this._value), n[0] = true);
684
609
  });
685
610
  };
686
611
  }
687
612
  };
688
- function Pt(t) {
613
+ function At(t) {
689
614
  let e = [];
690
615
  function n() {
691
616
  return t === void 0 || e.length < t;
@@ -726,9 +651,9 @@ function In(t) {
726
651
  let o, i, a, c, u;
727
652
  if (s[1]) {
728
653
  a = s[1];
729
- let m = a.lastIndexOf(".");
730
- if (a[m - 1] === "." && m--, m > 0) {
731
- o = a.slice(0, m), i = a.slice(m + 1);
654
+ let f = a.lastIndexOf(".");
655
+ if (a[f - 1] === "." && f--, f > 0) {
656
+ o = a.slice(0, f), i = a.slice(f + 1);
732
657
  let d = o.indexOf(".Module");
733
658
  d > 0 && (a = a.slice(d + 1), o = o.slice(0, d));
734
659
  }
@@ -741,13 +666,13 @@ function In(t) {
741
666
  if (r.match(e)) return { filename: r };
742
667
  };
743
668
  }
744
- function kt(t) {
669
+ function bt(t) {
745
670
  return [90, In(t)];
746
671
  }
747
- function j(t, e = []) {
672
+ function B(t, e = []) {
748
673
  return [t, e];
749
674
  }
750
- function Ft(t, e) {
675
+ function Ct(t, e) {
751
676
  let [n, r] = t;
752
677
  return [n, [...r, e]];
753
678
  }
@@ -759,13 +684,13 @@ function je(t, e) {
759
684
  }
760
685
  return false;
761
686
  }
762
- function Lt(t) {
687
+ function Rt(t) {
763
688
  return h.__SENTRY__ && h.__SENTRY__.encodePolyfill ? h.__SENTRY__.encodePolyfill(t) : new TextEncoder().encode(t);
764
689
  }
765
- function Ut(t) {
690
+ function Nt(t) {
766
691
  let [e, n] = t, r = JSON.stringify(e);
767
692
  function s(o) {
768
- typeof r == "string" ? r = typeof o == "string" ? r + o : [Lt(r), o] : r.push(typeof o == "string" ? Lt(o) : o);
693
+ typeof r == "string" ? r = typeof o == "string" ? r + o : [Rt(r), o] : r.push(typeof o == "string" ? Rt(o) : o);
769
694
  }
770
695
  for (let o of n) {
771
696
  let [i, a] = o;
@@ -782,29 +707,29 @@ ${JSON.stringify(i)}
782
707
  s(c);
783
708
  }
784
709
  }
785
- return typeof r == "string" ? r : Hr(r);
710
+ return typeof r == "string" ? r : jr(r);
786
711
  }
787
- function Hr(t) {
712
+ function jr(t) {
788
713
  let e = t.reduce((s, o) => s + o.length, 0), n = new Uint8Array(e), r = 0;
789
714
  for (let s of t) n.set(s, r), r += s.length;
790
715
  return n;
791
716
  }
792
- function $t(t) {
793
- let e = typeof t.data == "string" ? Lt(t.data) : t.data;
794
- return [y({ type: "attachment", length: e.length, filename: t.filename, content_type: t.contentType, attachment_type: t.attachmentType }), e];
717
+ function Ot(t) {
718
+ let e = typeof t.data == "string" ? Rt(t.data) : t.data;
719
+ return [S({ type: "attachment", length: e.length, filename: t.filename, content_type: t.contentType, attachment_type: t.attachmentType }), e];
795
720
  }
796
- var Br = { session: "session", sessions: "session", attachment: "attachment", transaction: "transaction", event: "error", client_report: "internal", user_report: "default", profile: "profile", profile_chunk: "profile", replay_event: "replay", replay_recording: "replay", check_in: "monitor", feedback: "feedback", span: "span", statsd: "metric_bucket" };
721
+ var Gr = { session: "session", sessions: "session", attachment: "attachment", transaction: "transaction", event: "error", client_report: "internal", user_report: "default", profile: "profile", profile_chunk: "profile", replay_event: "replay", replay_recording: "replay", check_in: "monitor", feedback: "feedback", span: "span", statsd: "metric_bucket" };
797
722
  function Ge(t) {
798
- return Br[t];
723
+ return Gr[t];
799
724
  }
800
725
  function qe(t) {
801
726
  if (!t || !t.sdk) return;
802
727
  let { name: e, version: n } = t.sdk;
803
728
  return { name: e, version: n };
804
729
  }
805
- function Ht(t, e, n, r) {
730
+ function vt(t, e, n, r) {
806
731
  let s = t.sdkProcessingMetadata && t.sdkProcessingMetadata.dynamicSamplingContext;
807
- return { event_id: t.event_id, sent_at: (/* @__PURE__ */ new Date()).toISOString(), ...e && { sdk: e }, ...!!n && r && { dsn: B(r) }, ...s && { trace: y({ ...s }) } };
732
+ return { event_id: t.event_id, sent_at: (/* @__PURE__ */ new Date()).toISOString(), ...e && { sdk: e }, ...!!n && r && { dsn: H(r) }, ...s && { trace: S({ ...s }) } };
808
733
  }
809
734
  function xn(t, e = Date.now()) {
810
735
  let n = parseInt(`${t}`, 10);
@@ -815,71 +740,71 @@ function xn(t, e = Date.now()) {
815
740
  function An(t, e) {
816
741
  return t[e] || t.all || 0;
817
742
  }
818
- function Bt(t, e, n = Date.now()) {
743
+ function wt(t, e, n = Date.now()) {
819
744
  return An(t, e) > n;
820
745
  }
821
- function jt(t, { statusCode: e, headers: n }, r = Date.now()) {
746
+ function Dt(t, { statusCode: e, headers: n }, r = Date.now()) {
822
747
  let s = { ...t }, o = n && n["x-sentry-rate-limits"], i = n && n["retry-after"];
823
748
  if (o) for (let a of o.trim().split(",")) {
824
- let [c, u, , , l] = a.split(":", 5), p = parseInt(c, 10), m = (isNaN(p) ? 60 : p) * 1e3;
825
- if (!u) s.all = r + m;
826
- else for (let d of u.split(";")) d === "metric_bucket" ? (!l || l.split(";").includes("custom")) && (s[d] = r + m) : s[d] = r + m;
749
+ let [c, u, , , l] = a.split(":", 5), p = parseInt(c, 10), f = (isNaN(p) ? 60 : p) * 1e3;
750
+ if (!u) s.all = r + f;
751
+ else for (let d of u.split(";")) d === "metric_bucket" ? (!l || l.split(";").includes("custom")) && (s[d] = r + f) : s[d] = r + f;
827
752
  }
828
753
  else i ? s.all = r + xn(i, r) : e === 429 && (s.all = r + 60 * 1e3);
829
754
  return s;
830
755
  }
831
- function Gt(t, e) {
756
+ function Mt(t, e) {
832
757
  return t(e.stack || "", 1);
833
758
  }
834
759
  function bn(t, e) {
835
- let n = { type: e.name || e.constructor.name, value: e.message }, r = Gt(t, e);
760
+ let n = { type: e.name || e.constructor.name, value: e.message }, r = Mt(t, e);
836
761
  return r.length && (n.stacktrace = { frames: r }), n;
837
762
  }
838
- function jr(t) {
763
+ function qr(t) {
839
764
  for (let e in t) if (Object.prototype.hasOwnProperty.call(t, e)) {
840
765
  let n = t[e];
841
766
  if (n instanceof Error) return n;
842
767
  }
843
768
  }
844
- function Gr(t) {
769
+ function zr(t) {
845
770
  if ("name" in t && typeof t.name == "string") {
846
771
  let r = `'${t.name}' captured as exception`;
847
772
  return "message" in t && typeof t.message == "string" && (r += ` with message '${t.message}'`), r;
848
773
  } else if ("message" in t && typeof t.message == "string") return t.message;
849
- let e = me(t);
850
- if (_t(t)) return `Event \`ErrorEvent\` captured as exception with message \`${t.message}\``;
851
- let n = qr(t);
774
+ let e = fe(t);
775
+ if (at(t)) return `Event \`ErrorEvent\` captured as exception with message \`${t.message}\``;
776
+ let n = Yr(t);
852
777
  return `${n && n !== "Object" ? `'${n}'` : "Object"} captured as exception with keys: ${e}`;
853
778
  }
854
- function qr(t) {
779
+ function Yr(t) {
855
780
  try {
856
781
  let e = Object.getPrototypeOf(t);
857
782
  return e ? e.constructor.name : void 0;
858
783
  } catch {
859
784
  }
860
785
  }
861
- function zr(t, e, n, r) {
786
+ function Jr(t, e, n, r) {
862
787
  if (z(n)) return [n, void 0];
863
788
  if (e.synthetic = true, O(n)) {
864
- let o = t && t.getOptions().normalizeDepth, i = { __serialized__: ae(n, o) }, a = jr(n);
789
+ let o = t && t.getOptions().normalizeDepth, i = { __serialized__: ne(n, o) }, a = qr(n);
865
790
  if (a) return [a, i];
866
- let c = Gr(n), u = r && r.syntheticException || new Error(c);
791
+ let c = zr(n), u = r && r.syntheticException || new Error(c);
867
792
  return u.message = c, [u, i];
868
793
  }
869
794
  let s = r && r.syntheticException || new Error(n);
870
795
  return s.message = `${n}`, [s, void 0];
871
796
  }
872
- function qt(t, e, n, r) {
873
- let o = r && r.data && r.data.mechanism || { handled: true, type: "generic" }, [i, a] = zr(t, o, n, r), c = { exception: { values: [bn(e, i)] } };
874
- return a && (c.extra = a), Ee(c, void 0, void 0), J(c, o), { ...c, event_id: r && r.event_id };
797
+ function Pt(t, e, n, r) {
798
+ let o = r && r.data && r.data.mechanism || { handled: true, type: "generic" }, [i, a] = Jr(t, o, n, r), c = { exception: { values: [bn(e, i)] } };
799
+ return a && (c.extra = a), _e(c, void 0, void 0), J(c, o), { ...c, event_id: r && r.event_id };
875
800
  }
876
- function zt(t, e, n = "info", r, s) {
801
+ function kt(t, e, n = "info", r, s) {
877
802
  let o = { event_id: r && r.event_id, level: n };
878
803
  if (s && r && r.syntheticException) {
879
- let i = Gt(t, r.syntheticException);
804
+ let i = Mt(t, r.syntheticException);
880
805
  i.length && (o.exception = { values: [{ value: e, stacktrace: { frames: i } }] });
881
806
  }
882
- if (se(e)) {
807
+ if (Q(e)) {
883
808
  let { __sentry_template_string__: i, __sentry_template_values__: a } = e;
884
809
  return o.logentry = { message: i, params: a }, o;
885
810
  }
@@ -889,15 +814,15 @@ function ze() {
889
814
  return { traceId: x(), spanId: x().substring(16) };
890
815
  }
891
816
  var _ = typeof __SENTRY_DEBUG__ > "u" || __SENTRY_DEBUG__;
892
- function G() {
893
- return Te(h), h;
817
+ function j() {
818
+ return ye(h), h;
894
819
  }
895
- function Te(t) {
820
+ function ye(t) {
896
821
  let e = t.__SENTRY__ = t.__SENTRY__ || {};
897
- return e.version = e.version || $, e[$] = e[$] || {};
822
+ return e.version = e.version || U, e[U] = e[U] || {};
898
823
  }
899
- function Ie(t, e = {}) {
900
- if (e.user && (!t.ipAddress && e.user.ip_address && (t.ipAddress = e.user.ip_address), !t.did && !e.did && (t.did = e.user.id || e.user.email || e.user.username)), t.timestamp = e.timestamp || _e(), e.abnormal_mechanism && (t.abnormal_mechanism = e.abnormal_mechanism), e.ignoreDuration && (t.ignoreDuration = e.ignoreDuration), e.sid && (t.sid = e.sid.length === 32 ? e.sid : x()), e.init !== void 0 && (t.init = e.init), !t.did && e.did && (t.did = `${e.did}`), typeof e.started == "number" && (t.started = e.started), t.ignoreDuration) t.duration = void 0;
824
+ function Te(t, e = {}) {
825
+ if (e.user && (!t.ipAddress && e.user.ip_address && (t.ipAddress = e.user.ip_address), !t.did && !e.did && (t.did = e.user.id || e.user.email || e.user.username)), t.timestamp = e.timestamp || ge(), e.abnormal_mechanism && (t.abnormal_mechanism = e.abnormal_mechanism), e.ignoreDuration && (t.ignoreDuration = e.ignoreDuration), e.sid && (t.sid = e.sid.length === 32 ? e.sid : x()), e.init !== void 0 && (t.init = e.init), !t.did && e.did && (t.did = `${e.did}`), typeof e.started == "number" && (t.started = e.started), t.ignoreDuration) t.duration = void 0;
901
826
  else if (typeof e.duration == "number") t.duration = e.duration;
902
827
  else {
903
828
  let n = t.timestamp - t.started;
@@ -905,21 +830,21 @@ function Ie(t, e = {}) {
905
830
  }
906
831
  e.release && (t.release = e.release), e.environment && (t.environment = e.environment), !t.ipAddress && e.ipAddress && (t.ipAddress = e.ipAddress), !t.userAgent && e.userAgent && (t.userAgent = e.userAgent), typeof e.errors == "number" && (t.errors = e.errors), e.status && (t.status = e.status);
907
832
  }
908
- var Yt = "_sentrySpan";
909
- function Jt(t, e) {
910
- e ? Y(t, Yt, e) : delete t[Yt];
833
+ var Lt = "_sentrySpan";
834
+ function Ft(t, e) {
835
+ e ? Y(t, Lt, e) : delete t[Lt];
911
836
  }
912
837
  function W(t) {
913
- return t[Yt];
838
+ return t[Lt];
914
839
  }
915
- var Jr = 100;
916
- var xe = class {
840
+ var Wr = 100;
841
+ var Ie = class {
917
842
  constructor() {
918
843
  this._notifyingListeners = false, this._scopeListeners = [], this._eventProcessors = [], this._breadcrumbs = [], this._attachments = [], this._user = {}, this._tags = {}, this._extra = {}, this._contexts = {}, this._sdkProcessingMetadata = {}, this._propagationContext = ze();
919
844
  }
920
845
  clone() {
921
- let e = new xe();
922
- return e._breadcrumbs = [...this._breadcrumbs], e._tags = { ...this._tags }, e._extra = { ...this._extra }, e._contexts = { ...this._contexts }, e._user = this._user, e._level = this._level, e._session = this._session, e._transactionName = this._transactionName, e._fingerprint = this._fingerprint, e._eventProcessors = [...this._eventProcessors], e._requestSession = this._requestSession, e._attachments = [...this._attachments], e._sdkProcessingMetadata = { ...this._sdkProcessingMetadata }, e._propagationContext = { ...this._propagationContext }, e._client = this._client, e._lastEventId = this._lastEventId, Jt(e, W(this)), e;
846
+ let e = new Ie();
847
+ return e._breadcrumbs = [...this._breadcrumbs], e._tags = { ...this._tags }, e._extra = { ...this._extra }, e._contexts = { ...this._contexts }, e._user = this._user, e._level = this._level, e._session = this._session, e._transactionName = this._transactionName, e._fingerprint = this._fingerprint, e._eventProcessors = [...this._eventProcessors], e._requestSession = this._requestSession, e._attachments = [...this._attachments], e._sdkProcessingMetadata = { ...this._sdkProcessingMetadata }, e._propagationContext = { ...this._propagationContext }, e._client = this._client, e._lastEventId = this._lastEventId, Ft(e, W(this)), e;
923
848
  }
924
849
  setClient(e) {
925
850
  this._client = e;
@@ -940,7 +865,7 @@ var xe = class {
940
865
  return this._eventProcessors.push(e), this;
941
866
  }
942
867
  setUser(e) {
943
- return this._user = e || { email: void 0, id: void 0, ip_address: void 0, username: void 0 }, this._session && Ie(this._session, { user: e }), this._notifyScopeListeners(), this;
868
+ return this._user = e || { email: void 0, id: void 0, ip_address: void 0, username: void 0 }, this._session && Te(this._session, { user: e }), this._notifyScopeListeners(), this;
944
869
  }
945
870
  getUser() {
946
871
  return this._user;
@@ -987,12 +912,12 @@ var xe = class {
987
912
  return this._tags = { ...this._tags, ...o }, this._extra = { ...this._extra, ...i }, this._contexts = { ...this._contexts, ...c }, a && Object.keys(a).length && (this._user = a), u && (this._level = u), l.length && (this._fingerprint = l), p && (this._propagationContext = p), s && (this._requestSession = s), this;
988
913
  }
989
914
  clear() {
990
- return this._breadcrumbs = [], this._tags = {}, this._extra = {}, this._user = {}, this._contexts = {}, this._level = void 0, this._transactionName = void 0, this._fingerprint = void 0, this._requestSession = void 0, this._session = void 0, Jt(this, void 0), this._attachments = [], this._propagationContext = ze(), this._notifyScopeListeners(), this;
915
+ return this._breadcrumbs = [], this._tags = {}, this._extra = {}, this._user = {}, this._contexts = {}, this._level = void 0, this._transactionName = void 0, this._fingerprint = void 0, this._requestSession = void 0, this._session = void 0, Ft(this, void 0), this._attachments = [], this._propagationContext = ze(), this._notifyScopeListeners(), this;
991
916
  }
992
917
  addBreadcrumb(e, n) {
993
- let r = typeof n == "number" ? n : Jr;
918
+ let r = typeof n == "number" ? n : Wr;
994
919
  if (r <= 0) return this;
995
- let s = { timestamp: ie(), ...e }, o = this._breadcrumbs;
920
+ let s = { timestamp: te(), ...e }, o = this._breadcrumbs;
996
921
  return o.push(s), this._breadcrumbs = o.length > r ? o.slice(-r) : o, this._notifyScopeListeners(), this;
997
922
  }
998
923
  getLastBreadcrumb() {
@@ -1021,19 +946,19 @@ var xe = class {
1021
946
  }
1022
947
  captureException(e, n) {
1023
948
  let r = n && n.event_id ? n.event_id : x();
1024
- if (!this._client) return f.warn("No client configured on scope - will not capture exception!"), r;
949
+ if (!this._client) return m.warn("No client configured on scope - will not capture exception!"), r;
1025
950
  let s = new Error("Sentry syntheticException");
1026
951
  return this._client.captureException(e, { originalException: e, syntheticException: s, ...n, event_id: r }, this), r;
1027
952
  }
1028
953
  captureMessage(e, n, r) {
1029
954
  let s = r && r.event_id ? r.event_id : x();
1030
- if (!this._client) return f.warn("No client configured on scope - will not capture message!"), s;
955
+ if (!this._client) return m.warn("No client configured on scope - will not capture message!"), s;
1031
956
  let o = new Error(e);
1032
957
  return this._client.captureMessage(e, n, { originalException: e, syntheticException: o, ...r, event_id: s }, this), s;
1033
958
  }
1034
959
  captureEvent(e, n) {
1035
960
  let r = n && n.event_id ? n.event_id : x();
1036
- return this._client ? (this._client.captureEvent(e, { ...n, event_id: r }, this), r) : (f.warn("No client configured on scope - will not capture event!"), r);
961
+ return this._client ? (this._client.captureEvent(e, { ...n, event_id: r }, this), r) : (m.warn("No client configured on scope - will not capture event!"), r);
1037
962
  }
1038
963
  _notifyScopeListeners() {
1039
964
  this._notifyingListeners || (this._notifyingListeners = true, this._scopeListeners.forEach((e) => {
@@ -1041,14 +966,14 @@ var xe = class {
1041
966
  }), this._notifyingListeners = false);
1042
967
  }
1043
968
  };
1044
- var C = xe;
969
+ var C = Ie;
1045
970
  function Rn() {
1046
- return oe("defaultCurrentScope", () => new C());
971
+ return ee("defaultCurrentScope", () => new C());
1047
972
  }
1048
973
  function Cn() {
1049
- return oe("defaultIsolationScope", () => new C());
974
+ return ee("defaultIsolationScope", () => new C());
1050
975
  }
1051
- var Vt = class {
976
+ var Ut = class {
1052
977
  constructor(e, n) {
1053
978
  let r;
1054
979
  e ? r = e : r = new C();
@@ -1062,7 +987,7 @@ var Vt = class {
1062
987
  } catch (s) {
1063
988
  throw this._popScope(), s;
1064
989
  }
1065
- return P(r) ? r.then((s) => (this._popScope(), s), (s) => {
990
+ return D(r) ? r.then((s) => (this._popScope(), s), (s) => {
1066
991
  throw this._popScope(), s;
1067
992
  }) : (this._popScope(), r);
1068
993
  }
@@ -1089,125 +1014,125 @@ var Vt = class {
1089
1014
  return this.getStack().length <= 1 ? false : !!this.getStack().pop();
1090
1015
  }
1091
1016
  };
1092
- function ce() {
1093
- let t = G(), e = Te(t);
1094
- return e.stack = e.stack || new Vt(Rn(), Cn());
1017
+ function re() {
1018
+ let t = j(), e = ye(t);
1019
+ return e.stack = e.stack || new Ut(Rn(), Cn());
1095
1020
  }
1096
- function Vr(t) {
1097
- return ce().withScope(t);
1021
+ function Kr(t) {
1022
+ return re().withScope(t);
1098
1023
  }
1099
- function Wr(t, e) {
1100
- let n = ce();
1024
+ function Zr(t, e) {
1025
+ let n = re();
1101
1026
  return n.withScope(() => (n.getStackTop().scope = t, e(t)));
1102
1027
  }
1103
1028
  function Nn(t) {
1104
- return ce().withScope(() => t(ce().getIsolationScope()));
1029
+ return re().withScope(() => t(re().getIsolationScope()));
1105
1030
  }
1106
1031
  function On() {
1107
- return { withIsolationScope: Nn, withScope: Vr, withSetScope: Wr, withSetIsolationScope: (t, e) => Nn(e), getCurrentScope: () => ce().getScope(), getIsolationScope: () => ce().getIsolationScope() };
1032
+ return { withIsolationScope: Nn, withScope: Kr, withSetScope: Zr, withSetIsolationScope: (t, e) => Nn(e), getCurrentScope: () => re().getScope(), getIsolationScope: () => re().getIsolationScope() };
1108
1033
  }
1109
- function Ae(t) {
1110
- let e = Te(t);
1034
+ function xe(t) {
1035
+ let e = ye(t);
1111
1036
  return e.acs ? e.acs : On();
1112
1037
  }
1113
- function Wt() {
1114
- let t = G();
1115
- return Ae(t).getCurrentScope();
1038
+ function $t() {
1039
+ let t = j();
1040
+ return xe(t).getCurrentScope();
1116
1041
  }
1117
1042
  function K() {
1118
- let t = G();
1119
- return Ae(t).getIsolationScope();
1043
+ let t = j();
1044
+ return xe(t).getIsolationScope();
1120
1045
  }
1121
1046
  function vn() {
1122
- return oe("globalScope", () => new C());
1047
+ return ee("globalScope", () => new C());
1123
1048
  }
1124
1049
  function wn() {
1125
- return Wt().getClient();
1050
+ return $t().getClient();
1126
1051
  }
1127
- var Kr = "_sentryMetrics";
1052
+ var Xr = "_sentryMetrics";
1128
1053
  function Dn(t) {
1129
- let e = t[Kr];
1054
+ let e = t[Xr];
1130
1055
  if (!e) return;
1131
1056
  let n = {};
1132
- for (let [, [r, s]] of e) n[r] || (n[r] = []), n[r].push(y(s));
1057
+ for (let [, [r, s]] of e) n[r] || (n[r] = []), n[r].push(S(s));
1133
1058
  return n;
1134
1059
  }
1135
1060
  var Mn = "sentry.source";
1136
1061
  var Pn = "sentry.sample_rate";
1137
1062
  var kn = "sentry.op";
1138
1063
  var Ln = "sentry.origin";
1139
- var Zr = 1;
1064
+ var Qr = 1;
1140
1065
  function Ye(t) {
1141
- let { spanId: e, traceId: n } = t.spanContext(), { parent_span_id: r } = ue(t);
1142
- return y({ parent_span_id: r, span_id: e, trace_id: n });
1066
+ let { spanId: e, traceId: n } = t.spanContext(), { parent_span_id: r } = se(t);
1067
+ return S({ parent_span_id: r, span_id: e, trace_id: n });
1143
1068
  }
1144
1069
  function Fn(t) {
1145
- return typeof t == "number" ? Un(t) : Array.isArray(t) ? t[0] + t[1] / 1e9 : t instanceof Date ? Un(t.getTime()) : _e();
1070
+ return typeof t == "number" ? Un(t) : Array.isArray(t) ? t[0] + t[1] / 1e9 : t instanceof Date ? Un(t.getTime()) : ge();
1146
1071
  }
1147
1072
  function Un(t) {
1148
1073
  return t > 9999999999 ? t / 1e3 : t;
1149
1074
  }
1150
- function ue(t) {
1151
- if (Qr(t)) return t.getSpanJSON();
1075
+ function se(t) {
1076
+ if (ts(t)) return t.getSpanJSON();
1152
1077
  try {
1153
1078
  let { spanId: e, traceId: n } = t.spanContext();
1154
- if (Xr(t)) {
1079
+ if (es(t)) {
1155
1080
  let { attributes: r, startTime: s, name: o, endTime: i, parentSpanId: a, status: c } = t;
1156
- return y({ span_id: e, trace_id: n, data: r, description: o, parent_span_id: a, start_timestamp: Fn(s), timestamp: Fn(i) || void 0, status: es(c), op: r[kn], origin: r[Ln], _metrics_summary: Dn(t) });
1081
+ return S({ span_id: e, trace_id: n, data: r, description: o, parent_span_id: a, start_timestamp: Fn(s), timestamp: Fn(i) || void 0, status: ns(c), op: r[kn], origin: r[Ln], _metrics_summary: Dn(t) });
1157
1082
  }
1158
1083
  return { span_id: e, trace_id: n };
1159
1084
  } catch {
1160
1085
  return {};
1161
1086
  }
1162
1087
  }
1163
- function Xr(t) {
1088
+ function es(t) {
1164
1089
  let e = t;
1165
1090
  return !!e.attributes && !!e.startTime && !!e.name && !!e.endTime && !!e.status;
1166
1091
  }
1167
- function Qr(t) {
1092
+ function ts(t) {
1168
1093
  return typeof t.getSpanJSON == "function";
1169
1094
  }
1170
1095
  function $n(t) {
1171
1096
  let { traceFlags: e } = t.spanContext();
1172
- return e === Zr;
1097
+ return e === Qr;
1173
1098
  }
1174
- function es(t) {
1099
+ function ns(t) {
1175
1100
  if (!(!t || t.code === 0)) return t.code === 1 ? "ok" : t.message || "unknown_error";
1176
1101
  }
1177
- var ts = "_sentryRootSpan";
1178
- function q(t) {
1179
- return t[ts] || t;
1102
+ var rs = "_sentryRootSpan";
1103
+ function G(t) {
1104
+ return t[rs] || t;
1180
1105
  }
1181
1106
  function Hn() {
1182
- let t = G(), e = Ae(t);
1183
- return e.getActiveSpan ? e.getActiveSpan() : W(Wt());
1107
+ let t = j(), e = xe(t);
1108
+ return e.getActiveSpan ? e.getActiveSpan() : W($t());
1184
1109
  }
1185
1110
  var Bn = false;
1186
1111
  function jn() {
1187
- Bn || (Bn = true, Ot(Kt), vt(Kt));
1112
+ Bn || (Bn = true, St(Ht), yt(Ht));
1188
1113
  }
1189
- function Kt() {
1190
- let t = Hn(), e = t && q(t);
1114
+ function Ht() {
1115
+ let t = Hn(), e = t && G(t);
1191
1116
  if (e) {
1192
1117
  let n = "internal_error";
1193
- _ && f.log(`[Tracing] Root span: ${n} -> Global error occured`), e.setStatus({ code: 2, message: n });
1118
+ _ && m.log(`[Tracing] Root span: ${n} -> Global error occured`), e.setStatus({ code: 2, message: n });
1194
1119
  }
1195
1120
  }
1196
- Kt.tag = "sentry_tracingErrorCallback";
1121
+ Ht.tag = "sentry_tracingErrorCallback";
1197
1122
  var Je = "production";
1198
- var ns = "_frozenDsc";
1199
- function be(t, e) {
1200
- let n = e.getOptions(), { publicKey: r } = e.getDsn() || {}, s = y({ environment: n.environment || Je, release: n.release, public_key: r, trace_id: t });
1123
+ var ss = "_frozenDsc";
1124
+ function Ae(t, e) {
1125
+ let n = e.getOptions(), { publicKey: r } = e.getDsn() || {}, s = S({ environment: n.environment || Je, release: n.release, public_key: r, trace_id: t });
1201
1126
  return e.emit("createDsc", s), s;
1202
1127
  }
1203
1128
  function Ve(t) {
1204
1129
  let e = wn();
1205
1130
  if (!e) return {};
1206
- let n = be(ue(t).trace_id || "", e), r = q(t);
1131
+ let n = Ae(se(t).trace_id || "", e), r = G(t);
1207
1132
  if (!r) return n;
1208
- let s = r[ns];
1133
+ let s = r[ss];
1209
1134
  if (s) return s;
1210
- let o = ue(r), i = o.data || {}, a = i[Pn];
1135
+ let o = se(r), i = o.data || {}, a = i[Pn];
1211
1136
  a != null && (n.sample_rate = `${a}`);
1212
1137
  let c = i[Mn];
1213
1138
  return c && c !== "url" && (n.transaction = o.description), n.sampled = String($n(r)), e.emit("createDsc", n), n;
@@ -1216,23 +1141,23 @@ function Gn(t) {
1216
1141
  if (typeof t == "boolean") return Number(t);
1217
1142
  let e = typeof t == "string" ? parseFloat(t) : t;
1218
1143
  if (typeof e != "number" || isNaN(e) || e < 0 || e > 1) {
1219
- _ && f.warn(`[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(t)} of type ${JSON.stringify(typeof t)}.`);
1144
+ _ && m.warn(`[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(t)} of type ${JSON.stringify(typeof t)}.`);
1220
1145
  return;
1221
1146
  }
1222
1147
  return e;
1223
1148
  }
1224
- function rs(t, e) {
1149
+ function os(t, e) {
1225
1150
  return e && (t.sdk = t.sdk || {}, t.sdk.name = t.sdk.name || e.name, t.sdk.version = t.sdk.version || e.version, t.sdk.integrations = [...t.sdk.integrations || [], ...e.integrations || []], t.sdk.packages = [...t.sdk.packages || [], ...e.packages || []]), t;
1226
1151
  }
1227
1152
  function qn(t, e, n, r) {
1228
- let s = qe(n), o = { sent_at: (/* @__PURE__ */ new Date()).toISOString(), ...s && { sdk: s }, ...!!r && e && { dsn: B(e) } }, i = "aggregates" in t ? [{ type: "sessions" }, t] : [{ type: "session" }, t.toJSON()];
1229
- return j(o, [i]);
1153
+ let s = qe(n), o = { sent_at: (/* @__PURE__ */ new Date()).toISOString(), ...s && { sdk: s }, ...!!r && e && { dsn: H(e) } }, i = "aggregates" in t ? [{ type: "sessions" }, t] : [{ type: "session" }, t.toJSON()];
1154
+ return B(o, [i]);
1230
1155
  }
1231
1156
  function zn(t, e, n, r) {
1232
1157
  let s = qe(n), o = t.type && t.type !== "replay_event" ? t.type : "event";
1233
- rs(t, n && n.sdk);
1234
- let i = Ht(t, s, r, e);
1235
- return delete t.sdkProcessingMetadata, j(i, [[{ type: o }, t]]);
1158
+ os(t, n && n.sdk);
1159
+ let i = vt(t, s, r, e);
1160
+ return delete t.sdkProcessingMetadata, B(i, [[{ type: o }, t]]);
1236
1161
  }
1237
1162
  function We(t, e, n, r = 0) {
1238
1163
  return new A((s, o) => {
@@ -1240,78 +1165,78 @@ function We(t, e, n, r = 0) {
1240
1165
  if (e === null || typeof i != "function") s(e);
1241
1166
  else {
1242
1167
  let a = i({ ...e }, n);
1243
- _ && i.id && a === null && f.log(`Event processor "${i.id}" dropped event`), P(a) ? a.then((c) => We(t, c, n, r + 1).then(s)).then(null, o) : We(t, a, n, r + 1).then(s).then(null, o);
1168
+ _ && i.id && a === null && m.log(`Event processor "${i.id}" dropped event`), D(a) ? a.then((c) => We(t, c, n, r + 1).then(s)).then(null, o) : We(t, a, n, r + 1).then(s).then(null, o);
1244
1169
  }
1245
1170
  });
1246
1171
  }
1247
1172
  function Yn(t, e) {
1248
1173
  let { fingerprint: n, span: r, breadcrumbs: s, sdkProcessingMetadata: o } = e;
1249
- ss(t, e), r && as(t, r), cs(t, n), os(t, s), is(t, o);
1174
+ is(t, e), r && us(t, r), ls(t, n), as(t, s), cs(t, o);
1250
1175
  }
1251
- function Zt(t, e) {
1252
- let { extra: n, tags: r, user: s, contexts: o, level: i, sdkProcessingMetadata: a, breadcrumbs: c, fingerprint: u, eventProcessors: l, attachments: p, propagationContext: m, transactionName: d, span: g } = e;
1253
- Re(t, "extra", n), Re(t, "tags", r), Re(t, "user", s), Re(t, "contexts", o), Re(t, "sdkProcessingMetadata", a), i && (t.level = i), d && (t.transactionName = d), g && (t.span = g), c.length && (t.breadcrumbs = [...t.breadcrumbs, ...c]), u.length && (t.fingerprint = [...t.fingerprint, ...u]), l.length && (t.eventProcessors = [...t.eventProcessors, ...l]), p.length && (t.attachments = [...t.attachments, ...p]), t.propagationContext = { ...t.propagationContext, ...m };
1176
+ function Bt(t, e) {
1177
+ let { extra: n, tags: r, user: s, contexts: o, level: i, sdkProcessingMetadata: a, breadcrumbs: c, fingerprint: u, eventProcessors: l, attachments: p, propagationContext: f, transactionName: d, span: g } = e;
1178
+ be(t, "extra", n), be(t, "tags", r), be(t, "user", s), be(t, "contexts", o), be(t, "sdkProcessingMetadata", a), i && (t.level = i), d && (t.transactionName = d), g && (t.span = g), c.length && (t.breadcrumbs = [...t.breadcrumbs, ...c]), u.length && (t.fingerprint = [...t.fingerprint, ...u]), l.length && (t.eventProcessors = [...t.eventProcessors, ...l]), p.length && (t.attachments = [...t.attachments, ...p]), t.propagationContext = { ...t.propagationContext, ...f };
1254
1179
  }
1255
- function Re(t, e, n) {
1180
+ function be(t, e, n) {
1256
1181
  if (n && Object.keys(n).length) {
1257
1182
  t[e] = { ...t[e] };
1258
1183
  for (let r in n) Object.prototype.hasOwnProperty.call(n, r) && (t[e][r] = n[r]);
1259
1184
  }
1260
1185
  }
1261
- function ss(t, e) {
1262
- let { extra: n, tags: r, user: s, contexts: o, level: i, transactionName: a } = e, c = y(n);
1186
+ function is(t, e) {
1187
+ let { extra: n, tags: r, user: s, contexts: o, level: i, transactionName: a } = e, c = S(n);
1263
1188
  c && Object.keys(c).length && (t.extra = { ...c, ...t.extra });
1264
- let u = y(r);
1189
+ let u = S(r);
1265
1190
  u && Object.keys(u).length && (t.tags = { ...u, ...t.tags });
1266
- let l = y(s);
1191
+ let l = S(s);
1267
1192
  l && Object.keys(l).length && (t.user = { ...l, ...t.user });
1268
- let p = y(o);
1193
+ let p = S(o);
1269
1194
  p && Object.keys(p).length && (t.contexts = { ...p, ...t.contexts }), i && (t.level = i), a && t.type !== "transaction" && (t.transaction = a);
1270
1195
  }
1271
- function os(t, e) {
1196
+ function as(t, e) {
1272
1197
  let n = [...t.breadcrumbs || [], ...e];
1273
1198
  t.breadcrumbs = n.length ? n : void 0;
1274
1199
  }
1275
- function is(t, e) {
1200
+ function cs(t, e) {
1276
1201
  t.sdkProcessingMetadata = { ...t.sdkProcessingMetadata, ...e };
1277
1202
  }
1278
- function as(t, e) {
1203
+ function us(t, e) {
1279
1204
  t.contexts = { trace: Ye(e), ...t.contexts }, t.sdkProcessingMetadata = { dynamicSamplingContext: Ve(e), ...t.sdkProcessingMetadata };
1280
- let n = q(e), r = ue(n).description;
1205
+ let n = G(e), r = se(n).description;
1281
1206
  r && !t.transaction && t.type === "transaction" && (t.transaction = r);
1282
1207
  }
1283
- function cs(t, e) {
1284
- t.fingerprint = t.fingerprint ? Se(t.fingerprint) : [], e && (t.fingerprint = t.fingerprint.concat(e)), t.fingerprint && !t.fingerprint.length && delete t.fingerprint;
1208
+ function ls(t, e) {
1209
+ t.fingerprint = t.fingerprint ? Ee(t.fingerprint) : [], e && (t.fingerprint = t.fingerprint.concat(e)), t.fingerprint && !t.fingerprint.length && delete t.fingerprint;
1285
1210
  }
1286
1211
  function Vn(t, e, n, r, s, o) {
1287
- let { normalizeDepth: i = 3, normalizeMaxBreadth: a = 1e3 } = t, c = { ...e, event_id: e.event_id || n.event_id || x(), timestamp: e.timestamp || ie() }, u = n.integrations || t.integrations.map((T) => T.name);
1288
- us(c, t), ds(c, u), e.type === void 0 && ls(c, t.stackParser);
1289
- let l = ms(r, n.captureContext);
1212
+ let { normalizeDepth: i = 3, normalizeMaxBreadth: a = 1e3 } = t, c = { ...e, event_id: e.event_id || n.event_id || x(), timestamp: e.timestamp || te() }, u = n.integrations || t.integrations.map((T) => T.name);
1213
+ ps(c, t), ms(c, u), e.type === void 0 && ds(c, t.stackParser);
1214
+ let l = gs(r, n.captureContext);
1290
1215
  n.mechanism && J(c, n.mechanism);
1291
- let p = s ? s.getEventProcessors() : [], m = vn().getScopeData();
1216
+ let p = s ? s.getEventProcessors() : [], f = vn().getScopeData();
1292
1217
  if (o) {
1293
1218
  let T = o.getScopeData();
1294
- Zt(m, T);
1219
+ Bt(f, T);
1295
1220
  }
1296
1221
  if (l) {
1297
1222
  let T = l.getScopeData();
1298
- Zt(m, T);
1223
+ Bt(f, T);
1299
1224
  }
1300
- let d = [...n.attachments || [], ...m.attachments];
1301
- d.length && (n.attachments = d), Yn(c, m);
1302
- let g = [...p, ...m.eventProcessors];
1303
- return We(g, c, n).then((T) => (T && ps(T), typeof i == "number" && i > 0 ? fs(T, i, a) : T));
1225
+ let d = [...n.attachments || [], ...f.attachments];
1226
+ d.length && (n.attachments = d), Yn(c, f);
1227
+ let g = [...p, ...f.eventProcessors];
1228
+ return We(g, c, n).then((T) => (T && fs(T), typeof i == "number" && i > 0 ? hs(T, i, a) : T));
1304
1229
  }
1305
- function us(t, e) {
1230
+ function ps(t, e) {
1306
1231
  let { environment: n, release: r, dist: s, maxValueLength: o = 250 } = e;
1307
- "environment" in t || (t.environment = "environment" in e ? n : Je), t.release === void 0 && r !== void 0 && (t.release = r), t.dist === void 0 && s !== void 0 && (t.dist = s), t.message && (t.message = U(t.message, o));
1232
+ "environment" in t || (t.environment = "environment" in e ? n : Je), t.release === void 0 && r !== void 0 && (t.release = r), t.dist === void 0 && s !== void 0 && (t.dist = s), t.message && (t.message = F(t.message, o));
1308
1233
  let i = t.exception && t.exception.values && t.exception.values[0];
1309
- i && i.value && (i.value = U(i.value, o));
1234
+ i && i.value && (i.value = F(i.value, o));
1310
1235
  let a = t.request;
1311
- a && a.url && (a.url = U(a.url, o));
1236
+ a && a.url && (a.url = F(a.url, o));
1312
1237
  }
1313
1238
  var Jn = /* @__PURE__ */ new WeakMap();
1314
- function ls(t, e) {
1239
+ function ds(t, e) {
1315
1240
  let n = h._sentryDebugIds;
1316
1241
  if (!n) return;
1317
1242
  let r, s = Jn.get(e);
@@ -1337,7 +1262,7 @@ function ls(t, e) {
1337
1262
  } catch {
1338
1263
  }
1339
1264
  }
1340
- function ps(t) {
1265
+ function fs(t) {
1341
1266
  let e = {};
1342
1267
  try {
1343
1268
  t.exception.values.forEach((r) => {
@@ -1354,15 +1279,15 @@ function ps(t) {
1354
1279
  n.push({ type: "sourcemap", code_file: r, debug_id: e[r] });
1355
1280
  });
1356
1281
  }
1357
- function ds(t, e) {
1282
+ function ms(t, e) {
1358
1283
  e.length > 0 && (t.sdk = t.sdk || {}, t.sdk.integrations = [...t.sdk.integrations || [], ...e]);
1359
1284
  }
1360
- function fs(t, e, n) {
1285
+ function hs(t, e, n) {
1361
1286
  if (!t) return null;
1362
1287
  let r = { ...t, ...t.breadcrumbs && { breadcrumbs: t.breadcrumbs.map((s) => ({ ...s, ...s.data && { data: v(s.data, e, n) } })) }, ...t.user && { user: v(t.user, e, n) }, ...t.contexts && { contexts: v(t.contexts, e, n) }, ...t.extra && { extra: v(t.extra, e, n) } };
1363
1288
  return t.contexts && t.contexts.trace && r.contexts && (r.contexts.trace = t.contexts.trace, t.contexts.trace.data && (r.contexts.trace.data = v(t.contexts.trace.data, e, n))), t.spans && (r.spans = t.spans.map((s) => ({ ...s, ...s.data && { data: v(s.data, e, n) } }))), r;
1364
1289
  }
1365
- function ms(t, e) {
1290
+ function gs(t, e) {
1366
1291
  if (!e) return t;
1367
1292
  let n = t ? t.clone() : new C();
1368
1293
  return n.update(e), n;
@@ -1377,7 +1302,7 @@ var Ke = class {
1377
1302
  }
1378
1303
  getSessionAggregates() {
1379
1304
  let e = Object.keys(this._pendingAggregates).map((r) => this._pendingAggregates[parseInt(r)]), n = { attrs: this._sessionAttrs, aggregates: e };
1380
- return y(n);
1305
+ return S(n);
1381
1306
  }
1382
1307
  close() {
1383
1308
  clearInterval(this._intervalId), this._isEnabled = false, this.flush();
@@ -1401,36 +1326,36 @@ var Ke = class {
1401
1326
  }
1402
1327
  }
1403
1328
  };
1404
- var hs = "7";
1405
- function gs(t) {
1329
+ var _s = "7";
1330
+ function Es(t) {
1406
1331
  let e = t.protocol ? `${t.protocol}:` : "", n = t.port ? `:${t.port}` : "";
1407
1332
  return `${e}//${t.host}${n}${t.path ? `/${t.path}` : ""}/api/`;
1408
1333
  }
1409
- function _s(t) {
1410
- return `${gs(t)}${t.projectId}/envelope/`;
1334
+ function Ss(t) {
1335
+ return `${Es(t)}${t.projectId}/envelope/`;
1411
1336
  }
1412
- function Es(t, e) {
1413
- return Rt({ sentry_key: t.publicKey, sentry_version: hs, ...e && { sentry_client: `${e.name}/${e.version}` } });
1337
+ function ys(t, e) {
1338
+ return gt({ sentry_key: t.publicKey, sentry_version: _s, ...e && { sentry_client: `${e.name}/${e.version}` } });
1414
1339
  }
1415
1340
  function Wn(t, e, n) {
1416
- return e || `${_s(t)}?${Es(t, n)}`;
1341
+ return e || `${Ss(t)}?${ys(t, n)}`;
1417
1342
  }
1418
1343
  var Kn = [];
1419
- function Ss(t) {
1344
+ function Ts(t) {
1420
1345
  let e = {};
1421
1346
  return t.forEach((n) => {
1422
1347
  let { name: r } = n, s = e[r];
1423
1348
  s && !s.isDefaultInstance && n.isDefaultInstance || (e[r] = n);
1424
1349
  }), Object.keys(e).map((n) => e[n]);
1425
1350
  }
1426
- function Xt(t) {
1351
+ function jt(t) {
1427
1352
  let e = t.defaultIntegrations || [], n = t.integrations;
1428
1353
  e.forEach((i) => {
1429
1354
  i.isDefaultInstance = true;
1430
1355
  });
1431
1356
  let r;
1432
- Array.isArray(n) ? r = [...e, ...n] : typeof n == "function" ? r = Se(n(e)) : r = e;
1433
- let s = Ss(r), o = ys(s, (i) => i.name === "Debug");
1357
+ Array.isArray(n) ? r = [...e, ...n] : typeof n == "function" ? r = Ee(n(e)) : r = e;
1358
+ let s = Ts(r), o = Is(s, (i) => i.name === "Debug");
1434
1359
  if (o !== -1) {
1435
1360
  let [i] = s.splice(o, 1);
1436
1361
  s.push(i);
@@ -1440,15 +1365,15 @@ function Xt(t) {
1440
1365
  function Zn(t, e) {
1441
1366
  let n = {};
1442
1367
  return e.forEach((r) => {
1443
- r && en(t, r, n);
1368
+ r && qt(t, r, n);
1444
1369
  }), n;
1445
1370
  }
1446
- function Qt(t, e) {
1371
+ function Gt(t, e) {
1447
1372
  for (let n of e) n && n.afterAllSetup && n.afterAllSetup(t);
1448
1373
  }
1449
- function en(t, e, n) {
1374
+ function qt(t, e, n) {
1450
1375
  if (n[e.name]) {
1451
- _ && f.log(`Integration skipped because it was already installed: ${e.name}`);
1376
+ _ && m.log(`Integration skipped because it was already installed: ${e.name}`);
1452
1377
  return;
1453
1378
  }
1454
1379
  if (n[e.name] = e, Kn.indexOf(e.name) === -1 && typeof e.setupOnce == "function" && (e.setupOnce(), Kn.push(e.name)), e.setup && typeof e.setup == "function" && e.setup(t), typeof e.preprocessEvent == "function") {
@@ -1459,38 +1384,38 @@ function en(t, e, n) {
1459
1384
  let r = e.processEvent.bind(e), s = Object.assign((o, i) => r(o, i, t), { id: e.name });
1460
1385
  t.addEventProcessor(s);
1461
1386
  }
1462
- _ && f.log(`Integration installed: ${e.name}`);
1387
+ _ && m.log(`Integration installed: ${e.name}`);
1463
1388
  }
1464
- function ys(t, e) {
1389
+ function Is(t, e) {
1465
1390
  for (let n = 0; n < t.length; n++) if (e(t[n]) === true) return n;
1466
1391
  return -1;
1467
1392
  }
1468
1393
  var Xn = "Not capturing exception because it's already been captured.";
1469
1394
  var Ze = class {
1470
1395
  constructor(e) {
1471
- if (this._options = e, this._integrations = {}, this._numProcessing = 0, this._outcomes = {}, this._hooks = {}, this._eventProcessors = [], e.dsn ? this._dsn = we(e.dsn) : _ && f.warn("No DSN provided, client will not send events."), this._dsn) {
1396
+ if (this._options = e, this._integrations = {}, this._numProcessing = 0, this._outcomes = {}, this._hooks = {}, this._eventProcessors = [], e.dsn ? this._dsn = we(e.dsn) : _ && m.warn("No DSN provided, client will not send events."), this._dsn) {
1472
1397
  let n = Wn(this._dsn, e.tunnel, e._metadata ? e._metadata.sdk : void 0);
1473
1398
  this._transport = e.transport({ tunnel: this._options.tunnel, recordDroppedEvent: this.recordDroppedEvent.bind(this), ...e.transportOptions, url: n });
1474
1399
  }
1475
1400
  }
1476
1401
  captureException(e, n, r) {
1477
1402
  let s = x();
1478
- if (Be(e)) return _ && f.log(Xn), s;
1403
+ if (Be(e)) return _ && m.log(Xn), s;
1479
1404
  let o = { event_id: s, ...n };
1480
1405
  return this._process(this.eventFromException(e, o).then((i) => this._captureEvent(i, o, r))), o.event_id;
1481
1406
  }
1482
1407
  captureMessage(e, n, r, s) {
1483
- let o = { event_id: x(), ...r }, i = se(e) ? e : String(e), a = Oe(e) ? this.eventFromMessage(i, n, o) : this.eventFromException(e, o);
1408
+ let o = { event_id: x(), ...r }, i = Q(e) ? e : String(e), a = Oe(e) ? this.eventFromMessage(i, n, o) : this.eventFromException(e, o);
1484
1409
  return this._process(a.then((c) => this._captureEvent(c, o, s))), o.event_id;
1485
1410
  }
1486
1411
  captureEvent(e, n, r) {
1487
1412
  let s = x();
1488
- if (n && n.originalException && Be(n.originalException)) return _ && f.log(Xn), s;
1413
+ if (n && n.originalException && Be(n.originalException)) return _ && m.log(Xn), s;
1489
1414
  let o = { event_id: s, ...n }, a = (e.sdkProcessingMetadata || {}).capturedSpanScope;
1490
1415
  return this._process(this._captureEvent(e, o, a || r)), o.event_id;
1491
1416
  }
1492
1417
  captureSession(e) {
1493
- typeof e.release != "string" ? _ && f.warn("Discarded session because of missing or non-string release") : (this.sendSession(e), Ie(e, { init: false }));
1418
+ typeof e.release != "string" ? _ && m.warn("Discarded session because of missing or non-string release") : (this.sendSession(e), Te(e, { init: false }));
1494
1419
  }
1495
1420
  getDsn() {
1496
1421
  return this._dsn;
@@ -1525,12 +1450,12 @@ var Ze = class {
1525
1450
  }
1526
1451
  addIntegration(e) {
1527
1452
  let n = this._integrations[e.name];
1528
- en(this, e, this._integrations), n || Qt(this, [e]);
1453
+ qt(this, e, this._integrations), n || Gt(this, [e]);
1529
1454
  }
1530
1455
  sendEvent(e, n = {}) {
1531
1456
  this.emit("beforeSendEvent", e, n);
1532
1457
  let r = zn(e, this._dsn, this._options._metadata, this._options.tunnel);
1533
- for (let o of n.attachments || []) r = Ft(r, $t(o));
1458
+ for (let o of n.attachments || []) r = Ct(r, Ot(o));
1534
1459
  let s = this.sendEnvelope(r);
1535
1460
  s && s.then((o) => this.emit("afterSendEvent", e, o), null);
1536
1461
  }
@@ -1541,7 +1466,7 @@ var Ze = class {
1541
1466
  recordDroppedEvent(e, n, r) {
1542
1467
  if (this._options.sendClientReports) {
1543
1468
  let s = `${e}:${n}`;
1544
- _ && f.log(`Adding outcome: "${s}"`), this._outcomes[s] = this._outcomes[s] + 1 || 1;
1469
+ _ && m.log(`Adding outcome: "${s}"`), this._outcomes[s] = this._outcomes[s] + 1 || 1;
1545
1470
  }
1546
1471
  }
1547
1472
  on(e, n) {
@@ -1551,11 +1476,11 @@ var Ze = class {
1551
1476
  this._hooks[e] && this._hooks[e].forEach((r) => r(...n));
1552
1477
  }
1553
1478
  sendEnvelope(e) {
1554
- return this.emit("beforeEnvelope", e), this._isEnabled() && this._transport ? this._transport.send(e).then(null, (n) => (_ && f.error("Error while sending event:", n), n)) : (_ && f.error("Transport disabled"), R({}));
1479
+ return this.emit("beforeEnvelope", e), this._isEnabled() && this._transport ? this._transport.send(e).then(null, (n) => (_ && m.error("Error while sending event:", n), n)) : (_ && m.error("Transport disabled"), R({}));
1555
1480
  }
1556
1481
  _setupIntegrations() {
1557
1482
  let { integrations: e } = this._options;
1558
- this._integrations = Zn(this, e), Qt(this, e);
1483
+ this._integrations = Zn(this, e), Gt(this, e);
1559
1484
  }
1560
1485
  _updateSessionFromEvent(e, n) {
1561
1486
  let r = false, s = false, o = n.exception && n.exception.values;
@@ -1570,7 +1495,7 @@ var Ze = class {
1570
1495
  }
1571
1496
  }
1572
1497
  let i = e.status === "ok";
1573
- (i && e.errors === 0 || i && r) && (Ie(e, { ...r && { status: "crashed" }, errors: e.errors || Number(s || r) }), this.captureSession(e));
1498
+ (i && e.errors === 0 || i && r) && (Te(e, { ...r && { status: "crashed" }, errors: e.errors || Number(s || r) }), this.captureSession(e));
1574
1499
  }
1575
1500
  _isClientDoneProcessing(e) {
1576
1501
  return new A((n) => {
@@ -1588,9 +1513,9 @@ var Ze = class {
1588
1513
  if (a === null) return a;
1589
1514
  let c = { ...s.getPropagationContext(), ...r ? r.getPropagationContext() : void 0 };
1590
1515
  if (!(a.contexts && a.contexts.trace) && c) {
1591
- let { traceId: l, spanId: p, parentSpanId: m, dsc: d } = c;
1592
- a.contexts = { trace: y({ trace_id: l, span_id: p, parent_span_id: m }), ...a.contexts };
1593
- let g = d || be(l, this);
1516
+ let { traceId: l, spanId: p, parentSpanId: f, dsc: d } = c;
1517
+ a.contexts = { trace: S({ trace_id: l, span_id: p, parent_span_id: f }), ...a.contexts };
1518
+ let g = d || Ae(l, this);
1594
1519
  a.sdkProcessingMetadata = { dynamicSamplingContext: g, ...a.sdkProcessingMetadata };
1595
1520
  }
1596
1521
  return a;
@@ -1600,7 +1525,7 @@ var Ze = class {
1600
1525
  return this._processEvent(e, n, r).then((s) => s.event_id, (s) => {
1601
1526
  if (_) {
1602
1527
  let o = s;
1603
- o.logLevel === "log" ? f.log(o.message) : f.warn(o);
1528
+ o.logLevel === "log" ? m.log(o.message) : m.warn(o);
1604
1529
  }
1605
1530
  });
1606
1531
  }
@@ -1611,8 +1536,8 @@ var Ze = class {
1611
1536
  return this._prepareEvent(e, n, r, d).then((g) => {
1612
1537
  if (g === null) throw this.recordDroppedEvent("event_processor", p, e), new b("An event processor returned `null`, will not send event.", "log");
1613
1538
  if (n.data && n.data.__sentry__ === true) return g;
1614
- let T = Is(s, g, n);
1615
- return Ts(T, u);
1539
+ let T = As(s, g, n);
1540
+ return xs(T, u);
1616
1541
  }).then((g) => {
1617
1542
  if (g === null) throw this.recordDroppedEvent("before_send", p, e), new b(`${u} returned \`null\`, will not send event.`, "log");
1618
1543
  let Z = r && r.getSession();
@@ -1639,9 +1564,9 @@ Reason: ${g}`));
1639
1564
  });
1640
1565
  }
1641
1566
  };
1642
- function Ts(t, e) {
1567
+ function xs(t, e) {
1643
1568
  let n = `${e} must return \`null\` or a valid event.`;
1644
- if (P(t)) return t.then((r) => {
1569
+ if (D(t)) return t.then((r) => {
1645
1570
  if (!O(r) && r !== null) throw new b(n);
1646
1571
  return r;
1647
1572
  }, (r) => {
@@ -1650,7 +1575,7 @@ function Ts(t, e) {
1650
1575
  if (!O(t) && t !== null) throw new b(n);
1651
1576
  return t;
1652
1577
  }
1653
- function Is(t, e, n) {
1578
+ function As(t, e, n) {
1654
1579
  let { beforeSend: r, beforeSendTransaction: s, beforeSendSpan: o } = t;
1655
1580
  if (Qn(e) && r) return r(e, n);
1656
1581
  if (er(e)) {
@@ -1674,22 +1599,22 @@ function er(t) {
1674
1599
  }
1675
1600
  function tr(t, e, n, r, s) {
1676
1601
  let o = { sent_at: (/* @__PURE__ */ new Date()).toISOString() };
1677
- n && n.sdk && (o.sdk = { name: n.sdk.name, version: n.sdk.version }), r && s && (o.dsn = B(s)), e && (o.trace = y(e));
1678
- let i = xs(t);
1679
- return j(o, [i]);
1602
+ n && n.sdk && (o.sdk = { name: n.sdk.name, version: n.sdk.version }), r && s && (o.dsn = H(s)), e && (o.trace = S(e));
1603
+ let i = bs(t);
1604
+ return B(o, [i]);
1680
1605
  }
1681
- function xs(t) {
1606
+ function bs(t) {
1682
1607
  return [{ type: "check_in" }, t];
1683
1608
  }
1684
- var Ce = class extends Ze {
1609
+ var Re = class extends Ze {
1685
1610
  constructor(e) {
1686
1611
  jn(), super(e);
1687
1612
  }
1688
1613
  eventFromException(e, n) {
1689
- return R(qt(this, this._options.stackParser, e, n));
1614
+ return R(Pt(this, this._options.stackParser, e, n));
1690
1615
  }
1691
1616
  eventFromMessage(e, n = "info", r) {
1692
- return R(zt(this._options.stackParser, e, n, r, this._options.attachStacktrace));
1617
+ return R(kt(this._options.stackParser, e, n, r, this._options.attachStacktrace));
1693
1618
  }
1694
1619
  captureException(e, n, r) {
1695
1620
  if (this._options.autoSessionTracking && this._sessionFlusher) {
@@ -1710,20 +1635,20 @@ var Ce = class extends Ze {
1710
1635
  }
1711
1636
  initSessionFlusher() {
1712
1637
  let { release: e, environment: n } = this._options;
1713
- e ? this._sessionFlusher = new Ke(this, { release: e, environment: n }) : _ && f.warn("Cannot initialise an instance of SessionFlusher if no release is provided!");
1638
+ e ? this._sessionFlusher = new Ke(this, { release: e, environment: n }) : _ && m.warn("Cannot initialise an instance of SessionFlusher if no release is provided!");
1714
1639
  }
1715
1640
  captureCheckIn(e, n, r) {
1716
1641
  let s = "checkInId" in e && e.checkInId ? e.checkInId : x();
1717
- if (!this._isEnabled()) return _ && f.warn("SDK not enabled, will not capture checkin."), s;
1642
+ if (!this._isEnabled()) return _ && m.warn("SDK not enabled, will not capture checkin."), s;
1718
1643
  let o = this.getOptions(), { release: i, environment: a, tunnel: c } = o, u = { check_in_id: s, monitor_slug: e.monitorSlug, status: e.status, release: i, environment: a };
1719
1644
  "duration" in e && (u.duration = e.duration), n && (u.monitor_config = { schedule: n.schedule, checkin_margin: n.checkinMargin, max_runtime: n.maxRuntime, timezone: n.timezone, failure_issue_threshold: n.failureIssueThreshold, recovery_threshold: n.recoveryThreshold });
1720
1645
  let [l, p] = this._getTraceInfoFromScope(r);
1721
1646
  p && (u.contexts = { trace: p });
1722
- let m = tr(u, l, this.getSdkMetadata(), c, this.getDsn());
1723
- return _ && f.info("Sending checkin:", e.monitorSlug, e.status), this.sendEnvelope(m), s;
1647
+ let f = tr(u, l, this.getSdkMetadata(), c, this.getDsn());
1648
+ return _ && m.info("Sending checkin:", e.monitorSlug, e.status), this.sendEnvelope(f), s;
1724
1649
  }
1725
1650
  _captureRequestSession() {
1726
- this._sessionFlusher ? this._sessionFlusher.incrementSessionStatusCount() : _ && f.warn("Discarded request mode session because autoSessionTracking option was disabled");
1651
+ this._sessionFlusher ? this._sessionFlusher.incrementSessionStatusCount() : _ && m.warn("Discarded request mode session because autoSessionTracking option was disabled");
1727
1652
  }
1728
1653
  _prepareEvent(e, n, r, s) {
1729
1654
  return this._options.platform && (e.platform = e.platform || this._options.platform), this._options.runtime && (e.contexts = { ...e.contexts, runtime: (e.contexts || {}).runtime || this._options.runtime }), this._options.serverName && (e.server_name = e.server_name || this._options.serverName), super._prepareEvent(e, n, r, s);
@@ -1732,35 +1657,35 @@ var Ce = class extends Ze {
1732
1657
  if (!e) return [void 0, void 0];
1733
1658
  let n = W(e);
1734
1659
  if (n) {
1735
- let c = q(n);
1660
+ let c = G(n);
1736
1661
  return [Ve(c), Ye(c)];
1737
1662
  }
1738
1663
  let { traceId: r, spanId: s, parentSpanId: o, dsc: i } = e.getPropagationContext(), a = { trace_id: r, span_id: s, parent_span_id: o };
1739
- return i ? [i, a] : [be(r, this), a];
1664
+ return i ? [i, a] : [Ae(r, this), a];
1740
1665
  }
1741
1666
  };
1742
- var As = 64;
1743
- function tn(t, e, n = Pt(t.bufferSize || As)) {
1667
+ var Rs = 64;
1668
+ function zt(t, e, n = At(t.bufferSize || Rs)) {
1744
1669
  let r = {}, s = (i) => n.drain(i);
1745
1670
  function o(i) {
1746
1671
  let a = [];
1747
- if (je(i, (p, m) => {
1748
- let d = Ge(m);
1749
- if (Bt(r, d)) {
1750
- let g = nr(p, m);
1672
+ if (je(i, (p, f) => {
1673
+ let d = Ge(f);
1674
+ if (wt(r, d)) {
1675
+ let g = nr(p, f);
1751
1676
  t.recordDroppedEvent("ratelimit_backoff", d, g);
1752
1677
  } else a.push(p);
1753
1678
  }), a.length === 0) return R({});
1754
- let c = j(i[0], a), u = (p) => {
1755
- je(c, (m, d) => {
1756
- let g = nr(m, d);
1679
+ let c = B(i[0], a), u = (p) => {
1680
+ je(c, (f, d) => {
1681
+ let g = nr(f, d);
1757
1682
  t.recordDroppedEvent(p, Ge(d), g);
1758
1683
  });
1759
- }, l = () => e({ body: Ut(c) }).then((p) => (p.statusCode !== void 0 && (p.statusCode < 200 || p.statusCode >= 300) && _ && f.warn(`Sentry responded with status code ${p.statusCode} to sent event.`), r = jt(r, p), p), (p) => {
1684
+ }, l = () => e({ body: Nt(c) }).then((p) => (p.statusCode !== void 0 && (p.statusCode < 200 || p.statusCode >= 300) && _ && m.warn(`Sentry responded with status code ${p.statusCode} to sent event.`), r = Dt(r, p), p), (p) => {
1760
1685
  throw u("network_error"), p;
1761
1686
  });
1762
1687
  return n.add(l).then((p) => p, (p) => {
1763
- if (p instanceof b) return _ && f.error("Skipped sending event because buffer is full."), u("queue_overflow"), R({});
1688
+ if (p instanceof b) return _ && m.error("Skipped sending event because buffer is full."), u("queue_overflow"), R({});
1764
1689
  throw p;
1765
1690
  });
1766
1691
  }
@@ -1769,9 +1694,9 @@ function tn(t, e, n = Pt(t.bufferSize || As)) {
1769
1694
  function nr(t, e) {
1770
1695
  if (!(e !== "event" && e !== "transaction")) return Array.isArray(t) ? t[1] : void 0;
1771
1696
  }
1772
- var bs = "RewriteFrames";
1697
+ var Cs = "RewriteFrames";
1773
1698
  var Xe = (t = {}) => {
1774
- let e = t.root, n = t.prefix || "app:///", r = "window" in h && h.window !== void 0, s = t.iteratee || Rs({ isBrowser: r, root: e, prefix: n });
1699
+ let e = t.root, n = t.prefix || "app:///", r = "window" in h && h.window !== void 0, s = t.iteratee || Ns({ isBrowser: r, root: e, prefix: n });
1775
1700
  function o(a) {
1776
1701
  try {
1777
1702
  return { ...a, exception: { ...a.exception, values: a.exception.values.map((c) => ({ ...c, ...c.stacktrace && { stacktrace: i(c.stacktrace) } })) } };
@@ -1782,12 +1707,12 @@ var Xe = (t = {}) => {
1782
1707
  function i(a) {
1783
1708
  return { ...a, frames: a && a.frames && a.frames.map((c) => s(c)) };
1784
1709
  }
1785
- return { name: bs, processEvent(a) {
1710
+ return { name: Cs, processEvent(a) {
1786
1711
  let c = a;
1787
1712
  return a.exception && Array.isArray(a.exception.values) && (c = o(c)), c;
1788
1713
  } };
1789
1714
  };
1790
- function Rs({ isBrowser: t, root: e, prefix: n }) {
1715
+ function Ns({ isBrowser: t, root: e, prefix: n }) {
1791
1716
  return (r) => {
1792
1717
  if (!r.filename) return r;
1793
1718
  let s = /^[a-zA-Z]:\\/.test(r.filename) || r.filename.includes("\\") && !r.filename.includes("/"), o = /^\//.test(r.filename);
@@ -1797,7 +1722,7 @@ function Rs({ isBrowser: t, root: e, prefix: n }) {
1797
1722
  i.indexOf(e) === 0 && (r.filename = i.replace(e, n));
1798
1723
  }
1799
1724
  } else if (s || o) {
1800
- let i = s ? r.filename.replace(/^[a-zA-Z]:/, "").replace(/\\/g, "/") : r.filename, a = e ? Mt(e, i) : ye(i);
1725
+ let i = s ? r.filename.replace(/^[a-zA-Z]:/, "").replace(/\\/g, "/") : r.filename, a = e ? xt(e, i) : Se(i);
1801
1726
  r.filename = `${n}${a}`;
1802
1727
  }
1803
1728
  return r;
@@ -1806,13 +1731,13 @@ function Rs({ isBrowser: t, root: e, prefix: n }) {
1806
1731
  function sr(t) {
1807
1732
  return typeof t == "object" && t !== null;
1808
1733
  }
1809
- function Ns(t) {
1734
+ function vs(t) {
1810
1735
  return sr(t) && "handled" in t && typeof t.handled == "boolean" && "type" in t && typeof t.type == "string";
1811
1736
  }
1812
- function Os(t) {
1813
- return sr(t) && "mechanism" in t && Ns(t.mechanism);
1737
+ function ws(t) {
1738
+ return sr(t) && "mechanism" in t && vs(t.mechanism);
1814
1739
  }
1815
- function vs() {
1740
+ function Ds() {
1816
1741
  if (h.SENTRY_RELEASE && h.SENTRY_RELEASE.id) return h.SENTRY_RELEASE.id;
1817
1742
  }
1818
1743
  function rr(t, e) {
@@ -1821,28 +1746,28 @@ function rr(t, e) {
1821
1746
  function or(t, e) {
1822
1747
  return t(e.stack || "", 1);
1823
1748
  }
1824
- function ws(t) {
1749
+ function Ms(t) {
1825
1750
  let e = t && t.message;
1826
1751
  return e ? e.error && typeof e.error.message == "string" ? e.error.message : e : "No error message";
1827
1752
  }
1828
1753
  function ir(t, e) {
1829
- let n = { type: e.name || e.constructor.name, value: ws(e) }, r = or(t, e);
1754
+ let n = { type: e.name || e.constructor.name, value: Ms(e) }, r = or(t, e);
1830
1755
  return r.length && (n.stacktrace = { frames: r }), n.type === void 0 && n.value === "" && (n.value = "Unrecoverable error caught"), n;
1831
1756
  }
1832
- function Ds(t, e, n, r) {
1833
- let s, i = (r && r.data && Os(r.data) ? r.data.mechanism : void 0) ?? { handled: true, type: "generic" };
1757
+ function Ps(t, e, n, r) {
1758
+ let s, i = (r && r.data && ws(r.data) ? r.data.mechanism : void 0) ?? { handled: true, type: "generic" };
1834
1759
  if (z(n)) s = n;
1835
1760
  else {
1836
1761
  if (O(n)) {
1837
- let c = `Non-Error exception captured with keys: ${me(n)}`, u = t?.getClient(), l = u && u.getOptions().normalizeDepth;
1838
- t?.setExtra("__serialized__", ae(n, l)), s = r && r.syntheticException || new Error(c), s.message = c;
1762
+ let c = `Non-Error exception captured with keys: ${fe(n)}`, u = t?.getClient(), l = u && u.getOptions().normalizeDepth;
1763
+ t?.setExtra("__serialized__", ne(n, l)), s = r && r.syntheticException || new Error(c), s.message = c;
1839
1764
  } else s = r && r.syntheticException || new Error(n), s.message = n;
1840
1765
  i.synthetic = true;
1841
1766
  }
1842
1767
  let a = { exception: { values: [ir(e, s)] } };
1843
- return Ee(a, void 0, void 0), J(a, i), { ...a, event_id: r && r.event_id };
1768
+ return _e(a, void 0, void 0), J(a, i), { ...a, event_id: r && r.event_id };
1844
1769
  }
1845
- function Ms(t, e, n = "info", r, s) {
1770
+ function ks(t, e, n = "info", r, s) {
1846
1771
  let o = { event_id: r && r.event_id, level: n, message: e };
1847
1772
  if (s && r && r.syntheticException) {
1848
1773
  let i = or(t, r.syntheticException);
@@ -1850,34 +1775,34 @@ function Ms(t, e, n = "info", r, s) {
1850
1775
  }
1851
1776
  return o;
1852
1777
  }
1853
- var Ps = 5;
1854
- var ks = (t = { limit: Ps }) => ({ name: "LinkedErrors", processEvent: (e, n, r) => Ls(r.getOptions().stackParser, t.limit, e, n) });
1855
- function Ls(t, e, n, r) {
1856
- if (!n.exception || !n.exception.values || !r || !k(r.originalException, Error)) return n;
1778
+ var Ls = 5;
1779
+ var Fs = (t = { limit: Ls }) => ({ name: "LinkedErrors", processEvent: (e, n, r) => Us(r.getOptions().stackParser, t.limit, e, n) });
1780
+ function Us(t, e, n, r) {
1781
+ if (!n.exception || !n.exception.values || !r || !M(r.originalException, Error)) return n;
1857
1782
  let s = ar(t, e, r.originalException);
1858
1783
  return n.exception.values = [...s, ...n.exception.values], n;
1859
1784
  }
1860
1785
  function ar(t, e, n, r = []) {
1861
- if (!k(n.cause, Error) || r.length + 1 >= e) return r;
1786
+ if (!M(n.cause, Error) || r.length + 1 >= e) return r;
1862
1787
  let s = ir(t, n.cause);
1863
1788
  return ar(t, e, n.cause, [s, ...r]);
1864
1789
  }
1865
- var Fs = { allowedHeaders: ["CF-RAY", "CF-Worker"] };
1866
- var Us = (t = {}) => {
1867
- let e = { ...Fs, ...t };
1790
+ var $s = { allowedHeaders: ["CF-RAY", "CF-Worker"] };
1791
+ var Hs = (t = {}) => {
1792
+ let e = { ...$s, ...t };
1868
1793
  return { name: "RequestData", preprocessEvent: (n) => {
1869
1794
  let { sdkProcessingMetadata: r } = n;
1870
- return r && ("request" in r && r.request instanceof Request && (n.request = Hs(r.request, e), n.user = $s(n.user ?? {}, r.request, e)), "requestData" in r && (n.request ? n.request.data = r.requestData : n.request = { data: r.requestData })), n;
1795
+ return r && ("request" in r && r.request instanceof Request && (n.request = js(r.request, e), n.user = Bs(n.user ?? {}, r.request, e)), "requestData" in r && (n.request ? n.request.data = r.requestData : n.request = { data: r.requestData })), n;
1871
1796
  } };
1872
1797
  };
1873
- function $s(t, e, n) {
1798
+ function Bs(t, e, n) {
1874
1799
  let r = e.headers.get("CF-Connecting-IP"), { allowedIps: s } = n, o = { ...t };
1875
- return !("ip_address" in t) && r && s !== void 0 && Bs(r, s) && (o.ip_address = r), Object.keys(o).length > 0 ? o : void 0;
1800
+ return !("ip_address" in t) && r && s !== void 0 && Gs(r, s) && (o.ip_address = r), Object.keys(o).length > 0 ? o : void 0;
1876
1801
  }
1877
- function Hs(t, e) {
1802
+ function js(t, e) {
1878
1803
  let n = t.headers.get("cookie"), r;
1879
1804
  if (n) try {
1880
- r = js(n);
1805
+ r = qs(n);
1881
1806
  } catch {
1882
1807
  }
1883
1808
  let s = {};
@@ -1891,18 +1816,18 @@ function Hs(t, e) {
1891
1816
  l < 0 ? o.url = t.url : (o.url = t.url.substr(0, l), o.query_string = t.url.substr(l + 1));
1892
1817
  }
1893
1818
  let { allowedHeaders: i, allowedCookies: a, allowedSearchParams: c } = e;
1894
- if (i !== void 0 && o.headers ? (o.headers = nn(o.headers, i), Object.keys(o.headers).length === 0 && delete o.headers) : delete o.headers, a !== void 0 && o.cookies ? (o.cookies = nn(o.cookies, a), Object.keys(o.cookies).length === 0 && delete o.cookies) : delete o.cookies, c !== void 0) {
1819
+ if (i !== void 0 && o.headers ? (o.headers = Yt(o.headers, i), Object.keys(o.headers).length === 0 && delete o.headers) : delete o.headers, a !== void 0 && o.cookies ? (o.cookies = Yt(o.cookies, a), Object.keys(o.cookies).length === 0 && delete o.cookies) : delete o.cookies, c !== void 0) {
1895
1820
  let u = Object.fromEntries(new URLSearchParams(o.query_string)), l = new URLSearchParams();
1896
- Object.keys(nn(u, c)).forEach((p) => {
1821
+ Object.keys(Yt(u, c)).forEach((p) => {
1897
1822
  l.set(p, u[p]);
1898
1823
  }), o.query_string = l.toString();
1899
1824
  } else delete o.query_string;
1900
1825
  return o;
1901
1826
  }
1902
- function Bs(t, e) {
1827
+ function Gs(t, e) {
1903
1828
  return typeof e == "boolean" ? e : e instanceof RegExp ? e.test(t) : Array.isArray(e) ? e.map((r) => r.toLowerCase()).includes(t) : false;
1904
1829
  }
1905
- function nn(t, e) {
1830
+ function Yt(t, e) {
1906
1831
  let n = () => false;
1907
1832
  if (typeof e == "boolean") return e ? t : {};
1908
1833
  if (e instanceof RegExp) n = (r) => e.test(r);
@@ -1912,7 +1837,7 @@ function nn(t, e) {
1912
1837
  } else return {};
1913
1838
  return Object.keys(t).filter(n).reduce((r, s) => (r[s] = t[s], r), {});
1914
1839
  }
1915
- function js(t) {
1840
+ function qs(t) {
1916
1841
  if (typeof t != "string") return {};
1917
1842
  try {
1918
1843
  return t.split(";").map((e) => e.split("=")).reduce((e, [n, r]) => (e[decodeURIComponent(n.trim())] = decodeURIComponent(r.trim()), e), {});
@@ -1920,7 +1845,7 @@ function js(t) {
1920
1845
  return {};
1921
1846
  }
1922
1847
  }
1923
- function Gs(t, e) {
1848
+ function zs(t, e) {
1924
1849
  let n = {};
1925
1850
  return t.forEach((r) => {
1926
1851
  n[r.name] = r, typeof r.setupOnce == "function" && r.setupOnce();
@@ -1937,20 +1862,20 @@ function Gs(t, e) {
1937
1862
  }
1938
1863
  }), n;
1939
1864
  }
1940
- var rn = class extends Ce {
1865
+ var Jt = class extends Re {
1941
1866
  #e = null;
1942
1867
  #t = false;
1943
1868
  constructor(e) {
1944
1869
  e._metadata = e._metadata || {}, e._metadata.sdk = e._metadata.sdk || { name: "toucan-js", packages: [{ name: "npm:toucan-js", version: "4.0.0" }], version: "4.0.0" }, super(e);
1945
1870
  }
1946
1871
  setupIntegrations() {
1947
- this._isEnabled() && !this.#t && this.#e && (this._integrations = Gs(this._options.integrations, this.#e), this.#t = true);
1872
+ this._isEnabled() && !this.#t && this.#e && (this._integrations = zs(this._options.integrations, this.#e), this.#t = true);
1948
1873
  }
1949
1874
  eventFromException(e, n) {
1950
- return R(Ds(this.#e, this._options.stackParser, e, n));
1875
+ return R(Ps(this.#e, this._options.stackParser, e, n));
1951
1876
  }
1952
1877
  eventFromMessage(e, n = "info", r) {
1953
- return R(Ms(this._options.stackParser, e, n, r, this._options.attachStacktrace));
1878
+ return R(ks(this._options.stackParser, e, n, r, this._options.attachStacktrace));
1954
1879
  }
1955
1880
  _prepareEvent(e, n, r) {
1956
1881
  return e.platform = e.platform || "javascript", this.getOptions().request && (e.sdkProcessingMetadata = rr(e.sdkProcessingMetadata, ["request", this.getOptions().request])), this.getOptions().requestData && (e.sdkProcessingMetadata = rr(e.sdkProcessingMetadata, ["requestData", this.getOptions().requestData])), super._prepareEvent(e, n, r);
@@ -1968,8 +1893,8 @@ var rn = class extends Ce {
1968
1893
  this.getOptions().enabled = e;
1969
1894
  }
1970
1895
  };
1971
- function qs(t) {
1972
- let [e, n] = kt(t);
1896
+ function Ys(t) {
1897
+ let [e, n] = bt(t);
1973
1898
  return [e, (s) => {
1974
1899
  let o = n(s);
1975
1900
  if (o) {
@@ -1979,11 +1904,11 @@ function qs(t) {
1979
1904
  return o;
1980
1905
  }];
1981
1906
  }
1982
- function zs(t) {
1983
- if (t) return ye(t, ".js");
1984
- }
1985
- var Ys = Pe(qs(zs));
1986
1907
  function Js(t) {
1908
+ if (t) return Se(t, ".js");
1909
+ }
1910
+ var Vs = Pe(Ys(Js));
1911
+ function Ws(t) {
1987
1912
  function e({ body: n }) {
1988
1913
  try {
1989
1914
  let s = (t.fetcher ?? fetch)(t.url, { method: "POST", headers: t.headers, body: n }).then((o) => ({ statusCode: o.status, headers: { "retry-after": o.headers.get("Retry-After"), "x-sentry-rate-limits": o.headers.get("X-Sentry-Rate-Limits") } }));
@@ -1992,19 +1917,19 @@ function Js(t) {
1992
1917
  return V(r);
1993
1918
  }
1994
1919
  }
1995
- return tn(t, e);
1920
+ return zt(t, e);
1996
1921
  }
1997
- var le = class extends C {
1922
+ var oe = class extends C {
1998
1923
  #e;
1999
1924
  constructor(e) {
2000
- if (super(), e.defaultIntegrations = e.defaultIntegrations === false ? [] : [...Array.isArray(e.defaultIntegrations) ? e.defaultIntegrations : [Us(e.requestDataOptions), ks()]], e.release === void 0) {
2001
- let n = vs();
1925
+ if (super(), e.defaultIntegrations = e.defaultIntegrations === false ? [] : [...Array.isArray(e.defaultIntegrations) ? e.defaultIntegrations : [Hs(e.requestDataOptions), Fs()]], e.release === void 0) {
1926
+ let n = Ds();
2002
1927
  n !== void 0 && (e.release = n);
2003
1928
  }
2004
1929
  this.#e = e, this.attachNewClient();
2005
1930
  }
2006
1931
  attachNewClient() {
2007
- let e = new rn({ ...this.#e, transport: Js, integrations: Xt(this.#e), stackParser: Nt(this.#e.stackParser || Ys), transportOptions: { ...this.#e.transportOptions, context: this.#e.context } });
1932
+ let e = new Jt({ ...this.#e, transport: Ws, integrations: jt(this.#e), stackParser: Et(this.#e.stackParser || Vs), transportOptions: { ...this.#e.transportOptions, context: this.#e.context } });
2008
1933
  this.setClient(e), e.setSdk(this), e.setupIntegrations();
2009
1934
  }
2010
1935
  setRequestBody(e) {
@@ -2021,7 +1946,7 @@ var le = class extends C {
2021
1946
  return super.addBreadcrumb(e, s);
2022
1947
  }
2023
1948
  clone() {
2024
- let e = new le({ ...this.#e });
1949
+ let e = new oe({ ...this.#e });
2025
1950
  return e._breadcrumbs = [...this._breadcrumbs], e._tags = { ...this._tags }, e._extra = { ...this._extra }, e._contexts = { ...this._contexts }, e._user = this._user, e._level = this._level, e._session = this._session, e._transactionName = this._transactionName, e._fingerprint = this._fingerprint, e._eventProcessors = [...this._eventProcessors], e._requestSession = this._requestSession, e._attachments = [...this._attachments], e._sdkProcessingMetadata = { ...this._sdkProcessingMetadata }, e._propagationContext = { ...this._propagationContext }, e._lastEventId = this._lastEventId, e;
2026
1951
  }
2027
1952
  withScope(e) {
@@ -2031,19 +1956,19 @@ var le = class extends C {
2031
1956
  };
2032
1957
  function cr(t, e, n, r, s, o, i, a, c) {
2033
1958
  if (!(n && r && s)) return;
2034
- let u = new le({ dsn: n, request: t, context: e, sampleRate: 1, release: i?.tag, integrations: [Xe({ iteratee(l) {
1959
+ let u = new oe({ dsn: n, request: t, context: e, sampleRate: 1, release: i?.tag, integrations: [Xe({ iteratee(l) {
2035
1960
  return l.filename = "/index.js", l;
2036
1961
  } })], requestDataOptions: { allowedHeaders: ["user-agent", "cf-challenge", "accept-encoding", "accept-language", "cf-ray", "content-length", "content-type", "host"], allowedSearchParams: /(.*)/ }, transportOptions: { headers: { "CF-Access-Client-ID": r, "CF-Access-Client-Secret": s } } });
2037
1962
  return o && (u.setTag("colo", o.coloId), u.setTag("metal", o.metalId)), a && c && (u.setTag("accountId", a), u.setTag("scriptId", c)), u.setUser({ id: a?.toString() }), u;
2038
1963
  }
2039
- function Vs() {
1964
+ function Ks() {
2040
1965
  return { addLogs: () => {
2041
1966
  }, setTags: () => {
2042
1967
  }, end: () => {
2043
1968
  }, isRecording: true };
2044
1969
  }
2045
- function sn() {
2046
- return { enterSpan: (t, e, ...n) => e(Vs(), ...n), getSpanContext: () => ({ traceId: "test-trace", spanId: "test-span", parentSpanId: "test-parent-span", traceFlags: 0 }), runWithSpanContext: (t, e, ...n) => e(...n), traceId: "test-trace", spanId: "test-span", parentSpanId: "test-parent-span", cfTraceIdHeader: "test-trace:test-span:0" };
1970
+ function Vt() {
1971
+ return { enterSpan: (t, e, ...n) => e(Ks(), ...n), getSpanContext: () => ({ traceId: "test-trace", spanId: "test-span", parentSpanId: "test-parent-span", traceFlags: 0 }), runWithSpanContext: (t, e, ...n) => e(...n), traceId: "test-trace", spanId: "test-span", parentSpanId: "test-parent-span", cfTraceIdHeader: "test-trace:test-span:0" };
2047
1972
  }
2048
1973
  var Qe = class {
2049
1974
  constructor(e) {
@@ -2057,7 +1982,7 @@ var Qe = class {
2057
1982
  return this.data[e];
2058
1983
  }
2059
1984
  write() {
2060
- this.readyAnalytics && this.readyAnalytics.logEvent({ version: 1, accountId: this.data.accountId, indexId: this.data.scriptId?.toString(), doubles: [this.data.requestTime ?? -1, this.data.coloId ?? -1, this.data.metalId ?? -1, this.data.coloTier ?? -1, this.data.status ?? -1], blobs: [this.data.hostname?.substring(0, 256), this.data.userAgent?.substring(0, 256), this.data.htmlHandling, this.data.notFoundHandling, this.data.error?.substring(0, 256), this.data.version, this.data.coloRegion] });
1985
+ this.readyAnalytics && this.readyAnalytics.logEvent({ version: 1, accountId: this.data.accountId, indexId: this.data.scriptId?.toString(), doubles: [this.data.requestTime ?? -1, this.data.coloId ?? -1, this.data.metalId ?? -1, this.data.coloTier ?? -1, this.data.status ?? -1], blobs: [this.data.hostname?.substring(0, 256), this.data.userAgent?.substring(0, 256), this.data.htmlHandling, this.data.notFoundHandling, this.data.error?.substring(0, 256), this.data.version, this.data.coloRegion, this.data.cacheStatus] });
2061
1986
  }
2062
1987
  };
2063
1988
  var tt = class {
@@ -2065,28 +1990,28 @@ var tt = class {
2065
1990
  this.data = e;
2066
1991
  }
2067
1992
  async get(e) {
2068
- let n = await Zs(e), r = on(new Uint8Array(this.data, 20), n);
2069
- return r ? Qs(r) : null;
1993
+ let n = await Qs(e), r = Wt(new Uint8Array(this.data, 20), n);
1994
+ return r ? to(r) : null;
2070
1995
  }
2071
1996
  };
2072
- var Zs = async (t) => {
1997
+ var Qs = async (t) => {
2073
1998
  let n = new TextEncoder().encode(t), r = await crypto.subtle.digest("SHA-256", n.buffer);
2074
1999
  return new Uint8Array(r, 0, 16);
2075
2000
  };
2076
- var on = (t, e) => {
2001
+ var Wt = (t, e) => {
2077
2002
  if (t.byteLength === 0) return false;
2078
2003
  let n = t.byteOffset + (t.byteLength / 40 >> 1) * 40, r = new Uint8Array(t.buffer, n, 16);
2079
2004
  if (r.byteLength !== e.byteLength) throw new TypeError("Search value and current value are of different lengths");
2080
- let s = Xs(e, r);
2005
+ let s = eo(e, r);
2081
2006
  if (s < 0) {
2082
2007
  let o = t.byteOffset, i = n - t.byteOffset;
2083
- return on(new Uint8Array(t.buffer, o, i), e);
2008
+ return Wt(new Uint8Array(t.buffer, o, i), e);
2084
2009
  } else if (s > 0) {
2085
2010
  let o = n + 40, i = t.buffer.byteLength - n - 40;
2086
- return on(new Uint8Array(t.buffer, o, i), e);
2011
+ return Wt(new Uint8Array(t.buffer, o, i), e);
2087
2012
  } else return new Uint8Array(t.buffer, n, 40);
2088
2013
  };
2089
- var Xs = (t, e) => {
2014
+ var eo = (t, e) => {
2090
2015
  if (t.byteLength < e.byteLength) return -1;
2091
2016
  if (t.byteLength > e.byteLength) return 1;
2092
2017
  for (let [n, r] of t.entries()) {
@@ -2095,8 +2020,8 @@ var Xs = (t, e) => {
2095
2020
  }
2096
2021
  return 0;
2097
2022
  };
2098
- var Qs = (t) => [...t.slice(16, 16 + 16)].map((n) => n.toString(16).padStart(2, "0")).join("");
2099
- var an = (t) => ({ compatibility_date: t?.compatibility_date ?? "2021-11-02", compatibility_flags: t?.compatibility_flags ?? [], html_handling: t?.html_handling ?? "auto-trailing-slash", not_found_handling: t?.not_found_handling ?? "none", redirects: t?.redirects ?? { version: 1, staticRules: {}, rules: {} }, headers: t?.headers ?? { version: 2, rules: {} }, account_id: t?.account_id ?? -1, script_id: t?.script_id ?? -1 });
2023
+ var to = (t) => [...t.slice(16, 16 + 16)].map((n) => n.toString(16).padStart(2, "0")).join("");
2024
+ var Kt = (t) => ({ compatibility_date: t?.compatibility_date ?? "2021-11-02", compatibility_flags: t?.compatibility_flags ?? [], html_handling: t?.html_handling ?? "auto-trailing-slash", not_found_handling: t?.not_found_handling ?? "none", redirects: t?.redirects ?? { version: 1, staticRules: {}, rules: {} }, headers: t?.headers ?? { version: 2, rules: {} }, account_id: t?.account_id ?? -1, script_id: t?.script_id ?? -1 });
2100
2025
  var nt = class {
2101
2026
  constructor(e) {
2102
2027
  this.data = {};
@@ -2112,11 +2037,86 @@ var nt = class {
2112
2037
  this.readyAnalytics && this.readyAnalytics.logEvent({ version: 1, accountId: this.data.accountId, indexId: this.data.experimentName, doubles: [this.data.manifestReadTime ?? -1], blobs: [] });
2113
2038
  }
2114
2039
  };
2040
+ var Zt = class extends Response {
2041
+ constructor(e, n) {
2042
+ super(e, { ...n, status: Zt.status });
2043
+ }
2044
+ };
2045
+ var y = Zt;
2046
+ y.status = 200;
2047
+ var Xt = class extends Response {
2048
+ constructor(...[e, n]) {
2049
+ super(e, { ...n, status: Xt.status, statusText: "Not Found" });
2050
+ }
2051
+ };
2052
+ var k = Xt;
2053
+ k.status = 404;
2054
+ var Ne = class extends k {
2055
+ constructor() {
2056
+ super();
2057
+ }
2058
+ };
2059
+ var Qt = class extends Response {
2060
+ constructor(...[e, n]) {
2061
+ super(e, { ...n, status: Qt.status, statusText: "Method Not Allowed" });
2062
+ }
2063
+ };
2064
+ var ie = Qt;
2065
+ ie.status = 405;
2066
+ var en = class extends Response {
2067
+ constructor(e, n) {
2068
+ super(null, { ...n, status: en.status });
2069
+ }
2070
+ };
2071
+ var L = en;
2072
+ L.status = 500;
2073
+ var tn = class extends Response {
2074
+ constructor(...[e, n]) {
2075
+ super(null, { ...n, status: tn.status, statusText: "Not Modified" });
2076
+ }
2077
+ };
2078
+ var ae = tn;
2079
+ ae.status = 304;
2080
+ var nn = class extends Response {
2081
+ constructor(e, n) {
2082
+ super(null, { ...n, status: nn.status, statusText: "Moved Permanently", headers: { ...n?.headers, Location: e } });
2083
+ }
2084
+ };
2085
+ var ce = nn;
2086
+ ce.status = 301;
2087
+ var rn = class extends Response {
2088
+ constructor(e, n) {
2089
+ super(null, { ...n, status: rn.status, statusText: "Found", headers: { ...n?.headers, Location: e } });
2090
+ }
2091
+ };
2092
+ var ue = rn;
2093
+ ue.status = 302;
2094
+ var sn = class extends Response {
2095
+ constructor(e, n) {
2096
+ super(null, { ...n, status: sn.status, statusText: "See Other", headers: { ...n?.headers, Location: e } });
2097
+ }
2098
+ };
2099
+ var le = sn;
2100
+ le.status = 303;
2101
+ var on = class extends Response {
2102
+ constructor(e, n) {
2103
+ super(null, { ...n, status: on.status, statusText: "Temporary Redirect", headers: { ...n?.headers, Location: e } });
2104
+ }
2105
+ };
2106
+ var q = on;
2107
+ q.status = 307;
2108
+ var an = class extends Response {
2109
+ constructor(e, n) {
2110
+ super(null, { ...n, status: an.status, statusText: "Permanent Redirect", headers: { ...n?.headers, Location: e } });
2111
+ }
2112
+ };
2113
+ var pe = an;
2114
+ pe.status = 308;
2115
2115
  var ur = "public, max-age=0, must-revalidate";
2116
- var eo = /[-/\\^$*+?.()|[\]{}]/g;
2117
- var to = (t) => t.replace(eo, "\\$&");
2118
- var no = /(?<=^https:\\\/\\\/[^/]*?):([A-Za-z]\w*)(?=\\)/g;
2119
- var ro = /:([A-Za-z]\w*)/g;
2116
+ var no = /[-/\\^$*+?.()|[\]{}]/g;
2117
+ var ro = (t) => t.replace(no, "\\$&");
2118
+ var so = /(?<=^https:\\\/\\\/[^/]*?):([A-Za-z]\w*)(?=\\)/g;
2119
+ var oo = /:([A-Za-z]\w*)/g;
2120
2120
  var rt = (t, e) => {
2121
2121
  for (let [n, r] of Object.entries(e)) t = t.replaceAll(`:${n}`, r);
2122
2122
  return t;
@@ -2125,10 +2125,10 @@ var st = (t, e = (n) => n) => {
2125
2125
  if (!t) return () => [];
2126
2126
  let n = Object.entries(t).map(([r, s]) => {
2127
2127
  let o = r.startsWith("https://");
2128
- r = r.split("*").map(to).join("(?<splat>.*)");
2129
- let i = r.matchAll(no);
2128
+ r = r.split("*").map(ro).join("(?<splat>.*)");
2129
+ let i = r.matchAll(so);
2130
2130
  for (let c of i) r = r.split(c[0]).join(`(?<${c[1]}>[^/.]+)`);
2131
- let a = r.matchAll(ro);
2131
+ let a = r.matchAll(oo);
2132
2132
  for (let c of a) r = r.split(c[0]).join(`(?<${c[1]}>[^/]+)`);
2133
2133
  r = "^" + r + "$";
2134
2134
  try {
@@ -2145,11 +2145,11 @@ var st = (t, e = (n) => n) => {
2145
2145
  }).filter((i) => i !== void 0);
2146
2146
  };
2147
2147
  };
2148
- function lr(t, e, n) {
2149
- let r = new Headers({ ETag: `"${t}"` });
2150
- return e !== void 0 && r.append("Content-Type", e), so(n) && r.append("Cache-Control", ur), r;
2148
+ function lr(t, e, n, r) {
2149
+ let s = new Headers({ ETag: `"${t}"` });
2150
+ return e !== void 0 && s.append("Content-Type", e), io(r) && s.append("Cache-Control", ur), s.append("CF-Cache-Status", n), s;
2151
2151
  }
2152
- function so(t) {
2152
+ function io(t) {
2153
2153
  return !t.headers.has("Authorization") && !t.headers.has("Range");
2154
2154
  }
2155
2155
  function pr(t, e, n) {
@@ -2167,111 +2167,113 @@ function pr(t, e, n) {
2167
2167
  });
2168
2168
  }), e;
2169
2169
  }
2170
- var oo = 1;
2170
+ var ao = 1;
2171
2171
  var dr = 2;
2172
2172
  var fr = async (t, e, n, r) => {
2173
2173
  let s = new URL(t.url), { host: o, search: i } = s, { pathname: a } = s, c = () => {
2174
2174
  let I = n.redirects.staticRules[`https://${o}${a}`], w = n.redirects.staticRules[a];
2175
2175
  return I && w ? I.lineNumber < w.lineNumber ? I : w : I || w;
2176
- }, u = () => st(n.redirects.version === oo ? n.redirects.rules : {}, ({ status: I, to: w }, N) => ({ status: I, to: rt(w, N) })), l = c() || u()({ request: t })[0], p = false;
2176
+ }, u = () => st(n.redirects.version === ao ? n.redirects.rules : {}, ({ status: I, to: w }, N) => ({ status: I, to: rt(w, N) })), l = c() || u()({ request: t })[0], p = false;
2177
2177
  if (l) if (l.status === 200) a = new URL(l.to, t.url).pathname, p = true;
2178
2178
  else {
2179
- let { status: I, to: w } = l, N = new URL(w, t.url), pe = N.origin === new URL(t.url).origin ? `${N.pathname}${N.search || i}${N.hash}` : `${N.href.slice(0, N.href.length - (N.search.length + N.hash.length))}${N.search ? N.search : i}${N.hash}`;
2179
+ let { status: I, to: w } = l, N = new URL(w, t.url), de = N.origin === new URL(t.url).origin ? `${N.pathname}${N.search || i}${N.hash}` : `${N.href.slice(0, N.href.length - (N.search.length + N.hash.length))}${N.search ? N.search : i}${N.hash}`;
2180
2180
  switch (I) {
2181
- case ee.status:
2182
- return new ee(pe);
2183
- case ne.status:
2184
- return new ne(pe);
2185
- case F.status:
2186
- return new F(pe);
2187
- case re.status:
2188
- return new re(pe);
2189
- case te.status:
2181
+ case ce.status:
2182
+ return new ce(de);
2183
+ case le.status:
2184
+ return new le(de);
2185
+ case q.status:
2186
+ return new q(de);
2187
+ case pe.status:
2188
+ return new pe(de);
2189
+ case ue.status:
2190
2190
  default:
2191
- return new te(pe);
2191
+ return new ue(de);
2192
2192
  }
2193
2193
  }
2194
- let m = po(a), d = await gr(m, n, r);
2194
+ let f = mo(a), d = await gr(f, n, r);
2195
2195
  if (!d) {
2196
- let I = p ? new D() : new fe();
2197
- return e.JAEGER.enterSpan("no_intent", (w) => (w.setTags({ decodedPathname: m, configuration: JSON.stringify(n), proxied: p, status: I.status }), I));
2196
+ let I = p ? new k() : new Ne();
2197
+ return e.JAEGER.enterSpan("no_intent", (w) => (w.setTags({ decodedPathname: f, configuration: JSON.stringify(n), proxied: p, status: I.status }), I));
2198
2198
  }
2199
2199
  let g = t.method.toUpperCase();
2200
- if (!["GET", "HEAD"].includes(g)) return e.JAEGER.enterSpan("method_not_allowed", (I) => (I.setTags({ method: g, status: X.status }), new X()));
2201
- let Z = d.redirect ?? m, T = fo(Z);
2202
- return T !== a && d.asset || d.redirect ? e.JAEGER.enterSpan("redirect", (I) => (I.setTags({ originalPath: a, location: T !== a ? T : d.redirect ?? "<unknown>", status: F.status }), new F(T + i))) : d.asset ? d.asset : e.JAEGER.enterSpan("unknown_action", (I) => (I.setTags({ pathname: a, status: M.status }), new M(new Error("Unknown action"))));
2200
+ if (!["GET", "HEAD"].includes(g)) return e.JAEGER.enterSpan("method_not_allowed", (I) => (I.setTags({ method: g, status: ie.status }), new ie()));
2201
+ let Z = d.redirect ?? f, T = ho(Z);
2202
+ return T !== a && d.asset || d.redirect ? e.JAEGER.enterSpan("redirect", (I) => (I.setTags({ originalPath: a, location: T !== a ? T : d.redirect ?? "<unknown>", status: q.status }), new q(T + i))) : d.asset ? d.asset : e.JAEGER.enterSpan("unknown_action", (I) => (I.setTags({ pathname: a, status: L.status }), new L(new Error("Unknown action"))));
2203
2203
  };
2204
- var io = async (t, e, n, r) => {
2205
- let { pathname: s } = new URL(e.url), o = e.method.toUpperCase(), i = await n.JAEGER.enterSpan("getByETag", async (p) => (p.setTags({ pathname: s, eTag: t.eTag, status: t.status }), await r(t.eTag))), a = lr(t.eTag, i.contentType, e), c = `"${t.eTag}"`, u = `W/${c}`, l = e.headers.get("If-None-Match") || "";
2206
- return [u, c].includes(l) ? n.JAEGER.enterSpan("matched_etag", (p) => (p.setTags({ matchedEtag: l, status: Q.status }), new Q(null, { headers: a }))) : n.JAEGER.enterSpan("response", (p) => {
2207
- p.setTags({ etag: t.eTag, status: t.status, head: o === "HEAD" });
2208
- let m = o === "HEAD" ? null : i.readableStream;
2204
+ var co = async (t, e, n, r, s) => {
2205
+ let { pathname: o } = new URL(e.url), i = e.method.toUpperCase(), a = await n.JAEGER.enterSpan("getByETag", async (f) => (f.setTags({ pathname: o, eTag: t.eTag, status: t.status }), await r(t.eTag))), c = lr(t.eTag, a.contentType, a.cacheStatus, e);
2206
+ s.setData({ cacheStatus: a.cacheStatus });
2207
+ let u = `"${t.eTag}"`, l = `W/${u}`, p = e.headers.get("If-None-Match") || "";
2208
+ return [l, u].includes(p) ? n.JAEGER.enterSpan("matched_etag", (f) => (f.setTags({ matchedEtag: p, status: ae.status }), new ae(null, { headers: c }))) : n.JAEGER.enterSpan("response", (f) => {
2209
+ f.setTags({ etag: t.eTag, status: t.status, head: i === "HEAD" });
2210
+ let d = i === "HEAD" ? null : a.readableStream;
2209
2211
  switch (t.status) {
2210
- case D.status:
2211
- return new D(m, { headers: a });
2212
- case S.status:
2213
- return new S(m, { headers: a });
2212
+ case k.status:
2213
+ return new k(d, { headers: c });
2214
+ case y.status:
2215
+ return new y(d, { headers: c });
2214
2216
  }
2215
2217
  });
2216
2218
  };
2217
- var mr = async (t, e, n, r) => !(await fr(t, e, { ...n, not_found_handling: "none" }, r) instanceof fe);
2218
- var hr = async (t, e, n, r, s) => {
2219
- let o = await fr(t, e, n, r), i = o instanceof Response ? o : await io(o, t, e, s);
2220
- return pr(t, i, n);
2219
+ var mr = async (t, e, n, r) => !(await fr(t, e, { ...n, not_found_handling: "none" }, r) instanceof Ne);
2220
+ var hr = async (t, e, n, r, s, o) => {
2221
+ let i = await fr(t, e, n, r), a = i instanceof Response ? i : await co(i, t, e, s, o);
2222
+ return pr(t, a, n);
2221
2223
  };
2222
2224
  var gr = async (t, e, n, r = false) => {
2223
2225
  switch (e.html_handling) {
2224
2226
  case "auto-trailing-slash":
2225
- return ao(t, e, n, r);
2227
+ return uo(t, e, n, r);
2226
2228
  case "force-trailing-slash":
2227
- return co(t, e, n, r);
2229
+ return lo(t, e, n, r);
2228
2230
  case "drop-trailing-slash":
2229
- return uo(t, e, n, r);
2231
+ return po(t, e, n, r);
2230
2232
  case "none":
2231
- return lo(t, e, n);
2233
+ return fo(t, e, n);
2232
2234
  }
2233
2235
  };
2234
- var ao = async (t, e, n, r) => {
2236
+ var uo = async (t, e, n, r) => {
2235
2237
  let s = null, o = null, i = await n(t);
2236
2238
  if (t.endsWith("/index")) {
2237
- if (i) return { asset: { eTag: i, status: S.status }, redirect: null };
2239
+ if (i) return { asset: { eTag: i, status: y.status }, redirect: null };
2238
2240
  if (s = await E(`${t}.html`, t.slice(0, -5), e, n, r)) return s;
2239
2241
  if (s = await E(`${t.slice(0, -6)}.html`, t.slice(0, -6), e, n, r)) return s;
2240
2242
  } else if (t.endsWith("/index.html")) {
2241
2243
  if (s = await E(t, t.slice(0, -10), e, n, r)) return s;
2242
2244
  if (s = await E(`${t.slice(0, -11)}.html`, t.slice(0, -11), e, n, r)) return s;
2243
2245
  } else if (t.endsWith("/")) {
2244
- if (o = await n(`${t}index.html`)) return { asset: { eTag: o, status: S.status }, redirect: null };
2246
+ if (o = await n(`${t}index.html`)) return { asset: { eTag: o, status: y.status }, redirect: null };
2245
2247
  if (s = await E(`${t.slice(0, -1)}.html`, t.slice(0, -1), e, n, r)) return s;
2246
2248
  } else if (t.endsWith(".html")) {
2247
2249
  if (s = await E(t, t.slice(0, -5), e, n, r)) return s;
2248
2250
  if (s = await E(`${t.slice(0, -5)}/index.html`, `${t.slice(0, -5)}/`, e, n, r)) return s;
2249
2251
  }
2250
- return i ? { asset: { eTag: i, status: S.status }, redirect: null } : (o = await n(`${t}.html`)) ? { asset: { eTag: o, status: S.status }, redirect: null } : (s = await E(`${t}/index.html`, `${t}/`, e, n, r)) ? s : ot(t, e, n);
2252
+ return i ? { asset: { eTag: i, status: y.status }, redirect: null } : (o = await n(`${t}.html`)) ? { asset: { eTag: o, status: y.status }, redirect: null } : (s = await E(`${t}/index.html`, `${t}/`, e, n, r)) ? s : ot(t, e, n);
2251
2253
  };
2252
- var co = async (t, e, n, r) => {
2254
+ var lo = async (t, e, n, r) => {
2253
2255
  let s = null, o = null, i = await n(t);
2254
2256
  if (t.endsWith("/index")) {
2255
- if (i) return { asset: { eTag: i, status: S.status }, redirect: null };
2257
+ if (i) return { asset: { eTag: i, status: y.status }, redirect: null };
2256
2258
  if (s = await E(`${t}.html`, t.slice(0, -5), e, n, r)) return s;
2257
2259
  if (s = await E(`${t.slice(0, -6)}.html`, t.slice(0, -5), e, n, r)) return s;
2258
2260
  } else if (t.endsWith("/index.html")) {
2259
2261
  if (s = await E(t, t.slice(0, -10), e, n, r)) return s;
2260
2262
  if (s = await E(`${t.slice(0, -11)}.html`, t.slice(0, -10), e, n, r)) return s;
2261
2263
  } else if (t.endsWith("/")) {
2262
- if (o = await n(`${t}index.html`)) return { asset: { eTag: o, status: S.status }, redirect: null };
2263
- if (o = await n(`${t.slice(0, -1)}.html`)) return { asset: { eTag: o, status: S.status }, redirect: null };
2264
+ if (o = await n(`${t}index.html`)) return { asset: { eTag: o, status: y.status }, redirect: null };
2265
+ if (o = await n(`${t.slice(0, -1)}.html`)) return { asset: { eTag: o, status: y.status }, redirect: null };
2264
2266
  } else if (t.endsWith(".html")) {
2265
2267
  if (s = await E(t, `${t.slice(0, -5)}/`, e, n, r)) return s;
2266
- if (i) return { asset: { eTag: i, status: S.status }, redirect: null };
2268
+ if (i) return { asset: { eTag: i, status: y.status }, redirect: null };
2267
2269
  if (s = await E(`${t.slice(0, -5)}/index.html`, `${t.slice(0, -5)}/`, e, n, r)) return s;
2268
2270
  }
2269
- return i ? { asset: { eTag: i, status: S.status }, redirect: null } : (s = await E(`${t}.html`, `${t}/`, e, n, r)) || (s = await E(`${t}/index.html`, `${t}/`, e, n, r)) ? s : ot(t, e, n);
2271
+ return i ? { asset: { eTag: i, status: y.status }, redirect: null } : (s = await E(`${t}.html`, `${t}/`, e, n, r)) || (s = await E(`${t}/index.html`, `${t}/`, e, n, r)) ? s : ot(t, e, n);
2270
2272
  };
2271
- var uo = async (t, e, n, r) => {
2273
+ var po = async (t, e, n, r) => {
2272
2274
  let s = null, o = null, i = await n(t);
2273
2275
  if (t.endsWith("/index")) {
2274
- if (i) return { asset: { eTag: i, status: S.status }, redirect: null };
2276
+ if (i) return { asset: { eTag: i, status: y.status }, redirect: null };
2275
2277
  if (t === "/index") {
2276
2278
  if (s = await E("/index.html", "/", e, n, r)) return s;
2277
2279
  } else {
@@ -2282,11 +2284,11 @@ var uo = async (t, e, n, r) => {
2282
2284
  if (s = await E("/index.html", "/", e, n, r)) return s;
2283
2285
  } else {
2284
2286
  if (s = await E(t, t.slice(0, -11), e, n, r)) return s;
2285
- if (i) return { asset: { eTag: i, status: S.status }, redirect: null };
2287
+ if (i) return { asset: { eTag: i, status: y.status }, redirect: null };
2286
2288
  if (s = await E(`${t.slice(0, -11)}.html`, t.slice(0, -11), e, n, r)) return s;
2287
2289
  }
2288
2290
  else if (t.endsWith("/")) if (t === "/") {
2289
- if (o = await n("/index.html")) return { asset: { eTag: o, status: S.status }, redirect: null };
2291
+ if (o = await n("/index.html")) return { asset: { eTag: o, status: y.status }, redirect: null };
2290
2292
  } else {
2291
2293
  if (s = await E(`${t.slice(0, -1)}.html`, t.slice(0, -1), e, n, r)) return s;
2292
2294
  if (s = await E(`${t.slice(0, -1)}/index.html`, t.slice(0, -1), e, n, r)) return s;
@@ -2295,24 +2297,24 @@ var uo = async (t, e, n, r) => {
2295
2297
  if (s = await E(t, t.slice(0, -5), e, n, r)) return s;
2296
2298
  if (s = await E(`${t.slice(0, -5)}/index.html`, t.slice(0, -5), e, n, r)) return s;
2297
2299
  }
2298
- return i ? { asset: { eTag: i, status: S.status }, redirect: null } : (o = await n(`${t}.html`)) ? { asset: { eTag: o, status: S.status }, redirect: null } : (o = await n(`${t}/index.html`)) ? { asset: { eTag: o, status: S.status }, redirect: null } : ot(t, e, n);
2300
+ return i ? { asset: { eTag: i, status: y.status }, redirect: null } : (o = await n(`${t}.html`)) ? { asset: { eTag: o, status: y.status }, redirect: null } : (o = await n(`${t}/index.html`)) ? { asset: { eTag: o, status: y.status }, redirect: null } : ot(t, e, n);
2299
2301
  };
2300
- var lo = async (t, e, n) => {
2302
+ var fo = async (t, e, n) => {
2301
2303
  let r = await n(t);
2302
- return r ? { asset: { eTag: r, status: S.status }, redirect: null } : ot(t, e, n);
2304
+ return r ? { asset: { eTag: r, status: y.status }, redirect: null } : ot(t, e, n);
2303
2305
  };
2304
2306
  var ot = async (t, e, n) => {
2305
2307
  switch (e.not_found_handling) {
2306
2308
  case "single-page-application": {
2307
2309
  let r = await n("/index.html");
2308
- return r ? { asset: { eTag: r, status: S.status }, redirect: null } : null;
2310
+ return r ? { asset: { eTag: r, status: y.status }, redirect: null } : null;
2309
2311
  }
2310
2312
  case "404-page": {
2311
2313
  let r = t;
2312
2314
  for (; r; ) {
2313
2315
  r = r.slice(0, r.lastIndexOf("/"));
2314
2316
  let s = await n(`${r}/404.html`);
2315
- if (s) return { asset: { eTag: s, status: D.status }, redirect: null };
2317
+ if (s) return { asset: { eTag: s, status: k.status }, redirect: null };
2316
2318
  }
2317
2319
  return null;
2318
2320
  }
@@ -2329,21 +2331,36 @@ var E = async (t, e, n, r, s) => {
2329
2331
  }
2330
2332
  return null;
2331
2333
  };
2332
- var po = (t) => t.split("/").map((e) => {
2334
+ var mo = (t) => t.split("/").map((e) => {
2333
2335
  try {
2334
2336
  return decodeURIComponent(e);
2335
2337
  } catch {
2336
2338
  return e;
2337
2339
  }
2338
2340
  }).join("/").replace(/\/+/g, "/");
2339
- var fo = (t) => t.split("/").map((e) => {
2341
+ var ho = (t) => t.split("/").map((e) => {
2340
2342
  try {
2341
2343
  return encodeURIComponent(e);
2342
2344
  } catch {
2343
2345
  return e;
2344
2346
  }
2345
2347
  }).join("/");
2346
- async function _r(t, e, n, r = 1) {
2348
+ function _r(t, e, n) {
2349
+ try {
2350
+ let r = new L(n);
2351
+ return t && t.captureException(n), n instanceof Error && e.setData({ error: n.message }), r;
2352
+ } catch (r) {
2353
+ return console.error("Error handling error", r), new L(r);
2354
+ }
2355
+ }
2356
+ function Er(t, e, n) {
2357
+ try {
2358
+ t.setData({ requestTime: e.now() - n }), t.write();
2359
+ } catch (r) {
2360
+ console.error("Error submitting metrics", r);
2361
+ }
2362
+ }
2363
+ async function Sr(t, e, n, r = 1) {
2347
2364
  let s = 0;
2348
2365
  for (; s <= r; ) try {
2349
2366
  let o = await t.getWithMetadata(e, { type: "stream", cacheTtl: 31536e3 });
@@ -2360,52 +2377,37 @@ async function _r(t, e, n, r = 1) {
2360
2377
  await new Promise((i) => setTimeout(i, Math.pow(2, s++) * 1e3));
2361
2378
  }
2362
2379
  }
2363
- function ho(t, e, n) {
2364
- try {
2365
- let r = new M(n);
2366
- return t && t.captureException(n), n instanceof Error && e.setData({ error: n.message }), r;
2367
- } catch (r) {
2368
- return console.error("Error handling error", r), new M(r);
2369
- }
2370
- }
2371
- function go(t, e, n) {
2372
- try {
2373
- t.setData({ requestTime: e.now() - n }), t.write();
2374
- } catch (r) {
2375
- console.error("Error submitting metrics", r);
2376
- }
2377
- }
2378
- var Er = class extends mo {
2380
+ var yr = class extends go {
2379
2381
  async fetch(t) {
2380
- let e, n = new Qe(this.env.ANALYTICS), r = new de(this.env.UNSAFE_PERFORMANCE), s = r.now();
2382
+ let e, n = new Qe(this.env.ANALYTICS), r = new X(this.env.UNSAFE_PERFORMANCE), s = r.now();
2381
2383
  try {
2382
- this.env.JAEGER ??= sn(), e = cr(t, this.ctx, this.env.SENTRY_DSN, this.env.SENTRY_ACCESS_CLIENT_ID, this.env.SENTRY_ACCESS_CLIENT_SECRET, this.env.COLO_METADATA, this.env.VERSION_METADATA, this.env.CONFIG?.account_id, this.env.CONFIG?.script_id);
2383
- let o = an(this.env.CONFIG), i = t.headers.get("user-agent") ?? "UA UNKNOWN", a = new URL(t.url);
2384
+ this.env.JAEGER ??= Vt(), e = cr(t, this.ctx, this.env.SENTRY_DSN, this.env.SENTRY_ACCESS_CLIENT_ID, this.env.SENTRY_ACCESS_CLIENT_SECRET, this.env.COLO_METADATA, this.env.VERSION_METADATA, this.env.CONFIG?.account_id, this.env.CONFIG?.script_id);
2385
+ let o = Kt(this.env.CONFIG), i = t.headers.get("user-agent") ?? "UA UNKNOWN", a = new URL(t.url);
2384
2386
  return this.env.COLO_METADATA && this.env.VERSION_METADATA && this.env.CONFIG && n.setData({ accountId: this.env.CONFIG.account_id, scriptId: this.env.CONFIG.script_id, coloId: this.env.COLO_METADATA.coloId, metalId: this.env.COLO_METADATA.metalId, coloTier: this.env.COLO_METADATA.coloTier, coloRegion: this.env.COLO_METADATA.coloRegion, version: this.env.VERSION_METADATA.tag, hostname: a.hostname, htmlHandling: o.html_handling, notFoundHandling: o.not_found_handling, userAgent: i }), await this.env.JAEGER.enterSpan("handleRequest", async (c) => {
2385
2387
  c.setTags({ hostname: a.hostname, eyeballPath: a.pathname, env: this.env.ENVIRONMENT, version: this.env.VERSION_METADATA?.id });
2386
- let u = await hr(t, this.env, o, this.unstable_exists.bind(this), this.unstable_getByETag.bind(this));
2388
+ let u = await hr(t, this.env, o, this.unstable_exists.bind(this), this.unstable_getByETag.bind(this), n);
2387
2389
  return n.setData({ status: u.status }), u;
2388
2390
  });
2389
2391
  } catch (o) {
2390
- return ho(e, n, o);
2392
+ return _r(e, n, o);
2391
2393
  } finally {
2392
- go(n, r, s);
2394
+ Er(n, r, s);
2393
2395
  }
2394
2396
  }
2395
2397
  async unstable_canFetch(t) {
2396
- return this.env.JAEGER ??= sn(), mr(t, this.env, an(this.env.CONFIG), this.unstable_exists.bind(this));
2398
+ return this.env.JAEGER ??= Vt(), mr(t, this.env, Kt(this.env.CONFIG), this.unstable_exists.bind(this));
2397
2399
  }
2398
2400
  async unstable_getByETag(t) {
2399
- let e = await _r(this.env.ASSETS_KV_NAMESPACE, t);
2400
- if (!e || !e.value) throw new Error(`Requested asset ${t} exists in the asset manifest but not in the KV namespace.`);
2401
- return { readableStream: e.value, contentType: e.metadata?.contentType };
2401
+ let e = new X(this.env.UNSAFE_PERFORMANCE), n = e.now(), r = await Sr(this.env.ASSETS_KV_NAMESPACE, t), o = e.now() - n;
2402
+ if (!r || !r.value) throw new Error(`Requested asset ${t} exists in the asset manifest but not in the KV namespace.`);
2403
+ return { readableStream: r.value, contentType: r.metadata?.contentType, cacheStatus: o <= 100 ? "HIT" : "MISS" };
2402
2404
  }
2403
2405
  async unstable_getByPathname(t) {
2404
2406
  let e = await this.unstable_exists(t);
2405
2407
  return e ? this.unstable_getByETag(e) : null;
2406
2408
  }
2407
2409
  async unstable_exists(t) {
2408
- let e = new nt(this.env.EXPERIMENT_ANALYTICS), n = new de(this.env.UNSAFE_PERFORMANCE);
2410
+ let e = new nt(this.env.EXPERIMENT_ANALYTICS), n = new X(this.env.UNSAFE_PERFORMANCE);
2409
2411
  this.env.COLO_METADATA && this.env.VERSION_METADATA && this.env.CONFIG && e.setData({ accountId: this.env.CONFIG.account_id, experimentName: "manifest-read-timing" });
2410
2412
  let r = n.now();
2411
2413
  try {
@@ -2424,7 +2426,7 @@ var UNKNOWN_HOST = "http://localhost";
2424
2426
  var MODULE_PATTERN = `__CLOUDFLARE_MODULE__(${MODULE_TYPES.join("|")})__(.*?)__`;
2425
2427
 
2426
2428
  // src/asset-workers/asset-worker.ts
2427
- var CustomAssetWorker = class extends Er {
2429
+ var CustomAssetWorker = class extends yr {
2428
2430
  async fetch(request) {
2429
2431
  const response = await super.fetch(request);
2430
2432
  const modifiedResponse = new Response(response.body, response);