posthog-node 5.8.5 → 5.8.7
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.
- package/dist/edge/index.cjs +3 -18
- package/dist/edge/index.cjs.map +1 -1
- package/dist/edge/index.mjs +3 -18
- package/dist/edge/index.mjs.map +1 -1
- package/dist/node/index.cjs +3 -18
- package/dist/node/index.cjs.map +1 -1
- package/dist/node/index.mjs +3 -18
- package/dist/node/index.mjs.map +1 -1
- package/package.json +3 -3
package/dist/node/index.cjs
CHANGED
|
@@ -747,7 +747,7 @@ class ErrorTracking {
|
|
|
747
747
|
this.client.addPendingPromise((async () => {
|
|
748
748
|
const eventMessage = await ErrorTracking.buildEventMessage(exception, hint);
|
|
749
749
|
const exceptionProperties = eventMessage.properties;
|
|
750
|
-
const exceptionType = exceptionProperties?.$exception_list[0]
|
|
750
|
+
const exceptionType = exceptionProperties?.$exception_list[0]?.type ?? 'Exception';
|
|
751
751
|
const isRateLimited = this._rateLimiter.consumeRateLimit(exceptionType);
|
|
752
752
|
if (isRateLimited) {
|
|
753
753
|
this._logger.info('Skipping exception capture because of client rate limiting.', {
|
|
@@ -1191,7 +1191,7 @@ function snipLine(line, colno) {
|
|
|
1191
1191
|
return newLine;
|
|
1192
1192
|
}
|
|
1193
1193
|
|
|
1194
|
-
var version = "5.8.
|
|
1194
|
+
var version = "5.8.7";
|
|
1195
1195
|
|
|
1196
1196
|
/**
|
|
1197
1197
|
* A lazy value that is only computed when needed. Inspired by C#'s Lazy<T> class.
|
|
@@ -1551,22 +1551,7 @@ class FeatureFlagsPoller {
|
|
|
1551
1551
|
const flagConditions = flagFilters.groups || [];
|
|
1552
1552
|
let isInconclusive = false;
|
|
1553
1553
|
let result = undefined;
|
|
1554
|
-
|
|
1555
|
-
// # evaluated first, and the variant override is applied to the first matching condition.
|
|
1556
|
-
const sortedFlagConditions = [...flagConditions].sort((conditionA, conditionB) => {
|
|
1557
|
-
const AHasVariantOverride = !!conditionA.variant;
|
|
1558
|
-
const BHasVariantOverride = !!conditionB.variant;
|
|
1559
|
-
if (AHasVariantOverride && BHasVariantOverride) {
|
|
1560
|
-
return 0;
|
|
1561
|
-
} else if (AHasVariantOverride) {
|
|
1562
|
-
return -1;
|
|
1563
|
-
} else if (BHasVariantOverride) {
|
|
1564
|
-
return 1;
|
|
1565
|
-
} else {
|
|
1566
|
-
return 0;
|
|
1567
|
-
}
|
|
1568
|
-
});
|
|
1569
|
-
for (const condition of sortedFlagConditions) {
|
|
1554
|
+
for (const condition of flagConditions) {
|
|
1570
1555
|
try {
|
|
1571
1556
|
if (await this.isConditionMatch(flag, distinctId, condition, properties, evaluationCache)) {
|
|
1572
1557
|
const variantOverride = condition.variant;
|