autotel-subscribers 16.0.0 → 16.0.1

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.
@@ -115,11 +115,11 @@ function normalizeWindowsPath(path) {
115
115
  return path.replace(/^[A-Z]:/, "").replace(/\\/g, "/");
116
116
  }
117
117
  var init_module_node = __esm({
118
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/error-tracking/modifiers/module.node.mjs"() {
118
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/error-tracking/modifiers/module.node.mjs"() {
119
119
  }
120
120
  });
121
121
 
122
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/featureFlagUtils.mjs
122
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/featureFlagUtils.mjs
123
123
  function getFlagDetailFromFlagAndPayload(key, value, payload) {
124
124
  return {
125
125
  key,
@@ -136,7 +136,7 @@ function getFlagDetailFromFlagAndPayload(key, value, payload) {
136
136
  }
137
137
  var normalizeFlagsResponse, getFlagValuesFromFlags, getPayloadsFromFlags, getFeatureFlagValue, parsePayload;
138
138
  var init_featureFlagUtils = __esm({
139
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/featureFlagUtils.mjs"() {
139
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/featureFlagUtils.mjs"() {
140
140
  normalizeFlagsResponse = (flagsResponse) => {
141
141
  if ("flags" in flagsResponse) {
142
142
  const featureFlags = getFlagValuesFromFlags(flagsResponse.flags);
@@ -194,10 +194,10 @@ var init_featureFlagUtils = __esm({
194
194
  }
195
195
  });
196
196
 
197
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/vendor/uuidv7.mjs
197
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/vendor/uuidv7.mjs
198
198
  var DIGITS, UUID, V7Generator, getDefaultRandom, defaultGenerator, uuidv7, uuidv7obj;
199
199
  var init_uuidv7 = __esm({
200
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/vendor/uuidv7.mjs"() {
200
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/vendor/uuidv7.mjs"() {
201
201
  DIGITS = "0123456789abcdef";
202
202
  UUID = class _UUID {
203
203
  constructor(bytes) {
@@ -358,10 +358,10 @@ var init_uuidv7 = __esm({
358
358
  }
359
359
  });
360
360
 
361
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/bot-detection.mjs
361
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/bot-detection.mjs
362
362
  var DEFAULT_BLOCKED_UA_STRS, isBlockedUA;
363
363
  var init_bot_detection = __esm({
364
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/bot-detection.mjs"() {
364
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/bot-detection.mjs"() {
365
365
  DEFAULT_BLOCKED_UA_STRS = [
366
366
  "amazonbot",
367
367
  "amazonproductbot",
@@ -452,10 +452,10 @@ var init_bot_detection = __esm({
452
452
  }
453
453
  });
454
454
 
455
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/types.mjs
455
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/types.mjs
456
456
  var types_PostHogPersistedProperty;
457
457
  var init_types = __esm({
458
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/types.mjs"() {
458
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/types.mjs"() {
459
459
  types_PostHogPersistedProperty = /* @__PURE__ */ (function(PostHogPersistedProperty) {
460
460
  PostHogPersistedProperty["AnonymousId"] = "anonymous_id";
461
461
  PostHogPersistedProperty["DistinctId"] = "distinct_id";
@@ -487,20 +487,13 @@ var init_types = __esm({
487
487
  }
488
488
  });
489
489
 
490
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/string-utils.mjs
490
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/string-utils.mjs
491
491
  var init_string_utils = __esm({
492
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/string-utils.mjs"() {
492
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/string-utils.mjs"() {
493
493
  }
494
494
  });
495
495
 
496
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/type-utils.mjs
497
- function isInstanceOf(candidate, base) {
498
- try {
499
- return candidate instanceof base;
500
- } catch {
501
- return false;
502
- }
503
- }
496
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/type-utils.mjs
504
497
  function isPrimitive(value) {
505
498
  return null === value || "object" != typeof value;
506
499
  }
@@ -516,9 +509,16 @@ function isEvent(candidate) {
516
509
  function isPlainObject(candidate) {
517
510
  return isBuiltin(candidate, "Object");
518
511
  }
519
- var nativeIsArray, ObjProto, type_utils_toString, isArray, isUndefined, isString, isEmptyString, isNumber, isPlainError;
512
+ function isInstanceOf(candidate, base) {
513
+ try {
514
+ return candidate instanceof base;
515
+ } catch {
516
+ return false;
517
+ }
518
+ }
519
+ var nativeIsArray, ObjProto, type_utils_toString, isArray, isObject, isUndefined, isString, isEmptyString, isNumber, isPlainError;
520
520
  var init_type_utils = __esm({
521
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/type-utils.mjs"() {
521
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/type-utils.mjs"() {
522
522
  init_types();
523
523
  init_string_utils();
524
524
  nativeIsArray = Array.isArray;
@@ -528,6 +528,7 @@ var init_type_utils = __esm({
528
528
  isArray = nativeIsArray || function(obj) {
529
529
  return "[object Array]" === type_utils_toString.call(obj);
530
530
  };
531
+ isObject = (x) => x === Object(x) && !isArray(x);
531
532
  isUndefined = (x) => void 0 === x;
532
533
  isString = (x) => "[object String]" == type_utils_toString.call(x);
533
534
  isEmptyString = (x) => isString(x) && 0 === x.trim().length;
@@ -536,7 +537,7 @@ var init_type_utils = __esm({
536
537
  }
537
538
  });
538
539
 
539
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/number-utils.mjs
540
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/number-utils.mjs
540
541
  function clampToRange(value, min, max, logger, fallbackValue) {
541
542
  if (min > max) {
542
543
  logger.warn("min cannot be greater than max.");
@@ -554,15 +555,15 @@ function clampToRange(value, min, max, logger, fallbackValue) {
554
555
  return clampToRange(max, min, max, logger);
555
556
  }
556
557
  var init_number_utils = __esm({
557
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/number-utils.mjs"() {
558
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/number-utils.mjs"() {
558
559
  init_type_utils();
559
560
  }
560
561
  });
561
562
 
562
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/bucketed-rate-limiter.mjs
563
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/bucketed-rate-limiter.mjs
563
564
  var ONE_DAY_IN_MS, BucketedRateLimiter;
564
565
  var init_bucketed_rate_limiter = __esm({
565
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/bucketed-rate-limiter.mjs"() {
566
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/bucketed-rate-limiter.mjs"() {
566
567
  init_number_utils();
567
568
  ONE_DAY_IN_MS = 864e5;
568
569
  BucketedRateLimiter = class {
@@ -606,10 +607,10 @@ var init_bucketed_rate_limiter = __esm({
606
607
  }
607
608
  });
608
609
 
609
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/promise-queue.mjs
610
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/promise-queue.mjs
610
611
  var PromiseQueue;
611
612
  var init_promise_queue = __esm({
612
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/promise-queue.mjs"() {
613
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/promise-queue.mjs"() {
613
614
  init_uuidv7();
614
615
  PromiseQueue = class {
615
616
  add(promise) {
@@ -640,7 +641,7 @@ var init_promise_queue = __esm({
640
641
  }
641
642
  });
642
643
 
643
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/logger.mjs
644
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/logger.mjs
644
645
  function createConsole(consoleLike = console) {
645
646
  const lockedMethods = {
646
647
  log: consoleLike.log.bind(consoleLike),
@@ -655,7 +656,7 @@ function createLogger(prefix, maybeCall = passThrough) {
655
656
  }
656
657
  var _createLogger, passThrough;
657
658
  var init_logger = __esm({
658
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/logger.mjs"() {
659
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/logger.mjs"() {
659
660
  _createLogger = (prefix, maybeCall, consoleLike) => {
660
661
  function _log(level, ...args) {
661
662
  maybeCall(() => {
@@ -684,10 +685,10 @@ var init_logger = __esm({
684
685
  }
685
686
  });
686
687
 
687
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/user-agent-utils.mjs
688
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/user-agent-utils.mjs
688
689
  var MOBILE, TABLET, GENERIC;
689
690
  var init_user_agent_utils = __esm({
690
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/user-agent-utils.mjs"() {
691
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/user-agent-utils.mjs"() {
691
692
  init_string_utils();
692
693
  init_type_utils();
693
694
  MOBILE = "Mobile";
@@ -698,7 +699,7 @@ var init_user_agent_utils = __esm({
698
699
  }
699
700
  });
700
701
 
701
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/index.mjs
702
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/index.mjs
702
703
  function assert(truthyValue, message2) {
703
704
  if (!truthyValue || "string" != typeof truthyValue || isEmpty(truthyValue)) throw new Error(message2);
704
705
  }
@@ -742,7 +743,7 @@ function allSettled(promises) {
742
743
  }
743
744
  var STRING_FORMAT, isError;
744
745
  var init_utils = __esm({
745
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/utils/index.mjs"() {
746
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/utils/index.mjs"() {
746
747
  init_bot_detection();
747
748
  init_bucketed_rate_limiter();
748
749
  init_number_utils();
@@ -756,10 +757,10 @@ var init_utils = __esm({
756
757
  }
757
758
  });
758
759
 
759
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/eventemitter.mjs
760
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/eventemitter.mjs
760
761
  var SimpleEventEmitter;
761
762
  var init_eventemitter = __esm({
762
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/eventemitter.mjs"() {
763
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/eventemitter.mjs"() {
763
764
  SimpleEventEmitter = class {
764
765
  constructor() {
765
766
  this.events = {};
@@ -780,7 +781,7 @@ var init_eventemitter = __esm({
780
781
  }
781
782
  });
782
783
 
783
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/gzip.mjs
784
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/gzip.mjs
784
785
  function isGzipSupported() {
785
786
  return "CompressionStream" in globalThis;
786
787
  }
@@ -799,11 +800,11 @@ async function gzipCompress(input, isDebug = true) {
799
800
  }
800
801
  }
801
802
  var init_gzip = __esm({
802
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/gzip.mjs"() {
803
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/gzip.mjs"() {
803
804
  }
804
805
  });
805
806
 
806
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/posthog-core-stateless.mjs
807
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/posthog-core-stateless.mjs
807
808
  async function logFlushError(err) {
808
809
  if (err instanceof PostHogFetchHttpError) {
809
810
  let text = "";
@@ -823,7 +824,7 @@ function isPostHogFetchContentTooLargeError(err) {
823
824
  }
824
825
  var PostHogFetchHttpError, PostHogFetchNetworkError, PostHogCoreStateless;
825
826
  var init_posthog_core_stateless = __esm({
826
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/posthog-core-stateless.mjs"() {
827
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/posthog-core-stateless.mjs"() {
827
828
  init_eventemitter();
828
829
  init_featureFlagUtils();
829
830
  init_gzip();
@@ -1441,9 +1442,9 @@ var init_posthog_core_stateless = __esm({
1441
1442
  }
1442
1443
  });
1443
1444
 
1444
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/posthog-core.mjs
1445
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/posthog-core.mjs
1445
1446
  var init_posthog_core = __esm({
1446
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/posthog-core.mjs"() {
1447
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/posthog-core.mjs"() {
1447
1448
  init_featureFlagUtils();
1448
1449
  init_types();
1449
1450
  init_posthog_core_stateless();
@@ -1452,7 +1453,7 @@ var init_posthog_core = __esm({
1452
1453
  }
1453
1454
  });
1454
1455
 
1455
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/chunk-ids.mjs
1456
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/chunk-ids.mjs
1456
1457
  function getFilenameToChunkIdMap(stackParser) {
1457
1458
  const chunkIdMap = globalThis._posthogChunkIds;
1458
1459
  if (!chunkIdMap) return;
@@ -1485,14 +1486,14 @@ function getFilenameToChunkIdMap(stackParser) {
1485
1486
  }
1486
1487
  var parsedStackResults, lastKeysCount, cachedFilenameChunkIds;
1487
1488
  var init_chunk_ids = __esm({
1488
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/chunk-ids.mjs"() {
1489
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/chunk-ids.mjs"() {
1489
1490
  }
1490
1491
  });
1491
1492
 
1492
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/error-properties-builder.mjs
1493
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/error-properties-builder.mjs
1493
1494
  var MAX_CAUSE_RECURSION, ErrorPropertiesBuilder;
1494
1495
  var init_error_properties_builder = __esm({
1495
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/error-properties-builder.mjs"() {
1496
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/error-properties-builder.mjs"() {
1496
1497
  init_utils();
1497
1498
  init_chunk_ids();
1498
1499
  MAX_CAUSE_RECURSION = 4;
@@ -1606,7 +1607,7 @@ var init_error_properties_builder = __esm({
1606
1607
  }
1607
1608
  });
1608
1609
 
1609
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/base.mjs
1610
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/base.mjs
1610
1611
  function createFrame(platform, filename, func, lineno, colno) {
1611
1612
  const frame = {
1612
1613
  platform,
@@ -1620,16 +1621,16 @@ function createFrame(platform, filename, func, lineno, colno) {
1620
1621
  }
1621
1622
  var UNKNOWN_FUNCTION;
1622
1623
  var init_base = __esm({
1623
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/base.mjs"() {
1624
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/base.mjs"() {
1624
1625
  init_utils();
1625
1626
  UNKNOWN_FUNCTION = "?";
1626
1627
  }
1627
1628
  });
1628
1629
 
1629
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/safari.mjs
1630
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/safari.mjs
1630
1631
  var extractSafariExtensionDetails;
1631
1632
  var init_safari = __esm({
1632
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/safari.mjs"() {
1633
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/safari.mjs"() {
1633
1634
  init_base();
1634
1635
  extractSafariExtensionDetails = (func, filename) => {
1635
1636
  const isSafariExtension = -1 !== func.indexOf("safari-extension");
@@ -1645,10 +1646,10 @@ var init_safari = __esm({
1645
1646
  }
1646
1647
  });
1647
1648
 
1648
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/chrome.mjs
1649
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/chrome.mjs
1649
1650
  var chromeRegexNoFnName, chromeRegex, chromeEvalRegex, chromeStackLineParser;
1650
1651
  var init_chrome = __esm({
1651
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/chrome.mjs"() {
1652
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/chrome.mjs"() {
1652
1653
  init_base();
1653
1654
  init_safari();
1654
1655
  chromeRegexNoFnName = /^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i;
@@ -1678,23 +1679,10 @@ var init_chrome = __esm({
1678
1679
  }
1679
1680
  });
1680
1681
 
1681
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/winjs.mjs
1682
- var winjsRegex, winjsStackLineParser;
1683
- var init_winjs = __esm({
1684
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/winjs.mjs"() {
1685
- init_base();
1686
- winjsRegex = /^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i;
1687
- winjsStackLineParser = (line, platform) => {
1688
- const parts = winjsRegex.exec(line);
1689
- return parts ? createFrame(platform, parts[2], parts[1] || UNKNOWN_FUNCTION, +parts[3], parts[4] ? +parts[4] : void 0) : void 0;
1690
- };
1691
- }
1692
- });
1693
-
1694
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/gecko.mjs
1682
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/gecko.mjs
1695
1683
  var geckoREgex, geckoEvalRegex, geckoStackLineParser;
1696
1684
  var init_gecko = __esm({
1697
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/gecko.mjs"() {
1685
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/gecko.mjs"() {
1698
1686
  init_base();
1699
1687
  init_safari();
1700
1688
  geckoREgex = /^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i;
@@ -1721,10 +1709,23 @@ var init_gecko = __esm({
1721
1709
  }
1722
1710
  });
1723
1711
 
1724
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/opera.mjs
1712
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/winjs.mjs
1713
+ var winjsRegex, winjsStackLineParser;
1714
+ var init_winjs = __esm({
1715
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/winjs.mjs"() {
1716
+ init_base();
1717
+ winjsRegex = /^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i;
1718
+ winjsStackLineParser = (line, platform) => {
1719
+ const parts = winjsRegex.exec(line);
1720
+ return parts ? createFrame(platform, parts[2], parts[1] || UNKNOWN_FUNCTION, +parts[3], parts[4] ? +parts[4] : void 0) : void 0;
1721
+ };
1722
+ }
1723
+ });
1724
+
1725
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/opera.mjs
1725
1726
  var opera10Regex, opera10StackLineParser, opera11Regex, opera11StackLineParser;
1726
1727
  var init_opera = __esm({
1727
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/opera.mjs"() {
1728
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/opera.mjs"() {
1728
1729
  init_base();
1729
1730
  opera10Regex = / line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i;
1730
1731
  opera10StackLineParser = (line, platform) => {
@@ -1739,7 +1740,7 @@ var init_opera = __esm({
1739
1740
  }
1740
1741
  });
1741
1742
 
1742
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/node.mjs
1743
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/node.mjs
1743
1744
  function filenameIsInApp(filename, isNative = false) {
1744
1745
  const isInternal = isNative || filename && !filename.startsWith("/") && !filename.match(/^[A-Z]:/) && !filename.startsWith(".") && !filename.match(/^[a-zA-Z]([a-zA-Z0-9.\-+])*:\/\//);
1745
1746
  return !isInternal && void 0 !== filename && !filename.includes("node_modules/");
@@ -1749,7 +1750,7 @@ function _parseIntOrUndefined(input) {
1749
1750
  }
1750
1751
  var FILENAME_MATCH, FULL_MATCH, nodeStackLineParser;
1751
1752
  var init_node = __esm({
1752
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/node.mjs"() {
1753
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/node.mjs"() {
1753
1754
  init_base();
1754
1755
  FILENAME_MATCH = /^\s*[-]{4,}$/;
1755
1756
  FULL_MATCH = /at (?:async )?(?:(.+?)\s+\()?(?:(.+):(\d+):(\d+)?|([^)]+))\)?/;
@@ -1810,7 +1811,7 @@ var init_node = __esm({
1810
1811
  }
1811
1812
  });
1812
1813
 
1813
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/index.mjs
1814
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/index.mjs
1814
1815
  function reverseAndStripFrames(stack) {
1815
1816
  if (!stack.length) return [];
1816
1817
  const localStack = Array.from(stack);
@@ -1824,6 +1825,9 @@ function reverseAndStripFrames(stack) {
1824
1825
  function getLastStackFrame(arr) {
1825
1826
  return arr[arr.length - 1] || {};
1826
1827
  }
1828
+ function createDefaultStackParser() {
1829
+ return createStackParser("web:javascript", chromeStackLineParser, geckoStackLineParser);
1830
+ }
1827
1831
  function createStackParser(platform, ...parsers) {
1828
1832
  return (stack, skipFirstLines = 0) => {
1829
1833
  const frames = [];
@@ -1848,11 +1852,11 @@ function createStackParser(platform, ...parsers) {
1848
1852
  }
1849
1853
  var WEBPACK_ERROR_REGEXP, STACKTRACE_FRAME_LIMIT;
1850
1854
  var init_parsers = __esm({
1851
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/parsers/index.mjs"() {
1855
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/parsers/index.mjs"() {
1852
1856
  init_base();
1853
1857
  init_chrome();
1854
- init_winjs();
1855
1858
  init_gecko();
1859
+ init_winjs();
1856
1860
  init_opera();
1857
1861
  init_node();
1858
1862
  WEBPACK_ERROR_REGEXP = /\(error: (.*)\)/;
@@ -1860,10 +1864,10 @@ var init_parsers = __esm({
1860
1864
  }
1861
1865
  });
1862
1866
 
1863
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/dom-exception-coercer.mjs
1867
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/dom-exception-coercer.mjs
1864
1868
  var DOMExceptionCoercer;
1865
1869
  var init_dom_exception_coercer = __esm({
1866
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/dom-exception-coercer.mjs"() {
1870
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/dom-exception-coercer.mjs"() {
1867
1871
  init_utils();
1868
1872
  DOMExceptionCoercer = class {
1869
1873
  match(err) {
@@ -1897,10 +1901,10 @@ var init_dom_exception_coercer = __esm({
1897
1901
  }
1898
1902
  });
1899
1903
 
1900
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/error-coercer.mjs
1904
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/error-coercer.mjs
1901
1905
  var ErrorCoercer;
1902
1906
  var init_error_coercer = __esm({
1903
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/error-coercer.mjs"() {
1907
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/error-coercer.mjs"() {
1904
1908
  init_utils();
1905
1909
  ErrorCoercer = class {
1906
1910
  match(err) {
@@ -1930,10 +1934,10 @@ var init_error_coercer = __esm({
1930
1934
  }
1931
1935
  });
1932
1936
 
1933
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/error-event-coercer.mjs
1937
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/error-event-coercer.mjs
1934
1938
  var ErrorEventCoercer;
1935
1939
  var init_error_event_coercer = __esm({
1936
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/error-event-coercer.mjs"() {
1940
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/error-event-coercer.mjs"() {
1937
1941
  init_utils();
1938
1942
  ErrorEventCoercer = class {
1939
1943
  constructor() {
@@ -1955,10 +1959,10 @@ var init_error_event_coercer = __esm({
1955
1959
  }
1956
1960
  });
1957
1961
 
1958
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/string-coercer.mjs
1962
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/string-coercer.mjs
1959
1963
  var ERROR_TYPES_PATTERN, StringCoercer;
1960
1964
  var init_string_coercer = __esm({
1961
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/string-coercer.mjs"() {
1965
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/string-coercer.mjs"() {
1962
1966
  ERROR_TYPES_PATTERN = /^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;
1963
1967
  StringCoercer = class {
1964
1968
  match(input) {
@@ -1990,10 +1994,10 @@ var init_string_coercer = __esm({
1990
1994
  }
1991
1995
  });
1992
1996
 
1993
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/types.mjs
1997
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/types.mjs
1994
1998
  var severityLevels;
1995
1999
  var init_types2 = __esm({
1996
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/types.mjs"() {
2000
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/types.mjs"() {
1997
2001
  severityLevels = [
1998
2002
  "fatal",
1999
2003
  "error",
@@ -2005,7 +2009,7 @@ var init_types2 = __esm({
2005
2009
  }
2006
2010
  });
2007
2011
 
2008
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/utils.mjs
2012
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/utils.mjs
2009
2013
  function extractExceptionKeysForMessage(err, maxLength = 40) {
2010
2014
  const keys = Object.keys(err);
2011
2015
  keys.sort();
@@ -2020,14 +2024,14 @@ function extractExceptionKeysForMessage(err, maxLength = 40) {
2020
2024
  return "";
2021
2025
  }
2022
2026
  var init_utils2 = __esm({
2023
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/utils.mjs"() {
2027
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/utils.mjs"() {
2024
2028
  }
2025
2029
  });
2026
2030
 
2027
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/object-coercer.mjs
2031
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/object-coercer.mjs
2028
2032
  var ObjectCoercer;
2029
2033
  var init_object_coercer = __esm({
2030
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/object-coercer.mjs"() {
2034
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/object-coercer.mjs"() {
2031
2035
  init_utils();
2032
2036
  init_types2();
2033
2037
  init_utils2();
@@ -2081,10 +2085,10 @@ var init_object_coercer = __esm({
2081
2085
  }
2082
2086
  });
2083
2087
 
2084
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/event-coercer.mjs
2088
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/event-coercer.mjs
2085
2089
  var EventCoercer;
2086
2090
  var init_event_coercer = __esm({
2087
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/event-coercer.mjs"() {
2091
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/event-coercer.mjs"() {
2088
2092
  init_utils();
2089
2093
  init_utils2();
2090
2094
  EventCoercer = class {
@@ -2104,10 +2108,10 @@ var init_event_coercer = __esm({
2104
2108
  }
2105
2109
  });
2106
2110
 
2107
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/primitive-coercer.mjs
2111
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/primitive-coercer.mjs
2108
2112
  var PrimitiveCoercer;
2109
2113
  var init_primitive_coercer = __esm({
2110
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/primitive-coercer.mjs"() {
2114
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/primitive-coercer.mjs"() {
2111
2115
  init_utils();
2112
2116
  PrimitiveCoercer = class {
2113
2117
  match(candidate) {
@@ -2125,10 +2129,10 @@ var init_primitive_coercer = __esm({
2125
2129
  }
2126
2130
  });
2127
2131
 
2128
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/promise-rejection-event.mjs
2132
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/promise-rejection-event.mjs
2129
2133
  var PromiseRejectionEventCoercer;
2130
2134
  var init_promise_rejection_event = __esm({
2131
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/promise-rejection-event.mjs"() {
2135
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/promise-rejection-event.mjs"() {
2132
2136
  init_utils();
2133
2137
  PromiseRejectionEventCoercer = class {
2134
2138
  match(err) {
@@ -2157,9 +2161,9 @@ var init_promise_rejection_event = __esm({
2157
2161
  }
2158
2162
  });
2159
2163
 
2160
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/index.mjs
2164
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/index.mjs
2161
2165
  var init_coercers = __esm({
2162
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/coercers/index.mjs"() {
2166
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/coercers/index.mjs"() {
2163
2167
  init_dom_exception_coercer();
2164
2168
  init_error_coercer();
2165
2169
  init_error_event_coercer();
@@ -2171,10 +2175,10 @@ var init_coercers = __esm({
2171
2175
  }
2172
2176
  });
2173
2177
 
2174
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/utils.mjs
2178
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/utils.mjs
2175
2179
  var ReduceableCache;
2176
2180
  var init_utils3 = __esm({
2177
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/utils.mjs"() {
2181
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/utils.mjs"() {
2178
2182
  ReduceableCache = class {
2179
2183
  constructor(_maxSize) {
2180
2184
  this._maxSize = _maxSize;
@@ -2200,7 +2204,7 @@ var init_utils3 = __esm({
2200
2204
  }
2201
2205
  });
2202
2206
 
2203
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/index.mjs
2207
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/index.mjs
2204
2208
  var error_tracking_exports = {};
2205
2209
  __export(error_tracking_exports, {
2206
2210
  DOMExceptionCoercer: () => DOMExceptionCoercer,
@@ -2214,6 +2218,7 @@ __export(error_tracking_exports, {
2214
2218
  ReduceableCache: () => ReduceableCache,
2215
2219
  StringCoercer: () => StringCoercer,
2216
2220
  chromeStackLineParser: () => chromeStackLineParser,
2221
+ createDefaultStackParser: () => createDefaultStackParser,
2217
2222
  createStackParser: () => createStackParser,
2218
2223
  geckoStackLineParser: () => geckoStackLineParser,
2219
2224
  nodeStackLineParser: () => nodeStackLineParser,
@@ -2223,7 +2228,7 @@ __export(error_tracking_exports, {
2223
2228
  winjsStackLineParser: () => winjsStackLineParser
2224
2229
  });
2225
2230
  var init_error_tracking = __esm({
2226
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/error-tracking/index.mjs"() {
2231
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/error-tracking/index.mjs"() {
2227
2232
  init_error_properties_builder();
2228
2233
  init_parsers();
2229
2234
  init_coercers();
@@ -2231,9 +2236,9 @@ var init_error_tracking = __esm({
2231
2236
  }
2232
2237
  });
2233
2238
 
2234
- // ../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/index.mjs
2239
+ // ../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/index.mjs
2235
2240
  var init_dist = __esm({
2236
- "../../node_modules/.pnpm/@posthog+core@1.9.0/node_modules/@posthog/core/dist/index.mjs"() {
2241
+ "../../node_modules/.pnpm/@posthog+core@1.9.1/node_modules/@posthog/core/dist/index.mjs"() {
2237
2242
  init_featureFlagUtils();
2238
2243
  init_uuidv7();
2239
2244
  init_utils();
@@ -2424,7 +2429,7 @@ function snipLine(line, colno) {
2424
2429
  }
2425
2430
  var LRU_FILE_CONTENTS_CACHE, LRU_FILE_CONTENTS_FS_READ_FAILED, DEFAULT_LINES_OF_CONTEXT, MAX_CONTEXTLINES_COLNO, MAX_CONTEXTLINES_LINENO;
2426
2431
  var init_context_lines_node = __esm({
2427
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/error-tracking/modifiers/context-lines.node.mjs"() {
2432
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/error-tracking/modifiers/context-lines.node.mjs"() {
2428
2433
  init_dist();
2429
2434
  LRU_FILE_CONTENTS_CACHE = new error_tracking_exports.ReduceableCache(25);
2430
2435
  LRU_FILE_CONTENTS_FS_READ_FAILED = new error_tracking_exports.ReduceableCache(20);
@@ -2434,7 +2439,7 @@ var init_context_lines_node = __esm({
2434
2439
  }
2435
2440
  });
2436
2441
 
2437
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/error-tracking/autocapture.mjs
2442
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/error-tracking/autocapture.mjs
2438
2443
  function makeUncaughtExceptionHandler(captureFn, onFatalFn) {
2439
2444
  let calledFatalError = false;
2440
2445
  return Object.assign((error) => {
@@ -2466,14 +2471,14 @@ function addUnhandledRejectionListener(captureFn) {
2466
2471
  }));
2467
2472
  }
2468
2473
  var init_autocapture = __esm({
2469
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/error-tracking/autocapture.mjs"() {
2474
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/error-tracking/autocapture.mjs"() {
2470
2475
  }
2471
2476
  });
2472
2477
 
2473
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/error-tracking/index.mjs
2478
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/error-tracking/index.mjs
2474
2479
  var SHUTDOWN_TIMEOUT, ErrorTracking;
2475
2480
  var init_error_tracking2 = __esm({
2476
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/error-tracking/index.mjs"() {
2481
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/error-tracking/index.mjs"() {
2477
2482
  init_autocapture();
2478
2483
  init_dist();
2479
2484
  SHUTDOWN_TIMEOUT = 2e3;
@@ -2490,6 +2495,9 @@ var init_error_tracking2 = __esm({
2490
2495
  });
2491
2496
  this.startAutocaptureIfEnabled();
2492
2497
  }
2498
+ static isPreviouslyCapturedError(x) {
2499
+ return isObject(x) && "__posthog_previously_captured_error" in x && true === x.__posthog_previously_captured_error;
2500
+ }
2493
2501
  static async buildEventMessage(error, hint, distinctId, additionalProperties) {
2494
2502
  const properties = {
2495
2503
  ...additionalProperties
@@ -2514,14 +2522,16 @@ var init_error_tracking2 = __esm({
2514
2522
  }
2515
2523
  onException(exception, hint) {
2516
2524
  this.client.addPendingPromise((async () => {
2517
- const eventMessage = await _ErrorTracking.buildEventMessage(exception, hint);
2518
- const exceptionProperties = eventMessage.properties;
2519
- const exceptionType = exceptionProperties?.$exception_list[0]?.type ?? "Exception";
2520
- const isRateLimited = this._rateLimiter.consumeRateLimit(exceptionType);
2521
- if (isRateLimited) return void this._logger.info("Skipping exception capture because of client rate limiting.", {
2522
- exception: exceptionType
2523
- });
2524
- return this.client.capture(eventMessage);
2525
+ if (!_ErrorTracking.isPreviouslyCapturedError(exception)) {
2526
+ const eventMessage = await _ErrorTracking.buildEventMessage(exception, hint);
2527
+ const exceptionProperties = eventMessage.properties;
2528
+ const exceptionType = exceptionProperties?.$exception_list[0]?.type ?? "Exception";
2529
+ const isRateLimited = this._rateLimiter.consumeRateLimit(exceptionType);
2530
+ if (isRateLimited) return void this._logger.info("Skipping exception capture because of client rate limiting.", {
2531
+ exception: exceptionType
2532
+ });
2533
+ return this.client.capture(eventMessage);
2534
+ }
2525
2535
  })());
2526
2536
  }
2527
2537
  async onFatalError(exception) {
@@ -2539,18 +2549,18 @@ var init_error_tracking2 = __esm({
2539
2549
  }
2540
2550
  });
2541
2551
 
2542
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/version.mjs
2552
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/version.mjs
2543
2553
  var version;
2544
2554
  var init_version = __esm({
2545
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/version.mjs"() {
2546
- version = "5.19.0";
2555
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/version.mjs"() {
2556
+ version = "5.21.0";
2547
2557
  }
2548
2558
  });
2549
2559
 
2550
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/types.mjs
2560
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/types.mjs
2551
2561
  var FeatureFlagError;
2552
2562
  var init_types3 = __esm({
2553
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/types.mjs"() {
2563
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/types.mjs"() {
2554
2564
  FeatureFlagError = {
2555
2565
  ERRORS_WHILE_COMPUTING: "errors_while_computing_flags",
2556
2566
  FLAG_MISSING: "flag_missing",
@@ -2560,7 +2570,7 @@ var init_types3 = __esm({
2560
2570
  }
2561
2571
  });
2562
2572
 
2563
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/feature-flags/crypto.mjs
2573
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/feature-flags/crypto.mjs
2564
2574
  async function hashSHA1(text) {
2565
2575
  const subtle = globalThis.crypto?.subtle;
2566
2576
  if (!subtle) throw new Error("SubtleCrypto API not available");
@@ -2569,11 +2579,11 @@ async function hashSHA1(text) {
2569
2579
  return hashArray.map((byte) => byte.toString(16).padStart(2, "0")).join("");
2570
2580
  }
2571
2581
  var init_crypto = __esm({
2572
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/feature-flags/crypto.mjs"() {
2582
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/feature-flags/crypto.mjs"() {
2573
2583
  }
2574
2584
  });
2575
2585
 
2576
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/feature-flags/feature-flags.mjs
2586
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/feature-flags/feature-flags.mjs
2577
2587
  async function _hash(key, distinctId, salt = "") {
2578
2588
  const hashString = await hashSHA1(`${key}.${distinctId}${salt}`);
2579
2589
  return parseInt(hashString.slice(0, 15), 16) / LONG_SCALE;
@@ -2741,7 +2751,7 @@ function relativeDateParseForFeatureFlagMatching(value) {
2741
2751
  }
2742
2752
  var SIXTY_SECONDS, LONG_SCALE, NULL_VALUES_ALLOWED_OPERATORS, ClientError, InconclusiveMatchError, RequiresServerEvaluation, FeatureFlagsPoller;
2743
2753
  var init_feature_flags = __esm({
2744
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/feature-flags/feature-flags.mjs"() {
2754
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/feature-flags/feature-flags.mjs"() {
2745
2755
  init_dist();
2746
2756
  init_crypto();
2747
2757
  SIXTY_SECONDS = 6e4;
@@ -2795,6 +2805,7 @@ var init_feature_flags = __esm({
2795
2805
  this.customHeaders = customHeaders;
2796
2806
  this.onLoad = options.onLoad;
2797
2807
  this.cacheProvider = options.cacheProvider;
2808
+ this.strictLocalEvaluation = options.strictLocalEvaluation ?? false;
2798
2809
  this.loadFeatureFlags();
2799
2810
  }
2800
2811
  debug(enabled = true) {
@@ -2990,6 +3001,11 @@ var init_feature_flags = __esm({
2990
3001
  this.cohorts = flagData.cohorts;
2991
3002
  this.loadedSuccessfullyOnce = true;
2992
3003
  }
3004
+ warnAboutExperienceContinuityFlags(flags) {
3005
+ if (this.strictLocalEvaluation) return;
3006
+ const experienceContinuityFlags = flags.filter((f) => f.ensure_experience_continuity);
3007
+ if (experienceContinuityFlags.length > 0) console.warn(`[PostHog] You are using local evaluation but ${experienceContinuityFlags.length} flag(s) have experience continuity enabled: ${experienceContinuityFlags.map((f) => f.key).join(", ")}. Experience continuity is incompatible with local evaluation and will cause a server request on every flag evaluation, negating local evaluation cost savings. To avoid server requests and unexpected costs, either disable experience continuity on these flags in PostHog, use strictLocalEvaluation: true in client init, or pass onlyEvaluateLocally: true per flag call (flags that cannot be evaluated locally will return undefined).`);
3008
+ }
2993
3009
  async loadFromCache(debugMessage) {
2994
3010
  if (!this.cacheProvider) return false;
2995
3011
  try {
@@ -2998,6 +3014,7 @@ var init_feature_flags = __esm({
2998
3014
  this.updateFlagState(cached);
2999
3015
  this.logMsgIfDebug(() => console.debug(`[FEATURE FLAGS] ${debugMessage} (${cached.flags.length} flags)`));
3000
3016
  this.onLoad?.(this.featureFlags.length);
3017
+ this.warnAboutExperienceContinuityFlags(cached.flags);
3001
3018
  return true;
3002
3019
  }
3003
3020
  return false;
@@ -3091,6 +3108,7 @@ var init_feature_flags = __esm({
3091
3108
  this.onError?.(new Error(`Failed to store in cache: ${err}`));
3092
3109
  }
3093
3110
  this.onLoad?.(this.featureFlags.length);
3111
+ this.warnAboutExperienceContinuityFlags(flagData.flags);
3094
3112
  break;
3095
3113
  }
3096
3114
  default:
@@ -3146,10 +3164,10 @@ var init_feature_flags = __esm({
3146
3164
  }
3147
3165
  });
3148
3166
 
3149
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/storage-memory.mjs
3167
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/storage-memory.mjs
3150
3168
  var PostHogMemoryStorage;
3151
3169
  var init_storage_memory = __esm({
3152
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/storage-memory.mjs"() {
3170
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/storage-memory.mjs"() {
3153
3171
  PostHogMemoryStorage = class {
3154
3172
  getProperty(key) {
3155
3173
  return this._memoryStorage[key];
@@ -3164,10 +3182,10 @@ var init_storage_memory = __esm({
3164
3182
  }
3165
3183
  });
3166
3184
 
3167
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/client.mjs
3185
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/client.mjs
3168
3186
  var MINIMUM_POLLING_INTERVAL, THIRTY_SECONDS, MAX_CACHE_SIZE, PostHogBackendClient;
3169
3187
  var init_client = __esm({
3170
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/client.mjs"() {
3188
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/client.mjs"() {
3171
3189
  init_version();
3172
3190
  init_dist();
3173
3191
  init_types3();
@@ -3200,7 +3218,8 @@ var init_client = __esm({
3200
3218
  this._events.emit("localEvaluationFlagsLoaded", count);
3201
3219
  },
3202
3220
  customHeaders: this.getCustomHeaders(),
3203
- cacheProvider: options.flagDefinitionCacheProvider
3221
+ cacheProvider: options.flagDefinitionCacheProvider,
3222
+ strictLocalEvaluation: options.strictLocalEvaluation
3204
3223
  });
3205
3224
  }
3206
3225
  this.errorTracking = new ErrorTracking(this, options, this._logger);
@@ -3313,7 +3332,7 @@ var init_client = __esm({
3313
3332
  const adjustedProperties = this.addLocalPersonAndGroupProperties(distinctId, groups, personProperties, groupProperties);
3314
3333
  personProperties = adjustedProperties.allPersonProperties;
3315
3334
  groupProperties = adjustedProperties.allGroupProperties;
3316
- if (void 0 == onlyEvaluateLocally) onlyEvaluateLocally = false;
3335
+ if (void 0 == onlyEvaluateLocally) onlyEvaluateLocally = this.options.strictLocalEvaluation ?? false;
3317
3336
  if (void 0 == sendFeatureFlagEvents) sendFeatureFlagEvents = this.options.sendFeatureFlagEvent ?? true;
3318
3337
  let response = await this.featureFlagsPoller?.getFeatureFlag(key, distinctId, groups, personProperties, groupProperties);
3319
3338
  const flagWasLocallyEvaluated = void 0 !== response;
@@ -3390,7 +3409,7 @@ var init_client = __esm({
3390
3409
  else throw e;
3391
3410
  }
3392
3411
  }
3393
- if (void 0 == onlyEvaluateLocally) onlyEvaluateLocally = false;
3412
+ if (void 0 == onlyEvaluateLocally) onlyEvaluateLocally = this.options.strictLocalEvaluation ?? false;
3394
3413
  const payloadWasLocallyEvaluated = void 0 !== response;
3395
3414
  if (!payloadWasLocallyEvaluated && !onlyEvaluateLocally) response = await super.getFeatureFlagPayloadStateless(key, distinctId, groups, personProperties, groupProperties, disableGeoip);
3396
3415
  return response;
@@ -3421,7 +3440,7 @@ var init_client = __esm({
3421
3440
  const adjustedProperties = this.addLocalPersonAndGroupProperties(distinctId, groups, personProperties, groupProperties);
3422
3441
  personProperties = adjustedProperties.allPersonProperties;
3423
3442
  groupProperties = adjustedProperties.allGroupProperties;
3424
- if (void 0 == onlyEvaluateLocally) onlyEvaluateLocally = false;
3443
+ if (void 0 == onlyEvaluateLocally) onlyEvaluateLocally = this.options.strictLocalEvaluation ?? false;
3425
3444
  const localEvaluationResult = await this.featureFlagsPoller?.getAllFlagsAndPayloads(distinctId, groups, personProperties, groupProperties, flagKeys);
3426
3445
  let featureFlags = {};
3427
3446
  let featureFlagPayloads = {};
@@ -3571,7 +3590,7 @@ var init_client = __esm({
3571
3590
  const finalPersonProperties = sendFeatureFlagsOptions?.personProperties || {};
3572
3591
  const finalGroupProperties = sendFeatureFlagsOptions?.groupProperties || {};
3573
3592
  const flagKeys = sendFeatureFlagsOptions?.flagKeys;
3574
- const onlyEvaluateLocally = sendFeatureFlagsOptions?.onlyEvaluateLocally ?? false;
3593
+ const onlyEvaluateLocally = sendFeatureFlagsOptions?.onlyEvaluateLocally ?? this.options.strictLocalEvaluation ?? false;
3575
3594
  if (onlyEvaluateLocally) if (!((this.featureFlagsPoller?.featureFlags?.length || 0) > 0)) return {};
3576
3595
  else {
3577
3596
  const groupsWithStringValues = {};
@@ -3614,17 +3633,24 @@ var init_client = __esm({
3614
3633
  allGroupProperties
3615
3634
  };
3616
3635
  }
3617
- captureException(error, distinctId, additionalProperties) {
3618
- const syntheticException = new Error("PostHog syntheticException");
3619
- this.addPendingPromise(ErrorTracking.buildEventMessage(error, {
3620
- syntheticException
3621
- }, distinctId, additionalProperties).then((msg) => this.capture(msg)));
3636
+ captureException(error, distinctId, additionalProperties, uuid) {
3637
+ if (!ErrorTracking.isPreviouslyCapturedError(error)) {
3638
+ const syntheticException = new Error("PostHog syntheticException");
3639
+ this.addPendingPromise(ErrorTracking.buildEventMessage(error, {
3640
+ syntheticException
3641
+ }, distinctId, additionalProperties).then((msg) => this.capture({
3642
+ ...msg,
3643
+ uuid
3644
+ })));
3645
+ }
3622
3646
  }
3623
3647
  async captureExceptionImmediate(error, distinctId, additionalProperties) {
3624
- const syntheticException = new Error("PostHog syntheticException");
3625
- this.addPendingPromise(ErrorTracking.buildEventMessage(error, {
3626
- syntheticException
3627
- }, distinctId, additionalProperties).then((msg) => this.captureImmediate(msg)));
3648
+ if (!ErrorTracking.isPreviouslyCapturedError(error)) {
3649
+ const syntheticException = new Error("PostHog syntheticException");
3650
+ this.addPendingPromise(ErrorTracking.buildEventMessage(error, {
3651
+ syntheticException
3652
+ }, distinctId, additionalProperties).then((msg) => this.captureImmediate(msg)));
3653
+ }
3628
3654
  }
3629
3655
  async prepareEventMessage(props) {
3630
3656
  const { distinctId, event, properties, groups, sendFeatureFlags, timestamp, disableGeoip, uuid } = props;
@@ -3713,7 +3739,7 @@ var init_client = __esm({
3713
3739
  });
3714
3740
  var PostHogContext;
3715
3741
  var init_context = __esm({
3716
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/context/context.mjs"() {
3742
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/context/context.mjs"() {
3717
3743
  PostHogContext = class {
3718
3744
  constructor() {
3719
3745
  this.storage = new async_hooks.AsyncLocalStorage();
@@ -3741,7 +3767,7 @@ var init_context = __esm({
3741
3767
  }
3742
3768
  });
3743
3769
 
3744
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/sentry-integration.mjs
3770
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/sentry-integration.mjs
3745
3771
  function createEventProcessor(_posthog, { organization, projectId, prefix, severityAllowList = [
3746
3772
  "error"
3747
3773
  ], sendExceptionsToPostHog = true } = {}) {
@@ -3797,7 +3823,7 @@ function sentryIntegration(_posthog, options) {
3797
3823
  }
3798
3824
  var NAME, PostHogSentryIntegration;
3799
3825
  var init_sentry_integration = __esm({
3800
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/sentry-integration.mjs"() {
3826
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/sentry-integration.mjs"() {
3801
3827
  NAME = "posthog-node";
3802
3828
  PostHogSentryIntegration = class {
3803
3829
  static #_ = this.POSTHOG_ID_TAG = "posthog_distinct_id";
@@ -3819,12 +3845,13 @@ var init_sentry_integration = __esm({
3819
3845
  }
3820
3846
  });
3821
3847
 
3822
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/express.mjs
3848
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/express.mjs
3823
3849
  function setupExpressErrorHandler(_posthog, app) {
3824
3850
  app.use(posthogErrorHandler(_posthog));
3825
3851
  }
3826
3852
  function posthogErrorHandler(posthog) {
3827
3853
  return (error, req, res, next) => {
3854
+ if (ErrorTracking.isPreviouslyCapturedError(error)) return void next(error);
3828
3855
  const sessionId = req.headers["x-posthog-session-id"];
3829
3856
  const distinctId = req.headers["x-posthog-distinct-id"];
3830
3857
  const syntheticException = new Error("Synthetic exception");
@@ -3850,21 +3877,21 @@ function posthogErrorHandler(posthog) {
3850
3877
  };
3851
3878
  }
3852
3879
  var init_express = __esm({
3853
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/extensions/express.mjs"() {
3880
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/extensions/express.mjs"() {
3854
3881
  init_error_tracking2();
3855
3882
  }
3856
3883
  });
3857
3884
 
3858
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/exports.mjs
3885
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/exports.mjs
3859
3886
  var init_exports = __esm({
3860
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/exports.mjs"() {
3887
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/exports.mjs"() {
3861
3888
  init_sentry_integration();
3862
3889
  init_express();
3863
3890
  init_types3();
3864
3891
  }
3865
3892
  });
3866
3893
 
3867
- // ../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/entrypoints/index.node.mjs
3894
+ // ../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/entrypoints/index.node.mjs
3868
3895
  var index_node_exports = {};
3869
3896
  __export(index_node_exports, {
3870
3897
  FeatureFlagError: () => FeatureFlagError,
@@ -3876,7 +3903,7 @@ __export(index_node_exports, {
3876
3903
  });
3877
3904
  var PostHog;
3878
3905
  var init_index_node = __esm({
3879
- "../../node_modules/.pnpm/posthog-node@5.19.0/node_modules/posthog-node/dist/entrypoints/index.node.mjs"() {
3906
+ "../../node_modules/.pnpm/posthog-node@5.21.0/node_modules/posthog-node/dist/entrypoints/index.node.mjs"() {
3880
3907
  init_module_node();
3881
3908
  init_context_lines_node();
3882
3909
  init_error_tracking2();
@@ -5167,9 +5194,9 @@ var require_dist2 = __commonJS({
5167
5194
  }
5168
5195
  });
5169
5196
 
5170
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/package.json
5197
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/package.json
5171
5198
  var require_package = __commonJS({
5172
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/package.json"(exports$1, module) {
5199
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/package.json"(exports$1, module) {
5173
5200
  module.exports = {
5174
5201
  name: "mixpanel",
5175
5202
  description: "A simple server-side API for mixpanel",
@@ -5179,7 +5206,7 @@ var require_package = __commonJS({
5179
5206
  "api",
5180
5207
  "stats"
5181
5208
  ],
5182
- version: "0.19.1",
5209
+ version: "0.20.0",
5183
5210
  homepage: "https://github.com/mixpanel/mixpanel-node",
5184
5211
  author: "Carl Sverre",
5185
5212
  license: "MIT",
@@ -5195,29 +5222,35 @@ var require_package = __commonJS({
5195
5222
  node: ">=10.0"
5196
5223
  },
5197
5224
  scripts: {
5198
- test: "vitest"
5225
+ test: "vitest",
5226
+ format: "prettier --write .",
5227
+ "check-format": "prettier --check .",
5228
+ lint: "oxlint ."
5199
5229
  },
5200
5230
  types: "./lib/mixpanel-node.d.ts",
5201
5231
  devDependencies: {
5202
5232
  "@types/node": "^24.10.1",
5203
5233
  "@vitest/coverage-v8": "^4.0.8",
5204
5234
  nock: "^14.0.10",
5235
+ oxlint: "^1.16.0",
5236
+ prettier: "^3.6.2",
5205
5237
  proxyquire: "^2.1.3",
5206
5238
  typescript: "^5.9.3",
5207
5239
  vitest: "^4.0.8"
5208
5240
  },
5209
5241
  dependencies: {
5210
- "https-proxy-agent": "7.0.6"
5242
+ "https-proxy-agent": "7.0.6",
5243
+ "json-logic-js": "2.0.5"
5211
5244
  }
5212
5245
  };
5213
5246
  }
5214
5247
  });
5215
5248
 
5216
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/utils.js
5249
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/utils.js
5217
5250
  var require_utils = __commonJS({
5218
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/utils.js"(exports$1) {
5251
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/utils.js"(exports$1) {
5219
5252
  exports$1.async_all = function(requests, handler, callback) {
5220
- var total = requests.length, errors = null, results = [], done = function(err, result) {
5253
+ let total = requests.length, errors = null, results = [], done = function(err, result) {
5221
5254
  if (err) {
5222
5255
  errors = errors || [];
5223
5256
  errors.push(err);
@@ -5230,14 +5263,16 @@ var require_utils = __commonJS({
5230
5263
  if (total === 0) {
5231
5264
  callback(errors, results);
5232
5265
  } else {
5233
- for (var i = 0, l = requests.length; i < l; i++) {
5266
+ for (let i = 0, l = requests.length; i < l; i++) {
5234
5267
  handler(requests[i], done);
5235
5268
  }
5236
5269
  }
5237
5270
  };
5238
5271
  exports$1.ensure_timestamp = function(time) {
5239
5272
  if (!(time instanceof Date || typeof time === "number")) {
5240
- throw new Error("`time` property must be a Date or Unix timestamp and is only required for `import` endpoint");
5273
+ throw new Error(
5274
+ "`time` property must be a Date or Unix timestamp and is only required for `import` endpoint"
5275
+ );
5241
5276
  }
5242
5277
  return time instanceof Date ? time.getTime() : time;
5243
5278
  };
@@ -5254,9 +5289,9 @@ var require_utils = __commonJS({
5254
5289
  }
5255
5290
  });
5256
5291
 
5257
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/profile_helpers.js
5292
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/profile_helpers.js
5258
5293
  var require_profile_helpers = __commonJS({
5259
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/profile_helpers.js"(exports$1) {
5294
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/profile_helpers.js"(exports$1) {
5260
5295
  var { ensure_timestamp } = require_utils();
5261
5296
  function merge_modifiers(data, modifiers) {
5262
5297
  if (modifiers) {
@@ -5304,7 +5339,7 @@ var require_profile_helpers = __commonJS({
5304
5339
  }
5305
5340
  }
5306
5341
  let data = {
5307
- "$token": this.token,
5342
+ $token: this.token,
5308
5343
  ...identifiers
5309
5344
  };
5310
5345
  const set_key = set_once ? "$set_once" : "$set";
@@ -5319,14 +5354,20 @@ var require_profile_helpers = __commonJS({
5319
5354
  }
5320
5355
  data = merge_modifiers(data, modifiers);
5321
5356
  if (this.config.debug) {
5322
- this.mixpanel.config.logger.debug(`Sending the following data to Mixpanel (${this.endpoint})`, { data });
5357
+ this.mixpanel.config.logger.debug(
5358
+ `Sending the following data to Mixpanel (${this.endpoint})`,
5359
+ { data }
5360
+ );
5323
5361
  }
5324
- this.mixpanel.send_request({ method: "GET", endpoint: this.endpoint, data }, callback);
5362
+ this.mixpanel.send_request(
5363
+ { method: "GET", endpoint: this.endpoint, data },
5364
+ callback
5365
+ );
5325
5366
  }
5326
5367
  _delete_profile({ identifiers, modifiers, callback }) {
5327
5368
  let data = {
5328
- "$delete": "",
5329
- "$token": this.token,
5369
+ $delete: "",
5370
+ $token: this.token,
5330
5371
  ...identifiers
5331
5372
  };
5332
5373
  if (typeof modifiers === "function") {
@@ -5336,13 +5377,18 @@ var require_profile_helpers = __commonJS({
5336
5377
  if (this.config.debug) {
5337
5378
  this.mixpanel.config.logger.debug("Deleting profile", { identifiers });
5338
5379
  }
5339
- this.mixpanel.send_request({ method: "GET", endpoint: this.endpoint, data }, callback);
5380
+ this.mixpanel.send_request(
5381
+ { method: "GET", endpoint: this.endpoint, data },
5382
+ callback
5383
+ );
5340
5384
  }
5341
5385
  _remove({ identifiers, data, modifiers, callback }) {
5342
5386
  let $remove = {};
5343
5387
  if (typeof data !== "object" || Array.isArray(data)) {
5344
5388
  if (this.config.debug) {
5345
- this.mixpanel.config.logger.error("Invalid value passed to #remove - data must be an object with scalar values");
5389
+ this.mixpanel.config.logger.error(
5390
+ "Invalid value passed to #remove - data must be an object with scalar values"
5391
+ );
5346
5392
  }
5347
5393
  return;
5348
5394
  }
@@ -5363,8 +5409,8 @@ var require_profile_helpers = __commonJS({
5363
5409
  return;
5364
5410
  }
5365
5411
  data = {
5366
- "$remove": $remove,
5367
- "$token": this.token,
5412
+ $remove,
5413
+ $token: this.token,
5368
5414
  ...identifiers
5369
5415
  };
5370
5416
  if (typeof modifiers === "function") {
@@ -5377,19 +5423,24 @@ var require_profile_helpers = __commonJS({
5377
5423
  { data }
5378
5424
  );
5379
5425
  }
5380
- this.mixpanel.send_request({ method: "GET", endpoint: this.endpoint, data }, callback);
5426
+ this.mixpanel.send_request(
5427
+ { method: "GET", endpoint: this.endpoint, data },
5428
+ callback
5429
+ );
5381
5430
  }
5382
5431
  _union({ identifiers, data, modifiers, callback }) {
5383
5432
  let $union = {};
5384
5433
  if (typeof data !== "object" || Array.isArray(data)) {
5385
5434
  if (this.config.debug) {
5386
- this.mixpanel.config.logger.error("Invalid value passed to #union - data must be an object with scalar or array values");
5435
+ this.mixpanel.config.logger.error(
5436
+ "Invalid value passed to #union - data must be an object with scalar or array values"
5437
+ );
5387
5438
  }
5388
5439
  return;
5389
5440
  }
5390
5441
  for (const [key, val] of Object.entries(data)) {
5391
5442
  if (Array.isArray(val)) {
5392
- var merge_values = val.filter(function(v) {
5443
+ const merge_values = val.filter(function(v) {
5393
5444
  return typeof v === "string" || typeof v === "number";
5394
5445
  });
5395
5446
  if (merge_values.length > 0) {
@@ -5410,8 +5461,8 @@ var require_profile_helpers = __commonJS({
5410
5461
  return;
5411
5462
  }
5412
5463
  data = {
5413
- "$union": $union,
5414
- "$token": this.token,
5464
+ $union,
5465
+ $token: this.token,
5415
5466
  ...identifiers
5416
5467
  };
5417
5468
  if (typeof modifiers === "function") {
@@ -5424,7 +5475,10 @@ var require_profile_helpers = __commonJS({
5424
5475
  { data }
5425
5476
  );
5426
5477
  }
5427
- this.mixpanel.send_request({ method: "GET", endpoint: this.endpoint, data }, callback);
5478
+ this.mixpanel.send_request(
5479
+ { method: "GET", endpoint: this.endpoint, data },
5480
+ callback
5481
+ );
5428
5482
  }
5429
5483
  _unset({ identifiers, prop, modifiers, callback }) {
5430
5484
  let $unset = [];
@@ -5442,8 +5496,8 @@ var require_profile_helpers = __commonJS({
5442
5496
  return;
5443
5497
  }
5444
5498
  let data = {
5445
- "$unset": $unset,
5446
- "$token": this.token,
5499
+ $unset,
5500
+ $token: this.token,
5447
5501
  ...identifiers
5448
5502
  };
5449
5503
  if (typeof modifiers === "function") {
@@ -5456,15 +5510,18 @@ var require_profile_helpers = __commonJS({
5456
5510
  { data }
5457
5511
  );
5458
5512
  }
5459
- this.mixpanel.send_request({ method: "GET", endpoint: this.endpoint, data }, callback);
5513
+ this.mixpanel.send_request(
5514
+ { method: "GET", endpoint: this.endpoint, data },
5515
+ callback
5516
+ );
5460
5517
  }
5461
5518
  };
5462
5519
  }
5463
5520
  });
5464
5521
 
5465
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/groups.js
5522
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/groups.js
5466
5523
  var require_groups = __commonJS({
5467
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/groups.js"(exports$1) {
5524
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/groups.js"(exports$1) {
5468
5525
  var { ProfileHelpers } = require_profile_helpers();
5469
5526
  var MixpanelGroups = class extends ProfileHelpers() {
5470
5527
  constructor(mp_instance) {
@@ -5473,9 +5530,9 @@ var require_groups = __commonJS({
5473
5530
  this.endpoint = "/groups";
5474
5531
  }
5475
5532
  /** groups.set_once(group_key, group_id, prop, to, modifiers, callback)
5476
- ---
5477
- The same as groups.set, but adds a property value to a group only if it has not been set before.
5478
- */
5533
+ ---
5534
+ The same as groups.set, but adds a property value to a group only if it has not been set before.
5535
+ */
5479
5536
  set_once(group_key, group_id, prop, to, modifiers, callback) {
5480
5537
  const identifiers = { $group_key: group_key, $group_id: group_id };
5481
5538
  this._set(prop, to, modifiers, callback, { identifiers, set_once: true });
@@ -5564,9 +5621,9 @@ var require_groups = __commonJS({
5564
5621
  }
5565
5622
  });
5566
5623
 
5567
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/people.js
5624
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/people.js
5568
5625
  var require_people = __commonJS({
5569
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/people.js"(exports$1) {
5626
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/people.js"(exports$1) {
5570
5627
  var { merge_modifiers, ProfileHelpers } = require_profile_helpers();
5571
5628
  var MixpanelPeople = class extends ProfileHelpers() {
5572
5629
  constructor(mp_instance) {
@@ -5632,7 +5689,7 @@ var require_people = __commonJS({
5632
5689
  });
5633
5690
  */
5634
5691
  increment(distinct_id, prop, by, modifiers, callback) {
5635
- var $add = {};
5692
+ const $add = {};
5636
5693
  if (typeof prop === "object") {
5637
5694
  if (typeof by === "object") {
5638
5695
  callback = modifiers;
@@ -5668,16 +5725,22 @@ var require_people = __commonJS({
5668
5725
  $add[prop] = 1;
5669
5726
  }
5670
5727
  }
5671
- var data = {
5672
- "$add": $add,
5673
- "$token": this.mixpanel.token,
5674
- "$distinct_id": distinct_id
5728
+ let data = {
5729
+ $add,
5730
+ $token: this.mixpanel.token,
5731
+ $distinct_id: distinct_id
5675
5732
  };
5676
5733
  data = merge_modifiers(data, modifiers);
5677
5734
  if (this.mixpanel.config.debug) {
5678
- this.mixpanel.config.logger.debug("Sending the following data to Mixpanel (Engage)", { data });
5735
+ this.mixpanel.config.logger.debug(
5736
+ "Sending the following data to Mixpanel (Engage)",
5737
+ { data }
5738
+ );
5679
5739
  }
5680
- this.mixpanel.send_request({ method: "GET", endpoint: "/engage", data }, callback);
5740
+ this.mixpanel.send_request(
5741
+ { method: "GET", endpoint: "/engage", data },
5742
+ callback
5743
+ );
5681
5744
  }
5682
5745
  /**
5683
5746
  people.append(distinct_id, prop, value, modifiers, callback)
@@ -5696,7 +5759,7 @@ var require_people = __commonJS({
5696
5759
  });
5697
5760
  */
5698
5761
  append(distinct_id, prop, value, modifiers, callback) {
5699
- var $append = {};
5762
+ const $append = {};
5700
5763
  if (typeof prop === "object") {
5701
5764
  if (typeof value === "object") {
5702
5765
  callback = modifiers;
@@ -5713,16 +5776,22 @@ var require_people = __commonJS({
5713
5776
  callback = modifiers;
5714
5777
  }
5715
5778
  }
5716
- var data = {
5717
- "$append": $append,
5718
- "$token": this.mixpanel.token,
5719
- "$distinct_id": distinct_id
5779
+ let data = {
5780
+ $append,
5781
+ $token: this.mixpanel.token,
5782
+ $distinct_id: distinct_id
5720
5783
  };
5721
5784
  data = merge_modifiers(data, modifiers);
5722
5785
  if (this.mixpanel.config.debug) {
5723
- this.mixpanel.config.logger.debug("Sending the following data to Mixpanel (Engage)", { data });
5786
+ this.mixpanel.config.logger.debug(
5787
+ "Sending the following data to Mixpanel (Engage)",
5788
+ { data }
5789
+ );
5724
5790
  }
5725
- this.mixpanel.send_request({ method: "GET", endpoint: "/engage", data }, callback);
5791
+ this.mixpanel.send_request(
5792
+ { method: "GET", endpoint: "/engage", data },
5793
+ callback
5794
+ );
5726
5795
  }
5727
5796
  /**
5728
5797
  people.track_charge(distinct_id, amount, properties, modifiers, callback)
@@ -5757,27 +5826,35 @@ var require_people = __commonJS({
5757
5826
  if (typeof amount !== "number") {
5758
5827
  amount = parseFloat(amount);
5759
5828
  if (isNaN(amount)) {
5760
- this.mixpanel.config.logger.error("Invalid value passed to mixpanel.people.track_charge - must be a number");
5829
+ this.mixpanel.config.logger.error(
5830
+ "Invalid value passed to mixpanel.people.track_charge - must be a number"
5831
+ );
5761
5832
  return;
5762
5833
  }
5763
5834
  }
5764
5835
  properties.$amount = amount;
5765
5836
  if (properties.hasOwnProperty("$time")) {
5766
- var time = properties.$time;
5837
+ const time = properties.$time;
5767
5838
  if (Object.prototype.toString.call(time) === "[object Date]") {
5768
5839
  properties.$time = time.toISOString();
5769
5840
  }
5770
5841
  }
5771
- var data = {
5772
- "$append": { "$transactions": properties },
5773
- "$token": this.mixpanel.token,
5774
- "$distinct_id": distinct_id
5842
+ let data = {
5843
+ $append: { $transactions: properties },
5844
+ $token: this.mixpanel.token,
5845
+ $distinct_id: distinct_id
5775
5846
  };
5776
5847
  data = merge_modifiers(data, modifiers);
5777
5848
  if (this.mixpanel.config.debug) {
5778
- this.mixpanel.config.logger.debug("Sending the following data to Mixpanel (Engage)", { data });
5849
+ this.mixpanel.config.logger.debug(
5850
+ "Sending the following data to Mixpanel (Engage)",
5851
+ { data }
5852
+ );
5779
5853
  }
5780
- this.mixpanel.send_request({ method: "GET", endpoint: "/engage", data }, callback);
5854
+ this.mixpanel.send_request(
5855
+ { method: "GET", endpoint: "/engage", data },
5856
+ callback
5857
+ );
5781
5858
  }
5782
5859
  /**
5783
5860
  people.clear_charges(distinct_id, modifiers, callback)
@@ -5789,19 +5866,24 @@ var require_people = __commonJS({
5789
5866
  mixpanel.people.clear_charges('bob');
5790
5867
  */
5791
5868
  clear_charges(distinct_id, modifiers, callback) {
5792
- var data = {
5793
- "$set": { "$transactions": [] },
5794
- "$token": this.mixpanel.token,
5795
- "$distinct_id": distinct_id
5869
+ let data = {
5870
+ $set: { $transactions: [] },
5871
+ $token: this.mixpanel.token,
5872
+ $distinct_id: distinct_id
5796
5873
  };
5797
5874
  if (typeof modifiers === "function") {
5798
5875
  callback = modifiers;
5799
5876
  }
5800
5877
  data = merge_modifiers(data, modifiers);
5801
5878
  if (this.mixpanel.config.debug) {
5802
- this.mixpanel.config.logger.debug("Clearing this user's charges", { "$distinct_id": distinct_id });
5879
+ this.mixpanel.config.logger.debug("Clearing this user's charges", {
5880
+ $distinct_id: distinct_id
5881
+ });
5803
5882
  }
5804
- this.mixpanel.send_request({ method: "GET", endpoint: "/engage", data }, callback);
5883
+ this.mixpanel.send_request(
5884
+ { method: "GET", endpoint: "/engage", data },
5885
+ callback
5886
+ );
5805
5887
  }
5806
5888
  /**
5807
5889
  people.delete_user(distinct_id, modifiers, callback)
@@ -5828,7 +5910,7 @@ var require_people = __commonJS({
5828
5910
  mixpanel.people.remove('bob', {'browsers': 'chrome', 'os': 'linux'});
5829
5911
  */
5830
5912
  remove(distinct_id, data, modifiers, callback) {
5831
- const identifiers = { "$distinct_id": distinct_id };
5913
+ const identifiers = { $distinct_id: distinct_id };
5832
5914
  this._remove({ identifiers, data, modifiers, callback });
5833
5915
  }
5834
5916
  /**
@@ -5866,9 +5948,9 @@ var require_people = __commonJS({
5866
5948
  }
5867
5949
  });
5868
5950
 
5869
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/flags/utils.js
5951
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/flags/utils.js
5870
5952
  var require_utils2 = __commonJS({
5871
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/flags/utils.js"(exports$1, module) {
5953
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/flags/utils.js"(exports$1, module) {
5872
5954
  var crypto3 = __require("crypto");
5873
5955
  var EXPOSURE_EVENT = "$experiment_started";
5874
5956
  var REQUEST_HEADERS = {
@@ -5903,22 +5985,55 @@ var require_utils2 = __commonJS({
5903
5985
  const traceFlags = "01";
5904
5986
  return `${version3}-${traceId}-${parentId}-${traceFlags}`;
5905
5987
  }
5988
+ function lowercaseJson(obj, lowercaseKeys) {
5989
+ if (obj === null || obj === void 0) {
5990
+ return obj;
5991
+ } else if (typeof obj === "string") {
5992
+ return obj.toLowerCase();
5993
+ } else if (typeof obj === "object") {
5994
+ if (Array.isArray(obj)) {
5995
+ return obj.map((item) => lowercaseJson(item, lowercaseKeys));
5996
+ } else {
5997
+ return Object.fromEntries(
5998
+ Object.entries(obj).map(([k, v]) => [
5999
+ lowercaseKeys ? k.toLowerCase() : k,
6000
+ lowercaseJson(v, lowercaseKeys)
6001
+ ])
6002
+ );
6003
+ }
6004
+ } else {
6005
+ return obj;
6006
+ }
6007
+ }
6008
+ function lowercaseAllKeysAndValues(obj) {
6009
+ return lowercaseJson(obj, true);
6010
+ }
6011
+ function lowercaseLeafNodes(obj) {
6012
+ return lowercaseJson(obj, false);
6013
+ }
5906
6014
  module.exports = {
5907
6015
  EXPOSURE_EVENT,
5908
6016
  REQUEST_HEADERS,
5909
6017
  normalizedHash,
5910
6018
  prepareCommonQueryParams,
5911
- generateTraceparent
6019
+ generateTraceparent,
6020
+ lowercaseAllKeysAndValues,
6021
+ lowercaseLeafNodes
5912
6022
  };
5913
6023
  }
5914
6024
  });
5915
6025
 
5916
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/flags/flags.js
6026
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/flags/flags.js
5917
6027
  var require_flags = __commonJS({
5918
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/flags/flags.js"(exports$1, module) {
6028
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/flags/flags.js"(exports$1, module) {
5919
6029
  var https3 = __require("https");
5920
6030
  var packageInfo = require_package();
5921
- var { prepareCommonQueryParams, generateTraceparent, EXPOSURE_EVENT, REQUEST_HEADERS } = require_utils2();
6031
+ var {
6032
+ prepareCommonQueryParams,
6033
+ generateTraceparent,
6034
+ EXPOSURE_EVENT,
6035
+ REQUEST_HEADERS
6036
+ } = require_utils2();
5922
6037
  var FeatureFlagsProvider = class {
5923
6038
  /**
5924
6039
  * @param {Object} providerConfig - Configuration object with token, api_host, request_timeout_in_seconds
@@ -5941,7 +6056,10 @@ var require_flags = __commonJS({
5941
6056
  */
5942
6057
  async callFlagsEndpoint(additionalParams = null) {
5943
6058
  return new Promise((resolve, reject) => {
5944
- const commonParams = prepareCommonQueryParams(this.providerConfig.token, packageInfo.version);
6059
+ const commonParams = prepareCommonQueryParams(
6060
+ this.providerConfig.token,
6061
+ packageInfo.version
6062
+ );
5945
6063
  const params = new URLSearchParams(commonParams);
5946
6064
  if (additionalParams) {
5947
6065
  for (const [key, value] of Object.entries(additionalParams)) {
@@ -5956,8 +6074,8 @@ var require_flags = __commonJS({
5956
6074
  method: "GET",
5957
6075
  headers: {
5958
6076
  ...REQUEST_HEADERS,
5959
- "Authorization": "Basic " + Buffer.from(this.providerConfig.token + ":").toString("base64"),
5960
- "traceparent": generateTraceparent()
6077
+ Authorization: "Basic " + Buffer.from(this.providerConfig.token + ":").toString("base64"),
6078
+ traceparent: generateTraceparent()
5961
6079
  },
5962
6080
  timeout: this.providerConfig.request_timeout_in_seconds * 1e3
5963
6081
  };
@@ -5968,20 +6086,26 @@ var require_flags = __commonJS({
5968
6086
  });
5969
6087
  res.on("end", () => {
5970
6088
  if (res.statusCode !== 200) {
5971
- this.logger?.error(`HTTP ${res.statusCode} error calling flags endpoint: ${data}`);
6089
+ this.logger?.error(
6090
+ `HTTP ${res.statusCode} error calling flags endpoint: ${data}`
6091
+ );
5972
6092
  return reject(new Error(`HTTP ${res.statusCode}: ${data}`));
5973
6093
  }
5974
6094
  try {
5975
6095
  const result = JSON.parse(data);
5976
6096
  resolve(result);
5977
6097
  } catch (parseErr) {
5978
- this.logger?.error(`Failed to parse JSON response: ${parseErr.message}`);
6098
+ this.logger?.error(
6099
+ `Failed to parse JSON response: ${parseErr.message}`
6100
+ );
5979
6101
  reject(parseErr);
5980
6102
  }
5981
6103
  });
5982
6104
  });
5983
6105
  request.on("error", (err) => {
5984
- this.logger?.error(`Network error calling flags endpoint: ${err.message}`);
6106
+ this.logger?.error(
6107
+ `Network error calling flags endpoint: ${err.message}`
6108
+ );
5985
6109
  reject(err);
5986
6110
  });
5987
6111
  request.on("timeout", () => {
@@ -6003,14 +6127,16 @@ var require_flags = __commonJS({
6003
6127
  */
6004
6128
  trackExposureEvent(flagKey, selectedVariant, context, latencyMs = null) {
6005
6129
  if (!context.distinct_id) {
6006
- this.logger?.error("Cannot track exposure event without a distinct_id in the context");
6130
+ this.logger?.error(
6131
+ "Cannot track exposure event without a distinct_id in the context"
6132
+ );
6007
6133
  return;
6008
6134
  }
6009
6135
  const properties = {
6010
- "distinct_id": context.distinct_id,
6136
+ distinct_id: context.distinct_id,
6011
6137
  "Experiment name": flagKey,
6012
6138
  "Variant name": selectedVariant.variant_key,
6013
- "$experiment_type": "feature_flag",
6139
+ $experiment_type: "feature_flag",
6014
6140
  "Flag evaluation mode": this.evaluationMode
6015
6141
  };
6016
6142
  if (latencyMs !== null && latencyMs !== void 0) {
@@ -6027,7 +6153,9 @@ var require_flags = __commonJS({
6027
6153
  }
6028
6154
  this.tracker(EXPOSURE_EVENT, properties, (err) => {
6029
6155
  if (err) {
6030
- this.logger?.error(`[flags]Failed to track exposure event for flag '${flagKey}': ${err.message}`);
6156
+ this.logger?.error(
6157
+ `[flags]Failed to track exposure event for flag '${flagKey}': ${err.message}`
6158
+ );
6031
6159
  }
6032
6160
  });
6033
6161
  }
@@ -6036,11 +6164,392 @@ var require_flags = __commonJS({
6036
6164
  }
6037
6165
  });
6038
6166
 
6039
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/flags/local_flags.js
6167
+ // ../../node_modules/.pnpm/json-logic-js@2.0.5/node_modules/json-logic-js/logic.js
6168
+ var require_logic = __commonJS({
6169
+ "../../node_modules/.pnpm/json-logic-js@2.0.5/node_modules/json-logic-js/logic.js"(exports$1, module) {
6170
+ (function(root, factory) {
6171
+ if (typeof define === "function" && define.amd) {
6172
+ define(factory);
6173
+ } else if (typeof exports$1 === "object") {
6174
+ module.exports = factory();
6175
+ } else {
6176
+ root.jsonLogic = factory();
6177
+ }
6178
+ })(exports$1, function() {
6179
+ if (!Array.isArray) {
6180
+ Array.isArray = function(arg) {
6181
+ return Object.prototype.toString.call(arg) === "[object Array]";
6182
+ };
6183
+ }
6184
+ function arrayUnique(array) {
6185
+ var a = [];
6186
+ for (var i = 0, l = array.length; i < l; i++) {
6187
+ if (a.indexOf(array[i]) === -1) {
6188
+ a.push(array[i]);
6189
+ }
6190
+ }
6191
+ return a;
6192
+ }
6193
+ var jsonLogic = {};
6194
+ var operations = {
6195
+ "==": function(a, b) {
6196
+ return a == b;
6197
+ },
6198
+ "===": function(a, b) {
6199
+ return a === b;
6200
+ },
6201
+ "!=": function(a, b) {
6202
+ return a != b;
6203
+ },
6204
+ "!==": function(a, b) {
6205
+ return a !== b;
6206
+ },
6207
+ ">": function(a, b) {
6208
+ return a > b;
6209
+ },
6210
+ ">=": function(a, b) {
6211
+ return a >= b;
6212
+ },
6213
+ "<": function(a, b, c) {
6214
+ return c === void 0 ? a < b : a < b && b < c;
6215
+ },
6216
+ "<=": function(a, b, c) {
6217
+ return c === void 0 ? a <= b : a <= b && b <= c;
6218
+ },
6219
+ "!!": function(a) {
6220
+ return jsonLogic.truthy(a);
6221
+ },
6222
+ "!": function(a) {
6223
+ return !jsonLogic.truthy(a);
6224
+ },
6225
+ "%": function(a, b) {
6226
+ return a % b;
6227
+ },
6228
+ "log": function(a) {
6229
+ console.log(a);
6230
+ return a;
6231
+ },
6232
+ "in": function(a, b) {
6233
+ if (!b || typeof b.indexOf === "undefined") return false;
6234
+ return b.indexOf(a) !== -1;
6235
+ },
6236
+ "cat": function() {
6237
+ return Array.prototype.join.call(arguments, "");
6238
+ },
6239
+ "substr": function(source, start, end) {
6240
+ if (end < 0) {
6241
+ var temp = String(source).substr(start);
6242
+ return temp.substr(0, temp.length + end);
6243
+ }
6244
+ return String(source).substr(start, end);
6245
+ },
6246
+ "+": function() {
6247
+ return Array.prototype.reduce.call(arguments, function(a, b) {
6248
+ return parseFloat(a, 10) + parseFloat(b, 10);
6249
+ }, 0);
6250
+ },
6251
+ "*": function() {
6252
+ return Array.prototype.reduce.call(arguments, function(a, b) {
6253
+ return parseFloat(a, 10) * parseFloat(b, 10);
6254
+ });
6255
+ },
6256
+ "-": function(a, b) {
6257
+ if (b === void 0) {
6258
+ return -a;
6259
+ } else {
6260
+ return a - b;
6261
+ }
6262
+ },
6263
+ "/": function(a, b) {
6264
+ return a / b;
6265
+ },
6266
+ "min": function() {
6267
+ return Math.min.apply(this, arguments);
6268
+ },
6269
+ "max": function() {
6270
+ return Math.max.apply(this, arguments);
6271
+ },
6272
+ "merge": function() {
6273
+ return Array.prototype.reduce.call(arguments, function(a, b) {
6274
+ return a.concat(b);
6275
+ }, []);
6276
+ },
6277
+ "var": function(a, b) {
6278
+ var not_found = b === void 0 ? null : b;
6279
+ var data = this;
6280
+ if (typeof a === "undefined" || a === "" || a === null) {
6281
+ return data;
6282
+ }
6283
+ var sub_props = String(a).split(".");
6284
+ for (var i = 0; i < sub_props.length; i++) {
6285
+ if (data === null || data === void 0) {
6286
+ return not_found;
6287
+ }
6288
+ data = data[sub_props[i]];
6289
+ if (data === void 0) {
6290
+ return not_found;
6291
+ }
6292
+ }
6293
+ return data;
6294
+ },
6295
+ "missing": function() {
6296
+ var missing = [];
6297
+ var keys = Array.isArray(arguments[0]) ? arguments[0] : arguments;
6298
+ for (var i = 0; i < keys.length; i++) {
6299
+ var key = keys[i];
6300
+ var value = jsonLogic.apply({ "var": key }, this);
6301
+ if (value === null || value === "") {
6302
+ missing.push(key);
6303
+ }
6304
+ }
6305
+ return missing;
6306
+ },
6307
+ "missing_some": function(need_count, options) {
6308
+ var are_missing = jsonLogic.apply({ "missing": options }, this);
6309
+ if (options.length - are_missing.length >= need_count) {
6310
+ return [];
6311
+ } else {
6312
+ return are_missing;
6313
+ }
6314
+ }
6315
+ };
6316
+ jsonLogic.is_logic = function(logic) {
6317
+ return typeof logic === "object" && // An object
6318
+ logic !== null && // but not null
6319
+ !Array.isArray(logic) && // and not an array
6320
+ Object.keys(logic).length === 1;
6321
+ };
6322
+ jsonLogic.truthy = function(value) {
6323
+ if (Array.isArray(value) && value.length === 0) {
6324
+ return false;
6325
+ }
6326
+ return !!value;
6327
+ };
6328
+ jsonLogic.get_operator = function(logic) {
6329
+ return Object.keys(logic)[0];
6330
+ };
6331
+ jsonLogic.get_values = function(logic) {
6332
+ return logic[jsonLogic.get_operator(logic)];
6333
+ };
6334
+ jsonLogic.apply = function(logic, data) {
6335
+ if (Array.isArray(logic)) {
6336
+ return logic.map(function(l) {
6337
+ return jsonLogic.apply(l, data);
6338
+ });
6339
+ }
6340
+ if (!jsonLogic.is_logic(logic)) {
6341
+ return logic;
6342
+ }
6343
+ var op = jsonLogic.get_operator(logic);
6344
+ var values = logic[op];
6345
+ var i;
6346
+ var current;
6347
+ var scopedLogic;
6348
+ var scopedData;
6349
+ var initial;
6350
+ if (!Array.isArray(values)) {
6351
+ values = [values];
6352
+ }
6353
+ if (op === "if" || op == "?:") {
6354
+ for (i = 0; i < values.length - 1; i += 2) {
6355
+ if (jsonLogic.truthy(jsonLogic.apply(values[i], data))) {
6356
+ return jsonLogic.apply(values[i + 1], data);
6357
+ }
6358
+ }
6359
+ if (values.length === i + 1) {
6360
+ return jsonLogic.apply(values[i], data);
6361
+ }
6362
+ return null;
6363
+ } else if (op === "and") {
6364
+ for (i = 0; i < values.length; i += 1) {
6365
+ current = jsonLogic.apply(values[i], data);
6366
+ if (!jsonLogic.truthy(current)) {
6367
+ return current;
6368
+ }
6369
+ }
6370
+ return current;
6371
+ } else if (op === "or") {
6372
+ for (i = 0; i < values.length; i += 1) {
6373
+ current = jsonLogic.apply(values[i], data);
6374
+ if (jsonLogic.truthy(current)) {
6375
+ return current;
6376
+ }
6377
+ }
6378
+ return current;
6379
+ } else if (op === "filter") {
6380
+ scopedData = jsonLogic.apply(values[0], data);
6381
+ scopedLogic = values[1];
6382
+ if (!Array.isArray(scopedData)) {
6383
+ return [];
6384
+ }
6385
+ return scopedData.filter(function(datum) {
6386
+ return jsonLogic.truthy(jsonLogic.apply(scopedLogic, datum));
6387
+ });
6388
+ } else if (op === "map") {
6389
+ scopedData = jsonLogic.apply(values[0], data);
6390
+ scopedLogic = values[1];
6391
+ if (!Array.isArray(scopedData)) {
6392
+ return [];
6393
+ }
6394
+ return scopedData.map(function(datum) {
6395
+ return jsonLogic.apply(scopedLogic, datum);
6396
+ });
6397
+ } else if (op === "reduce") {
6398
+ scopedData = jsonLogic.apply(values[0], data);
6399
+ scopedLogic = values[1];
6400
+ initial = typeof values[2] !== "undefined" ? jsonLogic.apply(values[2], data) : null;
6401
+ if (!Array.isArray(scopedData)) {
6402
+ return initial;
6403
+ }
6404
+ return scopedData.reduce(
6405
+ function(accumulator, current2) {
6406
+ return jsonLogic.apply(
6407
+ scopedLogic,
6408
+ { current: current2, accumulator }
6409
+ );
6410
+ },
6411
+ initial
6412
+ );
6413
+ } else if (op === "all") {
6414
+ scopedData = jsonLogic.apply(values[0], data);
6415
+ scopedLogic = values[1];
6416
+ if (!Array.isArray(scopedData) || !scopedData.length) {
6417
+ return false;
6418
+ }
6419
+ for (i = 0; i < scopedData.length; i += 1) {
6420
+ if (!jsonLogic.truthy(jsonLogic.apply(scopedLogic, scopedData[i]))) {
6421
+ return false;
6422
+ }
6423
+ }
6424
+ return true;
6425
+ } else if (op === "none") {
6426
+ scopedData = jsonLogic.apply(values[0], data);
6427
+ scopedLogic = values[1];
6428
+ if (!Array.isArray(scopedData) || !scopedData.length) {
6429
+ return true;
6430
+ }
6431
+ for (i = 0; i < scopedData.length; i += 1) {
6432
+ if (jsonLogic.truthy(jsonLogic.apply(scopedLogic, scopedData[i]))) {
6433
+ return false;
6434
+ }
6435
+ }
6436
+ return true;
6437
+ } else if (op === "some") {
6438
+ scopedData = jsonLogic.apply(values[0], data);
6439
+ scopedLogic = values[1];
6440
+ if (!Array.isArray(scopedData) || !scopedData.length) {
6441
+ return false;
6442
+ }
6443
+ for (i = 0; i < scopedData.length; i += 1) {
6444
+ if (jsonLogic.truthy(jsonLogic.apply(scopedLogic, scopedData[i]))) {
6445
+ return true;
6446
+ }
6447
+ }
6448
+ return false;
6449
+ }
6450
+ values = values.map(function(val) {
6451
+ return jsonLogic.apply(val, data);
6452
+ });
6453
+ if (operations.hasOwnProperty(op) && typeof operations[op] === "function") {
6454
+ return operations[op].apply(data, values);
6455
+ } else if (op.indexOf(".") > 0) {
6456
+ var sub_ops = String(op).split(".");
6457
+ var operation = operations;
6458
+ for (i = 0; i < sub_ops.length; i++) {
6459
+ if (!operation.hasOwnProperty(sub_ops[i])) {
6460
+ throw new Error("Unrecognized operation " + op + " (failed at " + sub_ops.slice(0, i + 1).join(".") + ")");
6461
+ }
6462
+ operation = operation[sub_ops[i]];
6463
+ }
6464
+ return operation.apply(data, values);
6465
+ }
6466
+ throw new Error("Unrecognized operation " + op);
6467
+ };
6468
+ jsonLogic.uses_data = function(logic) {
6469
+ var collection = [];
6470
+ if (jsonLogic.is_logic(logic)) {
6471
+ var op = jsonLogic.get_operator(logic);
6472
+ var values = logic[op];
6473
+ if (!Array.isArray(values)) {
6474
+ values = [values];
6475
+ }
6476
+ if (op === "var") {
6477
+ collection.push(values[0]);
6478
+ } else {
6479
+ values.forEach(function(val) {
6480
+ collection.push.apply(collection, jsonLogic.uses_data(val));
6481
+ });
6482
+ }
6483
+ }
6484
+ return arrayUnique(collection);
6485
+ };
6486
+ jsonLogic.add_operation = function(name, code) {
6487
+ operations[name] = code;
6488
+ };
6489
+ jsonLogic.rm_operation = function(name) {
6490
+ delete operations[name];
6491
+ };
6492
+ jsonLogic.rule_like = function(rule, pattern) {
6493
+ if (pattern === rule) {
6494
+ return true;
6495
+ }
6496
+ if (pattern === "@") {
6497
+ return true;
6498
+ }
6499
+ if (pattern === "number") {
6500
+ return typeof rule === "number";
6501
+ }
6502
+ if (pattern === "string") {
6503
+ return typeof rule === "string";
6504
+ }
6505
+ if (pattern === "array") {
6506
+ return Array.isArray(rule) && !jsonLogic.is_logic(rule);
6507
+ }
6508
+ if (jsonLogic.is_logic(pattern)) {
6509
+ if (jsonLogic.is_logic(rule)) {
6510
+ var pattern_op = jsonLogic.get_operator(pattern);
6511
+ var rule_op = jsonLogic.get_operator(rule);
6512
+ if (pattern_op === "@" || pattern_op === rule_op) {
6513
+ return jsonLogic.rule_like(
6514
+ jsonLogic.get_values(rule, false),
6515
+ jsonLogic.get_values(pattern, false)
6516
+ );
6517
+ }
6518
+ }
6519
+ return false;
6520
+ }
6521
+ if (Array.isArray(pattern)) {
6522
+ if (Array.isArray(rule)) {
6523
+ if (pattern.length !== rule.length) {
6524
+ return false;
6525
+ }
6526
+ for (var i = 0; i < pattern.length; i += 1) {
6527
+ if (!jsonLogic.rule_like(rule[i], pattern[i])) {
6528
+ return false;
6529
+ }
6530
+ }
6531
+ return true;
6532
+ } else {
6533
+ return false;
6534
+ }
6535
+ }
6536
+ return false;
6537
+ };
6538
+ return jsonLogic;
6539
+ });
6540
+ }
6541
+ });
6542
+
6543
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/flags/local_flags.js
6040
6544
  var require_local_flags = __commonJS({
6041
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/flags/local_flags.js"(exports$1, module) {
6545
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/flags/local_flags.js"(exports$1, module) {
6042
6546
  var FeatureFlagsProvider = require_flags();
6043
- var { normalizedHash } = require_utils2();
6547
+ var {
6548
+ normalizedHash,
6549
+ lowercaseAllKeysAndValues,
6550
+ lowercaseLeafNodes
6551
+ } = require_utils2();
6552
+ var { apply } = require_logic();
6044
6553
  var LocalFeatureFlagsProvider = class extends FeatureFlagsProvider {
6045
6554
  /**
6046
6555
  * @param {string} token - Mixpanel project token
@@ -6079,12 +6588,16 @@ var require_local_flags = __commonJS({
6079
6588
  try {
6080
6589
  await this._fetchFlagDefinitions();
6081
6590
  } catch (err) {
6082
- this.logger?.error(`Error polling for flag definition: ${err.message}`);
6591
+ this.logger?.error(
6592
+ `Error polling for flag definition: ${err.message}`
6593
+ );
6083
6594
  }
6084
6595
  }, this.config.polling_interval_in_seconds * 1e3);
6085
6596
  }
6086
6597
  } catch (err) {
6087
- this.logger?.error(`Initial flag definitions fetch failed: ${err.message}`);
6598
+ this.logger?.error(
6599
+ `Initial flag definitions fetch failed: ${err.message}`
6600
+ );
6088
6601
  }
6089
6602
  }
6090
6603
  /**
@@ -6095,7 +6608,9 @@ var require_local_flags = __commonJS({
6095
6608
  clearInterval(this.pollingInterval);
6096
6609
  this.pollingInterval = null;
6097
6610
  } else {
6098
- this.logger?.warn("stopPollingForDefinitions called but polling was not active");
6611
+ this.logger?.warn(
6612
+ "stopPollingForDefinitions called but polling was not active"
6613
+ );
6099
6614
  }
6100
6615
  }
6101
6616
  /**
@@ -6120,7 +6635,12 @@ var require_local_flags = __commonJS({
6120
6635
  * @returns {*} The variant value
6121
6636
  */
6122
6637
  getVariantValue(flagKey, fallbackValue, context, reportExposure = true) {
6123
- const result = this.getVariant(flagKey, { variant_value: fallbackValue }, context, reportExposure);
6638
+ const result = this.getVariant(
6639
+ flagKey,
6640
+ { variant_value: fallbackValue },
6641
+ context,
6642
+ reportExposure
6643
+ );
6124
6644
  return result.variant_value;
6125
6645
  }
6126
6646
  /**
@@ -6151,7 +6671,12 @@ var require_local_flags = __commonJS({
6151
6671
  } else {
6152
6672
  const rollout = this._getAssignedRollout(flag, contextValue, context);
6153
6673
  if (rollout) {
6154
- selectedVariant = this._getAssignedVariant(flag, contextValue, flagKey, rollout);
6674
+ selectedVariant = this._getAssignedVariant(
6675
+ flag,
6676
+ contextValue,
6677
+ flagKey,
6678
+ rollout
6679
+ );
6155
6680
  }
6156
6681
  }
6157
6682
  if (selectedVariant) {
@@ -6246,7 +6771,10 @@ var require_local_flags = __commonJS({
6246
6771
  }
6247
6772
  _getAssignedVariant(flag, contextValue, flagKey, rollout) {
6248
6773
  if (rollout.variant_override) {
6249
- const variant = this._getMatchingVariant(rollout.variant_override.key, flag);
6774
+ const variant = this._getMatchingVariant(
6775
+ rollout.variant_override.key,
6776
+ flag
6777
+ );
6250
6778
  if (variant) {
6251
6779
  return { ...variant, is_qa_tester: false };
6252
6780
  }
@@ -6279,15 +6807,41 @@ var require_local_flags = __commonJS({
6279
6807
  is_qa_tester: false
6280
6808
  };
6281
6809
  }
6810
+ _extractRuntimeParameters(context) {
6811
+ const customProperties = context.custom_properties;
6812
+ if (!customProperties || typeof customProperties !== "object") {
6813
+ return null;
6814
+ }
6815
+ return lowercaseAllKeysAndValues(customProperties);
6816
+ }
6817
+ _isRuntimeRuleSatisfied(rollout, context) {
6818
+ try {
6819
+ return apply(
6820
+ lowercaseLeafNodes(rollout.runtime_evaluation_rule),
6821
+ this._extractRuntimeParameters(context)
6822
+ );
6823
+ } catch (error) {
6824
+ this.logger?.error(`Error evaluating runtime rule: ${error.message}`);
6825
+ return false;
6826
+ }
6827
+ }
6282
6828
  _isRuntimeEvaluationSatisfied(rollout, context) {
6283
- if (!rollout.runtime_evaluation_definition) {
6829
+ if (rollout.runtime_evaluation_rule) {
6830
+ return this._isRuntimeRuleSatisfied(rollout, context);
6831
+ } else if (rollout.runtime_evaluation_definition) {
6832
+ return this._isLegacyRuntimeEvaluationSatisfied(rollout, context);
6833
+ } else {
6284
6834
  return true;
6285
6835
  }
6286
- const customProperties = context.custom_properties;
6287
- if (!customProperties || typeof customProperties !== "object") {
6836
+ }
6837
+ _isLegacyRuntimeEvaluationSatisfied(rollout, context) {
6838
+ const customProperties = this._extractRuntimeParameters(context);
6839
+ if (!customProperties) {
6288
6840
  return false;
6289
6841
  }
6290
- for (const [key, expectedValue] of Object.entries(rollout.runtime_evaluation_definition)) {
6842
+ for (const [key, expectedValue] of Object.entries(
6843
+ rollout.runtime_evaluation_definition
6844
+ )) {
6291
6845
  if (!(key in customProperties)) {
6292
6846
  return false;
6293
6847
  }
@@ -6303,9 +6857,9 @@ var require_local_flags = __commonJS({
6303
6857
  }
6304
6858
  });
6305
6859
 
6306
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/flags/remote_flags.js
6860
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/flags/remote_flags.js
6307
6861
  var require_remote_flags = __commonJS({
6308
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/flags/remote_flags.js"(exports$1, module) {
6862
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/flags/remote_flags.js"(exports$1, module) {
6309
6863
  var FeatureFlagsProvider = require_flags();
6310
6864
  var RemoteFeatureFlagsProvider = class extends FeatureFlagsProvider {
6311
6865
  /**
@@ -6339,10 +6893,17 @@ var require_remote_flags = __commonJS({
6339
6893
  */
6340
6894
  async getVariantValue(flagKey, fallbackValue, context, reportExposure = true) {
6341
6895
  try {
6342
- const selectedVariant = await this.getVariant(flagKey, { variant_value: fallbackValue }, context, reportExposure);
6896
+ const selectedVariant = await this.getVariant(
6897
+ flagKey,
6898
+ { variant_value: fallbackValue },
6899
+ context,
6900
+ reportExposure
6901
+ );
6343
6902
  return selectedVariant.variant_value;
6344
6903
  } catch (err) {
6345
- this.logger?.error(`Failed to get variant value for flag '${flagKey}': ${err.message}`);
6904
+ this.logger?.error(
6905
+ `Failed to get variant value for flag '${flagKey}': ${err.message}`
6906
+ );
6346
6907
  return fallbackValue;
6347
6908
  }
6348
6909
  }
@@ -6371,7 +6932,9 @@ var require_remote_flags = __commonJS({
6371
6932
  }
6372
6933
  return selectedVariant;
6373
6934
  } catch (err) {
6374
- this.logger?.error(`Failed to get variant for flag '${flagKey}': ${err.message}`);
6935
+ this.logger?.error(
6936
+ `Failed to get variant for flag '${flagKey}': ${err.message}`
6937
+ );
6375
6938
  return fallbackVariant;
6376
6939
  }
6377
6940
  }
@@ -6388,7 +6951,9 @@ var require_remote_flags = __commonJS({
6388
6951
  const value = await this.getVariantValue(flagKey, false, context);
6389
6952
  return value === true;
6390
6953
  } catch (err) {
6391
- this.logger?.error(`Failed to check if flag '${flagKey}' is enabled: ${err.message}`);
6954
+ this.logger?.error(
6955
+ `Failed to check if flag '${flagKey}' is enabled: ${err.message}`
6956
+ );
6392
6957
  return false;
6393
6958
  }
6394
6959
  }
@@ -6427,9 +6992,9 @@ var require_remote_flags = __commonJS({
6427
6992
  }
6428
6993
  });
6429
6994
 
6430
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/flags/index.js
6995
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/flags/index.js
6431
6996
  var require_flags2 = __commonJS({
6432
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/flags/index.js"(exports$1, module) {
6997
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/flags/index.js"(exports$1, module) {
6433
6998
  var LocalFeatureFlagsProvider = require_local_flags();
6434
6999
  var RemoteFeatureFlagsProvider = require_remote_flags();
6435
7000
  module.exports = {
@@ -6439,9 +7004,9 @@ var require_flags2 = __commonJS({
6439
7004
  }
6440
7005
  });
6441
7006
 
6442
- // ../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/mixpanel-node.js
7007
+ // ../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/mixpanel-node.js
6443
7008
  var require_mixpanel_node = __commonJS({
6444
- "../../node_modules/.pnpm/mixpanel@0.19.1/node_modules/mixpanel/lib/mixpanel-node.js"(exports$1, module) {
7009
+ "../../node_modules/.pnpm/mixpanel@0.20.0/node_modules/mixpanel/lib/mixpanel-node.js"(exports$1, module) {
6445
7010
  var querystring = __require("querystring");
6446
7011
  var Buffer4 = __require("buffer").Buffer;
6447
7012
  var http3 = __require("http");
@@ -6452,7 +7017,10 @@ var require_mixpanel_node = __commonJS({
6452
7017
  var { async_all, ensure_timestamp, assert_logger } = require_utils();
6453
7018
  var { MixpanelGroups } = require_groups();
6454
7019
  var { MixpanelPeople } = require_people();
6455
- var { LocalFeatureFlagsProvider, RemoteFeatureFlagsProvider } = require_flags2();
7020
+ var {
7021
+ LocalFeatureFlagsProvider,
7022
+ RemoteFeatureFlagsProvider
7023
+ } = require_flags2();
6456
7024
  var DEFAULT_CONFIG = {
6457
7025
  test: false,
6458
7026
  debug: false,
@@ -6468,7 +7036,9 @@ var require_mixpanel_node = __commonJS({
6468
7036
  };
6469
7037
  var create_client = function(token, config) {
6470
7038
  if (!token) {
6471
- throw new Error("The Mixpanel Client needs a Mixpanel token: `init(token)`");
7039
+ throw new Error(
7040
+ "The Mixpanel Client needs a Mixpanel token: `init(token)`"
7041
+ );
6472
7042
  }
6473
7043
  const metrics = {
6474
7044
  token,
@@ -6482,9 +7052,11 @@ var require_mixpanel_node = __commonJS({
6482
7052
  https: new https3.Agent({ keepAlive })
6483
7053
  };
6484
7054
  const proxyPath = process.env.HTTPS_PROXY || process.env.HTTP_PROXY;
6485
- const proxyAgent = proxyPath ? new HttpsProxyAgent(Object.assign(url.parse(proxyPath), {
6486
- keepAlive
6487
- })) : null;
7055
+ const proxyAgent = proxyPath ? new HttpsProxyAgent(
7056
+ Object.assign(url.parse(proxyPath), {
7057
+ keepAlive
7058
+ })
7059
+ ) : null;
6488
7060
  metrics.send_request = function(options, callback) {
6489
7061
  callback = callback || function() {
6490
7062
  };
@@ -6492,8 +7064,8 @@ var require_mixpanel_node = __commonJS({
6492
7064
  const endpoint = options.endpoint;
6493
7065
  const method = (options.method || "GET").toUpperCase();
6494
7066
  let query_params = {
6495
- "ip": metrics.config.geolocate ? 1 : 0,
6496
- "verbose": metrics.config.verbose ? 1 : 0
7067
+ ip: metrics.config.geolocate ? 1 : 0,
7068
+ verbose: metrics.config.verbose ? 1 : 0
6497
7069
  };
6498
7070
  const key = metrics.config.key;
6499
7071
  const secret = metrics.config.secret;
@@ -6526,7 +7098,9 @@ var require_mixpanel_node = __commonJS({
6526
7098
  } else if (key) {
6527
7099
  query_params.api_key = key;
6528
7100
  } else if (endpoint === "/import") {
6529
- throw new Error("The Mixpanel Client needs a Mixpanel API Secret when importing old events: `init(token, { secret: ... })`");
7101
+ throw new Error(
7102
+ "The Mixpanel Client needs a Mixpanel API Secret when importing old events: `init(token, { secret: ... })`"
7103
+ );
6530
7104
  }
6531
7105
  request_options.agent = proxyAgent || REQUEST_AGENTS[metrics.config.protocol];
6532
7106
  if (metrics.config.test) {
@@ -6534,20 +7108,22 @@ var require_mixpanel_node = __commonJS({
6534
7108
  }
6535
7109
  request_options.path = metrics.config.path + endpoint + "?" + querystring.stringify(query_params);
6536
7110
  request = request_lib.request(request_options, function(res) {
6537
- var data = "";
7111
+ let data = "";
6538
7112
  res.on("data", function(chunk3) {
6539
7113
  data += chunk3;
6540
7114
  });
6541
7115
  res.on("end", function() {
6542
- var e;
7116
+ let e;
6543
7117
  if (metrics.config.verbose) {
6544
7118
  try {
6545
- var result = JSON.parse(data);
7119
+ const result = JSON.parse(data);
6546
7120
  if (result.status != 1) {
6547
7121
  e = new Error("Mixpanel Server Error: " + result.error);
6548
7122
  }
6549
7123
  } catch (ex) {
6550
- e = new Error("Could not parse response from Mixpanel");
7124
+ e = new Error(
7125
+ "Could not parse response from Mixpanel " + ex.message
7126
+ );
6551
7127
  }
6552
7128
  } else {
6553
7129
  e = data !== "1" ? new Error("Mixpanel Server Error: " + data) : void 0;
@@ -6570,39 +7146,46 @@ var require_mixpanel_node = __commonJS({
6570
7146
  properties.token = metrics.token;
6571
7147
  properties.mp_lib = "node";
6572
7148
  properties.$lib_version = packageInfo.version;
6573
- var data = {
7149
+ const data = {
6574
7150
  event,
6575
7151
  properties
6576
7152
  };
6577
7153
  if (metrics.config.debug) {
6578
- metrics.config.logger.debug("Sending the following event to Mixpanel", { data });
7154
+ metrics.config.logger.debug("Sending the following event to Mixpanel", {
7155
+ data
7156
+ });
6579
7157
  }
6580
- metrics.send_request({ method: "GET", endpoint, data }, callback);
7158
+ metrics.send_request(
7159
+ { method: "GET", endpoint, data },
7160
+ callback
7161
+ );
6581
7162
  };
6582
- var chunk2 = function(arr, size) {
6583
- var chunks = [], i = 0, total = arr.length;
7163
+ const chunk2 = function(arr, size) {
7164
+ let chunks = [], i = 0, total = arr.length;
6584
7165
  while (i < total) {
6585
7166
  chunks.push(arr.slice(i, i += size));
6586
7167
  }
6587
7168
  return chunks;
6588
7169
  };
6589
- var send_batch_requests = function(options, callback) {
6590
- var event_list = options.event_list, endpoint = options.endpoint, max_batch_size = options.max_batch_size ? Math.min(MAX_BATCH_SIZE, options.max_batch_size) : MAX_BATCH_SIZE, max_concurrent_requests = options.max_concurrent_requests || options.max_batch_size > MAX_BATCH_SIZE && Math.ceil(options.max_batch_size / MAX_BATCH_SIZE), event_batches = chunk2(event_list, max_batch_size), request_batches = max_concurrent_requests ? chunk2(event_batches, max_concurrent_requests) : [event_batches], total_event_batches = event_batches.length, total_request_batches = request_batches.length;
7170
+ const send_batch_requests = function(options, callback) {
7171
+ const event_list = options.event_list, endpoint = options.endpoint, max_batch_size = options.max_batch_size ? Math.min(MAX_BATCH_SIZE, options.max_batch_size) : MAX_BATCH_SIZE, max_concurrent_requests = options.max_concurrent_requests || options.max_batch_size > MAX_BATCH_SIZE && Math.ceil(options.max_batch_size / MAX_BATCH_SIZE), event_batches = chunk2(event_list, max_batch_size), request_batches = max_concurrent_requests ? chunk2(event_batches, max_concurrent_requests) : [event_batches], total_event_batches = event_batches.length, total_request_batches = request_batches.length;
6591
7172
  function send_event_batch(batch, cb) {
6592
7173
  if (batch.length > 0) {
6593
7174
  batch = batch.map(function(event) {
6594
- event.properties;
6595
7175
  if (endpoint === "/import" || event.properties.time) {
6596
7176
  event.properties.time = ensure_timestamp(event.properties.time);
6597
7177
  }
6598
7178
  event.properties.token = event.properties.token || metrics.token;
6599
7179
  return event;
6600
7180
  });
6601
- metrics.send_request({ method: "POST", endpoint, data: batch }, cb);
7181
+ metrics.send_request(
7182
+ { method: "POST", endpoint, data: batch },
7183
+ cb
7184
+ );
6602
7185
  }
6603
7186
  }
6604
7187
  function send_next_request_batch(index) {
6605
- var request_batch = request_batches[index], cb = function(errors, results) {
7188
+ const request_batch = request_batches[index], cb = function(errors, results) {
6606
7189
  index += 1;
6607
7190
  if (index === total_request_batches) {
6608
7191
  callback && callback(errors, results);
@@ -6635,7 +7218,7 @@ var require_mixpanel_node = __commonJS({
6635
7218
  callback = options;
6636
7219
  options = {};
6637
7220
  }
6638
- var batch_options = {
7221
+ const batch_options = {
6639
7222
  event_list,
6640
7223
  endpoint: "/track",
6641
7224
  max_concurrent_requests: options.max_concurrent_requests,
@@ -6652,7 +7235,7 @@ var require_mixpanel_node = __commonJS({
6652
7235
  metrics.send_event_request("/import", event, properties, callback);
6653
7236
  };
6654
7237
  metrics.import_batch = function(event_list, options, callback) {
6655
- var batch_options;
7238
+ let batch_options;
6656
7239
  if (typeof options === "function" || !options) {
6657
7240
  callback = options;
6658
7241
  options = {};
@@ -6666,7 +7249,7 @@ var require_mixpanel_node = __commonJS({
6666
7249
  send_batch_requests(batch_options, callback);
6667
7250
  };
6668
7251
  metrics.alias = function(distinct_id, alias, callback) {
6669
- var properties = {
7252
+ const properties = {
6670
7253
  distinct_id,
6671
7254
  alias
6672
7255
  };
@@ -6892,10 +7475,10 @@ var init_tslib_es6 = __esm({
6892
7475
  }
6893
7476
  });
6894
7477
 
6895
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/event/event.js
7478
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/event/event.js
6896
7479
  var IdentifyOperation, SpecialEventType;
6897
7480
  var init_event = __esm({
6898
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/event/event.js"() {
7481
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/event/event.js"() {
6899
7482
  (function(IdentifyOperation3) {
6900
7483
  IdentifyOperation3["SET"] = "$set";
6901
7484
  IdentifyOperation3["SET_ONCE"] = "$setOnce";
@@ -6916,10 +7499,10 @@ var init_event = __esm({
6916
7499
  }
6917
7500
  });
6918
7501
 
6919
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/constants.js
7502
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/constants.js
6920
7503
  var UNSET_VALUE, AMPLITUDE_PREFIX, STORAGE_PREFIX, DEFAULT_INSTANCE_NAME, AMPLITUDE_SERVER_URL, EU_AMPLITUDE_SERVER_URL, AMPLITUDE_BATCH_SERVER_URL, EU_AMPLITUDE_BATCH_SERVER_URL;
6921
7504
  var init_constants = __esm({
6922
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/constants.js"() {
7505
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/constants.js"() {
6923
7506
  UNSET_VALUE = "-";
6924
7507
  AMPLITUDE_PREFIX = "AMP";
6925
7508
  STORAGE_PREFIX = "".concat(AMPLITUDE_PREFIX, "_unsent");
@@ -6931,10 +7514,10 @@ var init_constants = __esm({
6931
7514
  }
6932
7515
  });
6933
7516
 
6934
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/valid-properties.js
7517
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/valid-properties.js
6935
7518
  var MAX_PROPERTY_KEYS, isValidObject, isValidProperties;
6936
7519
  var init_valid_properties = __esm({
6937
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/valid-properties.js"() {
7520
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/valid-properties.js"() {
6938
7521
  init_tslib_es6();
6939
7522
  MAX_PROPERTY_KEYS = 1e3;
6940
7523
  isValidObject = function(properties) {
@@ -6989,10 +7572,10 @@ var init_valid_properties = __esm({
6989
7572
  }
6990
7573
  });
6991
7574
 
6992
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/identify.js
7575
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/identify.js
6993
7576
  var Identify, IdentifyOperation2, OrderedIdentifyOperations;
6994
7577
  var init_identify = __esm({
6995
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/identify.js"() {
7578
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/identify.js"() {
6996
7579
  init_tslib_es6();
6997
7580
  init_constants();
6998
7581
  init_valid_properties();
@@ -7103,10 +7686,10 @@ var init_identify = __esm({
7103
7686
  }
7104
7687
  });
7105
7688
 
7106
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/messages.js
7689
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/messages.js
7107
7690
  var SUCCESS_MESSAGE, UNEXPECTED_ERROR_MESSAGE, MAX_RETRIES_EXCEEDED_MESSAGE, OPT_OUT_MESSAGE, MISSING_API_KEY_MESSAGE, INVALID_API_KEY, CLIENT_NOT_INITIALIZED;
7108
7691
  var init_messages = __esm({
7109
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/messages.js"() {
7692
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/messages.js"() {
7110
7693
  SUCCESS_MESSAGE = "Event tracked successfully";
7111
7694
  UNEXPECTED_ERROR_MESSAGE = "Unexpected error occurred";
7112
7695
  MAX_RETRIES_EXCEEDED_MESSAGE = "Event rejected due to exceeded retry count";
@@ -7117,10 +7700,10 @@ var init_messages = __esm({
7117
7700
  }
7118
7701
  });
7119
7702
 
7120
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/status.js
7703
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/status.js
7121
7704
  var Status;
7122
7705
  var init_status = __esm({
7123
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/status.js"() {
7706
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/status.js"() {
7124
7707
  (function(Status2) {
7125
7708
  Status2["Unknown"] = "unknown";
7126
7709
  Status2["Skipped"] = "skipped";
@@ -7135,10 +7718,10 @@ var init_status = __esm({
7135
7718
  }
7136
7719
  });
7137
7720
 
7138
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/result-builder.js
7721
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/result-builder.js
7139
7722
  var buildResult;
7140
7723
  var init_result_builder = __esm({
7141
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/result-builder.js"() {
7724
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/result-builder.js"() {
7142
7725
  init_status();
7143
7726
  buildResult = function(event, code, message2) {
7144
7727
  if (code === void 0) {
@@ -7152,10 +7735,10 @@ var init_result_builder = __esm({
7152
7735
  }
7153
7736
  });
7154
7737
 
7155
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/global-scope.js
7738
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/global-scope.js
7156
7739
  var getGlobalScope;
7157
7740
  var init_global_scope = __esm({
7158
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/global-scope.js"() {
7741
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/global-scope.js"() {
7159
7742
  getGlobalScope = function() {
7160
7743
  var ampIntegrationContextName = "ampIntegrationContext";
7161
7744
  if (typeof globalThis !== "undefined" && typeof globalThis[ampIntegrationContextName] !== "undefined") {
@@ -7178,10 +7761,10 @@ var init_global_scope = __esm({
7178
7761
  }
7179
7762
  });
7180
7763
 
7181
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/uuid.js
7764
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/uuid.js
7182
7765
  var legacyUUID, hex, UUID2;
7183
7766
  var init_uuid = __esm({
7184
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/uuid.js"() {
7767
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/uuid.js"() {
7185
7768
  init_tslib_es6();
7186
7769
  init_global_scope();
7187
7770
  legacyUUID = function(a) {
@@ -7225,10 +7808,10 @@ var init_uuid = __esm({
7225
7808
  }
7226
7809
  });
7227
7810
 
7228
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/timeline.js
7811
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/timeline.js
7229
7812
  var Timeline;
7230
7813
  var init_timeline = __esm({
7231
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/timeline.js"() {
7814
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/timeline.js"() {
7232
7815
  init_tslib_es6();
7233
7816
  init_result_builder();
7234
7817
  init_uuid();
@@ -7530,10 +8113,10 @@ var init_timeline = __esm({
7530
8113
  }
7531
8114
  });
7532
8115
 
7533
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/event-builder.js
8116
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/event-builder.js
7534
8117
  var createTrackEvent, createIdentifyEvent, createGroupIdentifyEvent, createGroupEvent, createRevenueEvent;
7535
8118
  var init_event_builder = __esm({
7536
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/event-builder.js"() {
8119
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/event-builder.js"() {
7537
8120
  init_tslib_es6();
7538
8121
  init_identify();
7539
8122
  init_event();
@@ -7563,10 +8146,10 @@ var init_event_builder = __esm({
7563
8146
  }
7564
8147
  });
7565
8148
 
7566
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/return-wrapper.js
8149
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/return-wrapper.js
7567
8150
  var returnWrapper;
7568
8151
  var init_return_wrapper = __esm({
7569
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/return-wrapper.js"() {
8152
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/return-wrapper.js"() {
7570
8153
  returnWrapper = function(awaitable) {
7571
8154
  return {
7572
8155
  promise: awaitable || Promise.resolve()
@@ -7575,10 +8158,10 @@ var init_return_wrapper = __esm({
7575
8158
  }
7576
8159
  });
7577
8160
 
7578
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/core-client.js
8161
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/core-client.js
7579
8162
  var AmplitudeCore;
7580
8163
  var init_core_client = __esm({
7581
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/core-client.js"() {
8164
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/core-client.js"() {
7582
8165
  init_tslib_es6();
7583
8166
  init_event();
7584
8167
  init_identify();
@@ -7846,10 +8429,10 @@ var init_core_client = __esm({
7846
8429
  }
7847
8430
  });
7848
8431
 
7849
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/revenue.js
8432
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/revenue.js
7850
8433
  var Revenue, RevenueProperty;
7851
8434
  var init_revenue = __esm({
7852
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/revenue.js"() {
8435
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/revenue.js"() {
7853
8436
  init_tslib_es6();
7854
8437
  init_valid_properties();
7855
8438
  Revenue = /** @class */
@@ -7926,10 +8509,10 @@ var init_revenue = __esm({
7926
8509
  }
7927
8510
  });
7928
8511
 
7929
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/chunk.js
8512
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/chunk.js
7930
8513
  var chunk;
7931
8514
  var init_chunk = __esm({
7932
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/chunk.js"() {
8515
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/chunk.js"() {
7933
8516
  chunk = function(arr, size) {
7934
8517
  var chunkSize = Math.max(size, 1);
7935
8518
  return arr.reduce(function(chunks, element, index) {
@@ -7944,10 +8527,10 @@ var init_chunk = __esm({
7944
8527
  }
7945
8528
  });
7946
8529
 
7947
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/loglevel.js
8530
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/loglevel.js
7948
8531
  var LogLevel;
7949
8532
  var init_loglevel = __esm({
7950
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/loglevel.js"() {
8533
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/loglevel.js"() {
7951
8534
  (function(LogLevel2) {
7952
8535
  LogLevel2[LogLevel2["None"] = 0] = "None";
7953
8536
  LogLevel2[LogLevel2["Error"] = 1] = "Error";
@@ -7958,10 +8541,10 @@ var init_loglevel = __esm({
7958
8541
  }
7959
8542
  });
7960
8543
 
7961
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/logger.js
8544
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/logger.js
7962
8545
  var PREFIX, Logger;
7963
8546
  var init_logger2 = __esm({
7964
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/logger.js"() {
8547
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/logger.js"() {
7965
8548
  init_loglevel();
7966
8549
  PREFIX = "Amplitude Logger ";
7967
8550
  Logger = /** @class */
@@ -8023,10 +8606,10 @@ var init_logger2 = __esm({
8023
8606
  }
8024
8607
  });
8025
8608
 
8026
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/config.js
8609
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/config.js
8027
8610
  var getDefaultConfig, Config, getServerUrl, createServerConfig, RequestMetadata;
8028
8611
  var init_config = __esm({
8029
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/config.js"() {
8612
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/config.js"() {
8030
8613
  init_constants();
8031
8614
  init_logger2();
8032
8615
  init_loglevel();
@@ -8127,19 +8710,19 @@ var init_config = __esm({
8127
8710
  }
8128
8711
  });
8129
8712
 
8130
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/status-code.js
8713
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/status-code.js
8131
8714
  function isSuccessStatusCode(code) {
8132
8715
  return code >= 200 && code < 300;
8133
8716
  }
8134
8717
  var init_status_code = __esm({
8135
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/status-code.js"() {
8718
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/status-code.js"() {
8136
8719
  }
8137
8720
  });
8138
8721
 
8139
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/debug.js
8722
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/debug.js
8140
8723
  var getStacktrace, getClientLogConfig, getValueByStringPath, getClientStates, debugWrapper;
8141
8724
  var init_debug = __esm({
8142
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/utils/debug.js"() {
8725
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/utils/debug.js"() {
8143
8726
  init_tslib_es6();
8144
8727
  init_loglevel();
8145
8728
  getStacktrace = function(ignoreDepth) {
@@ -8257,7 +8840,7 @@ var init_debug = __esm({
8257
8840
  }
8258
8841
  });
8259
8842
 
8260
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/plugins/destination.js
8843
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/plugins/destination.js
8261
8844
  function getErrorMessage(error) {
8262
8845
  if (error instanceof Error)
8263
8846
  return error.message;
@@ -8275,7 +8858,7 @@ function getResponseBodyString(res) {
8275
8858
  }
8276
8859
  var Destination;
8277
8860
  var init_destination = __esm({
8278
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/plugins/destination.js"() {
8861
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/plugins/destination.js"() {
8279
8862
  init_tslib_es6();
8280
8863
  init_status();
8281
8864
  init_messages();
@@ -8666,10 +9249,10 @@ var init_destination = __esm({
8666
9249
  }
8667
9250
  });
8668
9251
 
8669
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/transports/base.js
9252
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/transports/base.js
8670
9253
  var BaseTransport;
8671
9254
  var init_base2 = __esm({
8672
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/transports/base.js"() {
9255
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/transports/base.js"() {
8673
9256
  init_status();
8674
9257
  init_status_code();
8675
9258
  BaseTransport = /** @class */
@@ -8771,10 +9354,10 @@ var init_base2 = __esm({
8771
9354
  }
8772
9355
  });
8773
9356
 
8774
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/server-zone.js
9357
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/server-zone.js
8775
9358
  var ServerZone;
8776
9359
  var init_server_zone = __esm({
8777
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/server-zone.js"() {
9360
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/server-zone.js"() {
8778
9361
  (function(ServerZone2) {
8779
9362
  ServerZone2["US"] = "US";
8780
9363
  ServerZone2["EU"] = "EU";
@@ -8783,17 +9366,17 @@ var init_server_zone = __esm({
8783
9366
  }
8784
9367
  });
8785
9368
 
8786
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/offline.js
9369
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/offline.js
8787
9370
  var OfflineDisabled;
8788
9371
  var init_offline = __esm({
8789
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/types/offline.js"() {
9372
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/types/offline.js"() {
8790
9373
  OfflineDisabled = null;
8791
9374
  }
8792
9375
  });
8793
9376
 
8794
- // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/index.js
9377
+ // ../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/index.js
8795
9378
  var init_esm = __esm({
8796
- "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.0/node_modules/@amplitude/analytics-core/lib/esm/index.js"() {
9379
+ "../../node_modules/.pnpm/@amplitude+analytics-core@2.35.2/node_modules/@amplitude/analytics-core/lib/esm/index.js"() {
8797
9380
  init_core_client();
8798
9381
  init_identify();
8799
9382
  init_revenue();
@@ -8810,18 +9393,18 @@ var init_esm = __esm({
8810
9393
  }
8811
9394
  });
8812
9395
 
8813
- // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/version.js
9396
+ // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/version.js
8814
9397
  var VERSION;
8815
9398
  var init_version2 = __esm({
8816
- "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/version.js"() {
8817
- VERSION = "1.5.29";
9399
+ "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/version.js"() {
9400
+ VERSION = "1.5.31";
8818
9401
  }
8819
9402
  });
8820
9403
 
8821
- // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/plugins/context.js
9404
+ // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/plugins/context.js
8822
9405
  var Context;
8823
9406
  var init_context2 = __esm({
8824
- "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/plugins/context.js"() {
9407
+ "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/plugins/context.js"() {
8825
9408
  init_tslib_es6();
8826
9409
  init_esm();
8827
9410
  init_version2();
@@ -8856,7 +9439,7 @@ var init_context2 = __esm({
8856
9439
  });
8857
9440
  var Http;
8858
9441
  var init_http = __esm({
8859
- "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/transports/http.js"() {
9442
+ "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/transports/http.js"() {
8860
9443
  init_tslib_es6();
8861
9444
  init_esm();
8862
9445
  Http = /** @class */
@@ -8918,10 +9501,10 @@ var init_http = __esm({
8918
9501
  }
8919
9502
  });
8920
9503
 
8921
- // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/config.js
9504
+ // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/config.js
8922
9505
  var NodeConfig, useNodeConfig;
8923
9506
  var init_config2 = __esm({
8924
- "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/config.js"() {
9507
+ "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/config.js"() {
8925
9508
  init_tslib_es6();
8926
9509
  init_esm();
8927
9510
  init_http();
@@ -8939,10 +9522,10 @@ var init_config2 = __esm({
8939
9522
  }
8940
9523
  });
8941
9524
 
8942
- // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/node-client.js
9525
+ // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/node-client.js
8943
9526
  var AmplitudeNode, createInstance, node_client_default;
8944
9527
  var init_node_client = __esm({
8945
- "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/node-client.js"() {
9528
+ "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/node-client.js"() {
8946
9529
  init_tslib_es6();
8947
9530
  init_esm();
8948
9531
  init_context2();
@@ -9016,7 +9599,7 @@ var init_node_client = __esm({
9016
9599
  }
9017
9600
  });
9018
9601
 
9019
- // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/types.js
9602
+ // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/types.js
9020
9603
  var types_exports = {};
9021
9604
  __export(types_exports, {
9022
9605
  IdentifyOperation: () => IdentifyOperation,
@@ -9027,12 +9610,12 @@ __export(types_exports, {
9027
9610
  SpecialEventType: () => SpecialEventType
9028
9611
  });
9029
9612
  var init_types4 = __esm({
9030
- "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/types.js"() {
9613
+ "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/types.js"() {
9031
9614
  init_esm();
9032
9615
  }
9033
9616
  });
9034
9617
 
9035
- // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/index.js
9618
+ // ../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/index.js
9036
9619
  var esm_exports = {};
9037
9620
  __export(esm_exports, {
9038
9621
  Identify: () => Identify,
@@ -9053,7 +9636,7 @@ __export(esm_exports, {
9053
9636
  });
9054
9637
  var add, groupIdentify, identify, init, logEvent, remove, revenue, setGroup, setOptOut, track, flush;
9055
9638
  var init_esm2 = __esm({
9056
- "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.29/node_modules/@amplitude/analytics-node/lib/esm/index.js"() {
9639
+ "../../node_modules/.pnpm/@amplitude+analytics-node@1.5.31/node_modules/@amplitude/analytics-node/lib/esm/index.js"() {
9057
9640
  init_node_client();
9058
9641
  init_node_client();
9059
9642
  init_esm();
@@ -10855,7 +11438,7 @@ var init_is_disjoint = __esm({
10855
11438
  function isObjectLike(value) {
10856
11439
  return typeof value === "object" && value !== null;
10857
11440
  }
10858
- function isObject(input) {
11441
+ function isObject2(input) {
10859
11442
  if (!isObjectLike(input) || Object.prototype.toString.call(input) !== "[object Object]") {
10860
11443
  return false;
10861
11444
  }
@@ -10875,7 +11458,7 @@ var init_is_object = __esm({
10875
11458
 
10876
11459
  // ../../node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/esm/lib/is_jwk.js
10877
11460
  function isJWK(key) {
10878
- return isObject(key) && typeof key.kty === "string";
11461
+ return isObject2(key) && typeof key.kty === "string";
10879
11462
  }
10880
11463
  function isPrivateJWK(key) {
10881
11464
  return key.kty !== "oct" && typeof key.d === "string";
@@ -11519,7 +12102,7 @@ var init_produce = __esm({
11519
12102
  ProduceJWT = class {
11520
12103
  _payload;
11521
12104
  constructor(payload = {}) {
11522
- if (!isObject(payload)) {
12105
+ if (!isObject2(payload)) {
11523
12106
  throw new TypeError("JWT Claims Set MUST be an object");
11524
12107
  }
11525
12108
  this._payload = payload;