coveo.analytics 2.30.40 → 2.30.42

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.
@@ -728,7 +728,7 @@
728
728
  const v5 = v35('v5', 0x50, sha1);
729
729
  var uuidv5 = v5;
730
730
 
731
- var libVersion = "2.30.40" ;
731
+ var libVersion = "2.30.42" ;
732
732
 
733
733
  var getFormattedLocation = function (location) {
734
734
  return "".concat(location.protocol, "//").concat(location.hostname).concat(location.pathname.indexOf('/') === 0 ? location.pathname : "/".concat(location.pathname)).concat(location.search);
@@ -1538,13 +1538,14 @@
1538
1538
 
1539
1539
  var doNotTrackValues = ['1', 1, 'yes', true];
1540
1540
  function doNotTrack() {
1541
- return (hasNavigator() &&
1542
- [
1543
- navigator.globalPrivacyControl,
1544
- navigator.doNotTrack,
1545
- navigator.msDoNotTrack,
1546
- window.doNotTrack,
1547
- ].some(function (value) { return doNotTrackValues.indexOf(value) !== -1; }));
1541
+ var checks = [];
1542
+ if (hasWindow()) {
1543
+ checks.push(window.doNotTrack);
1544
+ }
1545
+ if (hasNavigator()) {
1546
+ checks.push(navigator.doNotTrack, navigator.msDoNotTrack, navigator.globalPrivacyControl);
1547
+ }
1548
+ return checks.some(function (value) { return doNotTrackValues.indexOf(value) !== -1; });
1548
1549
  }
1549
1550
 
1550
1551
  var donottrack = /*#__PURE__*/Object.freeze({