diff options
author | Daniel Jalkut <jalkut@red-sweater.com> | 2022-05-18 11:20:21 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-18 11:20:21 +0300 |
commit | f17af4c1b8811467962137163e28719831604066 (patch) | |
tree | 060af26349c50298df289e0cb6551586e2dd4349 /js/piwik.js | |
parent | e078b77488cfdc264a55bf594da7923c6a8cbb15 (diff) |
Take care to always 'return request' in appendAvailablePerformanceMetrics (#19232)
* Take care to always 'return request' in appendAvailablePerformanceMetrics
This alleviates a variety of spurious "Invalid idSite: 0" issues as described in #12264. That issue was closed in 2019 but since then many of us have continued to see issues that do not seem to be rooted in client configuration errors, as suggested by https://github.com/matomo-org/matomo/issues/12264#issuecomment-474991737.
* Add minified matomo.js.
* Delete piwik.min.js
Co-authored-by: Stefan Giehl <stefan@matomo.org>
Diffstat (limited to 'js/piwik.js')
-rw-r--r-- | js/piwik.js | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/js/piwik.js b/js/piwik.js index 09019f3c6e..acbf631976 100644 --- a/js/piwik.js +++ b/js/piwik.js @@ -3564,7 +3564,7 @@ if (typeof window.Matomo !== 'object') { if (performanceData.connectEnd && performanceData.fetchStart) { if (performanceData.connectEnd < performanceData.fetchStart) { - return; + return request; } timings += '&pf_net=' + Math.round(performanceData.connectEnd - performanceData.fetchStart); @@ -3573,7 +3573,7 @@ if (typeof window.Matomo !== 'object') { if (performanceData.responseStart && performanceData.requestStart) { if (performanceData.responseStart < performanceData.requestStart) { - return; + return request; } timings += '&pf_srv=' + Math.round(performanceData.responseStart - performanceData.requestStart); @@ -3582,7 +3582,7 @@ if (typeof window.Matomo !== 'object') { if (performanceData.responseStart && performanceData.responseEnd) { if (performanceData.responseEnd < performanceData.responseStart) { - return; + return request; } timings += '&pf_tfr=' + Math.round(performanceData.responseEnd - performanceData.responseStart); @@ -3592,7 +3592,7 @@ if (typeof window.Matomo !== 'object') { if (performanceData.domInteractive && performanceData.domLoading) { if (performanceData.domInteractive < performanceData.domLoading) { - return; + return request; } timings += '&pf_dm1=' + Math.round(performanceData.domInteractive - performanceData.domLoading); @@ -3601,7 +3601,7 @@ if (typeof window.Matomo !== 'object') { if (performanceData.domInteractive && performanceData.responseEnd) { if (performanceData.domInteractive < performanceData.responseEnd) { - return; + return request; } timings += '&pf_dm1=' + Math.round(performanceData.domInteractive - performanceData.responseEnd); @@ -3611,7 +3611,7 @@ if (typeof window.Matomo !== 'object') { if (performanceData.domComplete && performanceData.domInteractive) { if (performanceData.domComplete < performanceData.domInteractive) { - return; + return request; } timings += '&pf_dm2=' + Math.round(performanceData.domComplete - performanceData.domInteractive); @@ -3620,7 +3620,7 @@ if (typeof window.Matomo !== 'object') { if (performanceData.loadEventEnd && performanceData.loadEventStart) { if (performanceData.loadEventEnd < performanceData.loadEventStart) { - return; + return request; } timings += '&pf_onl=' + Math.round(performanceData.loadEventEnd - performanceData.loadEventStart); |