diff --git a/src/.vuepress/theme/util/countly.js b/src/.vuepress/theme/util/countly.js index cffd1e0c..5e42d134 100644 --- a/src/.vuepress/theme/util/countly.js +++ b/src/.vuepress/theme/util/countly.js @@ -44,6 +44,8 @@ export function loadScript() { Track an event to countly with the provided data */ export function trackEvent(event, data = {}) { + if (!window.Countly) return + window.Countly.q.push([ 'add_event', {