@mrporter/frontend-monitoring
Advanced tools
Comparing version 1.0.1 to 1.0.2
@@ -34,11 +34,9 @@ 'use strict'; | ||
if (Math.random() < sampleRate) { | ||
if (!this.client) { | ||
console.log('Keen Event (Dev Mode): ', event); | ||
} else if (event) { | ||
var collection = event.collection; | ||
var event_data = event.event_data; | ||
if (!this.client) { | ||
console.log('Keen Event (Dev Mode): ', event); | ||
} else if (event && Math.random() < sampleRate) { | ||
var collection = event.collection; | ||
var event_data = event.event_data; | ||
this.client.addEvent(collection, { event_data: event_data }); | ||
} | ||
this.client.addEvent(collection, { event_data: event_data }); | ||
} | ||
@@ -45,0 +43,0 @@ } |
{ | ||
"name": "@mrporter/frontend-monitoring", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"description": "Utils and Events for MRP front end monitoring", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
8260
134