diff --git a/kwc-tracking.html b/kwc-tracking.html index b639208..29b28f6 100644 --- a/kwc-tracking.html +++ b/kwc-tracking.html @@ -196,6 +196,9 @@ */ function _handleUnload () { window.removeEventListener('unload', _handleUnload); + if (!queue.length) { + return; + } try { let client = new XMLHttpRequest(), url = `${config.API_URL}/track/${schema}`,