@fortify-dwellings/core
Advanced tools
Comparing version 0.2.58 to 0.2.59
@@ -29,10 +29,11 @@ "use strict"; | ||
: event_type; | ||
pageViews = pageViews + 1; | ||
let skipTrack = false; | ||
if (isInternal && cleanedEventType === 'Page Viewed') { | ||
pageViews = pageViews + 1; | ||
skipTrack = true; | ||
} | ||
const shouldIgnore = ((_a = pluginConfig === null || pluginConfig === void 0 ? void 0 : pluginConfig.excludeEvents) === null || _a === void 0 ? void 0 : _a.includes(cleanedEventType)) || | ||
(((_b = pluginConfig === null || pluginConfig === void 0 ? void 0 : pluginConfig.includeEvents) === null || _b === void 0 ? void 0 : _b.length) && !(pluginConfig === null || pluginConfig === void 0 ? void 0 : pluginConfig.includeEvents.includes(cleanedEventType))); | ||
if (shouldIgnore) { | ||
if (pluginConfig === null || pluginConfig === void 0 ? void 0 : pluginConfig.enrichEventProperties) { | ||
const honey = { ignored: true }; | ||
event.event_properties = Object.assign(Object.assign({}, event.event_properties), { honey }); | ||
} | ||
return event; | ||
@@ -39,0 +40,0 @@ } |
@@ -26,10 +26,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
: event_type; | ||
pageViews = pageViews + 1; | ||
let skipTrack = false; | ||
if (isInternal && cleanedEventType === 'Page Viewed') { | ||
pageViews = pageViews + 1; | ||
skipTrack = true; | ||
} | ||
const shouldIgnore = ((_a = pluginConfig === null || pluginConfig === void 0 ? void 0 : pluginConfig.excludeEvents) === null || _a === void 0 ? void 0 : _a.includes(cleanedEventType)) || | ||
(((_b = pluginConfig === null || pluginConfig === void 0 ? void 0 : pluginConfig.includeEvents) === null || _b === void 0 ? void 0 : _b.length) && !(pluginConfig === null || pluginConfig === void 0 ? void 0 : pluginConfig.includeEvents.includes(cleanedEventType))); | ||
if (shouldIgnore) { | ||
if (pluginConfig === null || pluginConfig === void 0 ? void 0 : pluginConfig.enrichEventProperties) { | ||
const honey = { ignored: true }; | ||
event.event_properties = Object.assign(Object.assign({}, event.event_properties), { honey }); | ||
} | ||
return event; | ||
@@ -36,0 +37,0 @@ } |
{ | ||
"name": "@fortify-dwellings/core", | ||
"description": "Threat detection library for real estate companies. Powered by honeypot.run", | ||
"description": "", | ||
"author": "https://honeypot.run", | ||
"version": "0.2.58", | ||
"version": "0.2.59", | ||
"license": "BUSL-1.1", | ||
"keywords": [ | ||
"geofencing", | ||
"browser", | ||
"identification", | ||
"fingerprinting", | ||
"real estate", | ||
"fraud", | ||
"browser fingerprint", | ||
"device fingerprint", | ||
"privacy" | ||
"security" | ||
], | ||
@@ -16,0 +14,0 @@ "main": "./dist/cjs/src/public/index.js", |
45801
1055