Skip to content
This repository was archived by the owner on Dec 26, 2022. It is now read-only.

Commit 8da727f

Browse files
committed
Fix GA
1 parent 7e466db commit 8da727f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

.env.example

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
SENTRY_DSN='https://XXXX.ingest.sentry.io/00000000'
2-
GA_UACODE=UA-XXXXXXXXXX
2+
GA_UACODE=UA-XXXXXXXXX-X
33
# DEBUG=universal-analytics
44
# NODE_DEBUG=request # debug requests in analytics

src/services/gaService/GaService.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ const executeOnCondition = (fn: () => void) => {
1717

1818
const GaService = {
1919
pageView(path: string) {
20-
executeOnCondition(analytics?.pageview(path).send());
20+
executeOnCondition(() => analytics?.pageview(path).send());
2121
},
2222
event(category: string, action: string) {
23-
executeOnCondition(analytics?.event(category, action).send());
23+
executeOnCondition(() => analytics?.event(category, action).send());
2424
},
2525
};
2626

0 commit comments

Comments
 (0)