Rounds floats passed to analytics (instead of truncating them).

pull/784/head
Boris Grozev 9 years ago
parent ec98e6fdff
commit c59d9e7c8b
  1. 2
      analytics.js

@ -12,7 +12,7 @@
Analytics.prototype.sendEvent = function (action, data) {
// empty label and add the value, the value should be integer or null
var value = parseInt(data);
var value = Math.round(parseFloat(data));
ga('send', 'event', 'jit.si', action, "", value ? value : null);
};

Loading…
Cancel
Save